54 |
try: sys.argv.remove('--jpeg'); jpeg = 1 |
try: sys.argv.remove('--jpeg'); jpeg = 1 |
55 |
except ValueError: jpeg = 0 |
except ValueError: jpeg = 0 |
56 |
|
|
57 |
|
notify = None |
58 |
|
|
59 |
print "ARGV:",sys.argv |
print "ARGV:",sys.argv |
60 |
print "DBG:",dbg.short,dbg.long,dbg.all |
print "DBG:",dbg.short,dbg.long+['notify='],dbg.all |
61 |
opts, args = getopt.getopt(sys.argv[1:], |
opts, args = getopt.getopt(sys.argv[1:], |
62 |
dbg.short, |
dbg.short, |
63 |
dbg.long) |
dbg.long+['notify=']) |
64 |
for o,a in opts: |
for o,a in opts: |
65 |
print "Opt: ",o,a |
print "Opt: ",o,a |
66 |
|
if o == '--notify': |
67 |
|
notify == a |
68 |
if o in dbg.all: |
if o in dbg.all: |
69 |
dbg.option(o,a) |
dbg.option(o,a) |
70 |
|
|
71 |
passmask = [1,1,1,1] |
passmask = [1,1,1,1] |
72 |
basedir = './' # must be ended by backslash |
basedir = './' # must be ended by backslash |
73 |
|
|
|
# catching feature parameters from the command line |
|
|
try: sys.argv.remove('--texture'); texture = 1 |
|
|
except ValueError: texture = 0 |
|
|
|
|
|
# catching feature parameters from the command line |
|
|
try: sys.argv.remove('--texture'); texture = 1 |
|
|
except ValueError: texture = 0 |
|
74 |
|
|
75 |
def listdir(path, extensions): |
def listdir(path, extensions): |
76 |
""" |
""" |
141 |
long(seed.split('.')[0]), |
long(seed.split('.')[0]), |
142 |
jpeg) |
jpeg) |
143 |
os.system('rm '+basedir+seed) |
os.system('rm '+basedir+seed) |
144 |
|
if notify: |
145 |
|
os.system(notify + ' ' + seed.split('.')[0]) |
146 |
|
|
147 |
else: |
else: |
148 |
print time.strftime('%y/%m/%d %H:%M:%S'), \ |
print time.strftime('%y/%m/%d %H:%M:%S'), \ |
149 |
"No requests, sleeping..." |
"No requests, sleeping..." |