updated to use argparse