@@ -35,6 +35,7 @@ def showNormalizedImage(name, normalized_image):
3535 print (x1 , y1 , x2 , y2 , x3 , y3 , x4 , y4 )
3636
3737 normalized_image = scanner .normalizeFile ("images/1.png" , x1 , y1 , x2 , y2 , x3 , y3 , x4 , y4 )
38+ normalized_image .recycle ()
3839 # showNormalizedImage("Normalized Image", normalized_image)
3940 # cv2.drawContours(image, [np.int0([(x1, y1), (x2, y2), (x3, y3), (x4, y4)])], 0, (0, 255, 0), 2)
4041
@@ -60,6 +61,7 @@ def showNormalizedImage(name, normalized_image):
6061
6162# normalized_image = scanner.normalizeBuffer(image, x1, y1, x2, y2, x3, y3, x4, y4)
6263# showNormalizedImage("Normalized Image", normalized_image)
64+ # normalized_image.recycle()
6365# cv2.drawContours(image, [np.int0([(x1, y1), (x2, y2), (x3, y3), (x4, y4)])], 0, (0, 255, 0), 2)
6466
6567# cv2.imshow('Document Image', image)
@@ -130,6 +132,7 @@ def showNormalizedImage(name, normalized_image):
130132# cv2.destroyWindow(data[0])
131133# data[1].save(str(time.time()) + '.png')
132134# print('Image saved')
135+ # data[1].recycle()
133136
134137# g_normalized_images = []
135138
0 commit comments