fix off-by-one error
This commit is contained in:
parent
2d26f7a9d0
commit
d63fedd297
@ -4,4 +4,4 @@ cd data/lcn
|
|||||||
python setup.py build_ext --inplace
|
python setup.py build_ext --inplace
|
||||||
|
|
||||||
cd ../
|
cd ../
|
||||||
python create_syn_data.py $2
|
python create_syn_data.py $1
|
||||||
|
@ -228,10 +228,10 @@ if __name__ == '__main__':
|
|||||||
out_root.mkdir(parents=True, exist_ok=True)
|
out_root.mkdir(parents=True, exist_ok=True)
|
||||||
|
|
||||||
start = 0
|
start = 0
|
||||||
if len(sys.argv) >= 2 and isinstance(sys.argv[2], int):
|
if len(sys.argv) >= 2 and isinstance(sys.argv[1], int):
|
||||||
start = sys.argv[2]
|
start = sys.argv[1]
|
||||||
else:
|
else:
|
||||||
if sys.argv[2] == '--resume':
|
if sys.argv[1] == '--resume':
|
||||||
try:
|
try:
|
||||||
start = max([int(dir) for dir in os.listdir(out_root) if str.isdigit(dir)]) or 0
|
start = max([int(dir) for dir in os.listdir(out_root) if str.isdigit(dir)]) or 0
|
||||||
except:
|
except:
|
||||||
|
Loading…
Reference in New Issue
Block a user