Write README.md, and some bugs corrections