add doc string and remove useless comments