ryouchinsa / Rectlabel-support

RectLabel is an offline image annotation tool for object detection and segmentation.
https://rectlabel.com
507 stars 73 forks source link

Memory leak when augmenting images #188

Closed jimjam-slam closed 2 years ago

jimjam-slam commented 2 years ago

Hi there! I'm trying to augment the images in my dataset (about 1057) images using the rotate and contrast options. When I start the process, RectLabel's memory consumption immediately starts rising from a steady 110 MB or so, by about a gigabyte every 5-10 seconds. The app crashes when my laptop's 16 GB is exhausted (well before all images are processed), and I get a macOS dialog asking me to kill apps.

ryouchinsa commented 2 years ago

Thanks for reporting the issue.

To reproduce the problem in our environment, let us ask some questions.

jimjam-slam commented 2 years ago

I'm asking for 2 augmented images per image. All of the 1057 source images are 3024x4032 (although I note that the augmented images come out a little bigger due to the padding the rotation introduces). The object types are boxes.

ryouchinsa commented 2 years ago

Thanks for the details.

We could reproduce and solve the problem using autoreleasepool. https://developer.apple.com/documentation/foundation/nsautoreleasepool

Heap memory used for image processing was not released immediately.

When the new update is released, we will let you know. Thank you.

ryouchinsa commented 2 years ago

The new update version 3.06.2 was released. To show the new update on Mac App Store, press command + R to reload.

Improved the heap memory problem for "Augment all images".

Let us know your feedback.

ryouchinsa commented 2 years ago

Currently If you need our support to fix this problem, please let us know.