Commit 5a0d8e18 authored by bepinat's avatar bepinat

argparse

parent c871a936
......@@ -19,7 +19,6 @@ Created on 12/2014
@author: Benoît Epinat
"""
#import getopt
import time
import os, sys
import copy
......@@ -1007,34 +1006,6 @@ def main(argv):
camel(options.filename, plot=options.plot, debug=options.debug, free_ratio=options.free_ratio, multi_ext=options.multi_ext, config=opts)
return
#def main_getopt(argv):
#"""
#"""
##Intiazation of parameters
#plot, debug, free_ratio, multi_ext = False, False, False, False
##Reading arguments
#try:
#opts, args = getopt.getopt(argv, "hf:pdrm", ["help", "file=", "plot", "debug", "free_line_ratio", "multi_ext"])
#except getopt.GetoptError:
#usage()
#sys.exit(2)
#for opt, arg in opts:
#if opt in ("-h", "--help"):
#usage()
#sys.exit()
#elif opt in ("-f", "--file"):
#filename = arg
#elif opt == '-d':
#debug = True
#elif opt in ("-p", "--plot"):
#plot = True
#elif opt in ("-r", "--free_line_ratio"):
#free_ratio = True
#elif opt in ("-m", "--multi_ext"):
#multi_ext = True
##Lauching CAMEL
#camel(filename, plot=plot, debug=debug, free_ratio=free_ratio, multi_ext=multi_ext)
#return
if __name__ == "__main__":
main(sys.argv[1:])
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment