Use argparse instead of optparse

Close #172