Bug fixes and improvements
Merge pull request #3 from ussuri/master

Bug fixes and improvements