juglab / labkit-ui

Advanced Tool for Labeling And Segmentation
BSD 2-Clause "Simplified" License
33 stars 21 forks source link

Possible race condition when removing labels #74

Open hinerm opened 3 years ago

hinerm commented 3 years ago

I have run into an AIOOBE twice when training a classifier after adding/removing Labels. This is the stack trace:

image

I have tried different combinations of adding classes, adding pixels to them or not, then removing the label(s) and training a classifier (with different timings of when the classifier is added as well). I haven't been able to reliably reproduce the exception :( which makes me suspicious of this WeakHashMap iteration.

Is it possible that if segmentation was run after removing a label but before GC, this loop would cause an AIOOBE?