wct-img-2-bee.py
Go to the documentation of this file.
1 #!/usr/bin/env python
2 import sys, os, glob
3 
4 def main(filepattern):
5  if (os.path.exists('data/0')):
6  print('found old data, removing ...')
7  os.system('rm -rf data')
8  if (os.path.exists('upload.zip')):
9  os.system('rm -f upload.zip')
10  os.system('mkdir -p data/0')
11  cmd = 'wirecell-img bee-blobs -s center -o data/0/0-test.json %s' % (
12  filepattern, )
13  print(cmd)
14  os.system(cmd)
15  os.system('zip -r upload data')
16 
17 if __name__ == "__main__":
18  if (len(sys.argv)!=2):
19  print("usage: python wct-img-2-bee.py 'filepattern'")
20  else:
21  main(sys.argv[1])
def main(filepattern)
Definition: wct-img-2-bee.py:4