- compatible with py3
- use argparse to replace optparse, optparse module is deprecated.