summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2019-01-09 23:12:46 +0100
committerJules Laplace <julescarbon@gmail.com>2019-01-09 23:12:46 +0100
commit863656f3394a82bb77d7dfdcbc9c788d2f5a6175 (patch)
tree61dc28df86ba7d046d3e27ea0de00b323dd0d8fc
parent333a743e278dac3f0997bad1b6480ecbceb1d71c (diff)
parent6eb733747b1d5333eedbdb976955c2ffb8c98e63 (diff)
only one
-rw-r--r--crop-moving.py16
1 files changed, 3 insertions, 13 deletions
diff --git a/crop-moving.py b/crop-moving.py
index 2e895d1..18f9a2e 100644
--- a/crop-moving.py
+++ b/crop-moving.py
@@ -51,19 +51,9 @@ if not opt.no_clobber:
if os.path.exists(out_path):
rmtree(out_path)
-for i in range(opt.count):
- x = int(i / opt.count * src_width) - x_margin
- w = x + crop_width + x_margin + x_margin
- if w > src_width:
- w = src_width
- x = src_width - (crop_width + x_margin + x_margin)
- if x < 0:
- x = 0
- crops.append((x, y0, w, y0 + crop_height + y_margin + y_margin,))
- letter = chr(97 + i)
- path = os.path.join(out_path, letter)
- os.makedirs(path)
- paths.append(path)
+path = os.path.join(out_path, 'a')
+os.makedirs(path)
+paths.append(path)
max_i = opt.max
dataset = []