From bb854d3aa778e147f27798576866bdef5a4b77fb Mon Sep 17 00:00:00 2001 From: Michael Murtaugh Date: Wed, 26 Jun 2019 15:53:13 +0200 Subject: [PATCH] weird buggy image poster generator --- reportlab_image_poster.py | 27 --------------------------- 1 file changed, 27 deletions(-) diff --git a/reportlab_image_poster.py b/reportlab_image_poster.py index ef1f8cf..d923d1d 100644 --- a/reportlab_image_poster.py +++ b/reportlab_image_poster.py @@ -54,30 +54,3 @@ sys.exit(0) # print ("Grid size {0}x{1} (cols x rows)".format(cols, rows)) # print (" (total size:", cols*imsize, rows*imsize, "margins:", mx, my, ")") ################# - -for l in range(7): - print (LABELS[l]) - col = 0 - row = 0 - with open(args.labels) as f: - f.readline() - for line in f: - path, label = line.split(",") - label = int(label) - if label == l: - image = Image.open(path) - print (image.size) - - x = mx + (col*imsize) - y = my + imsize + (7-l)*(4*imsize) - ((row+1)*imsize) - - c.drawInlineImage(image, x, y, width=imsize, height=imsize) - col += 1 - if col >= cols: - col = 0 - row +=1 - if row >= 3: - break - -c.showPage() -c.save() \ No newline at end of file