add saving model support
Merge pull request #3 from tongming/master

add saving model support