summaryrefslogtreecommitdiff
path: root/crop-thirds.py
diff options
context:
space:
mode:
Diffstat (limited to 'crop-thirds.py')
-rw-r--r--crop-thirds.py22
1 files changed, 2 insertions, 20 deletions
diff --git a/crop-thirds.py b/crop-thirds.py
index fddba9d..96653a3 100644
--- a/crop-thirds.py
+++ b/crop-thirds.py
@@ -60,7 +60,8 @@ for i in range(opt.count):
if x < 0:
x = 0
crops.append((x, y0, w, y0 + crop_height + y_margin + y_margin,))
- path = os.path.join(out_path, chr(97 + i))
+ letter = chr(97 + i)
+ path = os.path.join(out_path, letter)
os.makedirs(path)
paths.append(path)
@@ -87,22 +88,3 @@ def build_thumbnail(i, fn):
chunksize = 3
with Pool(processes=cpu_count()) as pool:
pool.starmap(build_thumbnail, dataset, chunksize)
-
-# if opt.folder_id > 0:
-# endpoint = os.getenv('API_REMOTE') + '/api/file/'
-# for label in labels:
-# subprocess.call([
-# "curl",
-# "-X", "POST",
-# "-d", "folder_id={}".format(opt.folder_id),
-# "-d", "module=pix2pixhd",
-# "-d", "name={}.mov".format(label),
-# "-d", "url=https://s3.amazonaws.com/i.asdf.us/cortex/lens/data/{}/{}.mov".format(opt.folder_id, label),
-# "-d", "dataset={}".format(label),
-# "-d", "activity=splice",
-# "-d", "generated=0",
-# "-d", "processed=1",
-# "-d", "datatype=video",
-# endpoint
-# ])
-