see-insight / see-segment

Simple Evolutionary Exploration - Image Segmentation
MIT License
6 stars 21 forks source link

Bus Error when running some Felzenszwalb segmentation #63

Open colbrydi opened 3 years ago

colbrydi commented 3 years ago

Sometimes the Felzenszwalb function crashes with a bush error. My guess is that one of the input parameters is causing a problem. It could be in the selected colorspace or the Felzenszwalb function itself. Here is an example of a set of parameters that fails.

<class 'see.Workflow.workflow'> parameters: colorspace = RGB CIE multichannel = True channel = 1 algorithm = Felzenszwalb alpha1 = 0.98828125 alpha2 = 0.8984375 beta1 = 0.94140625 beta2 = 0.7578125 gamma1 = 0.41796875 gamma2 = 0.1875 n_segments = 7 max_iter = 1

We need to track down the source of this failure and see if we can come up with a solution to either 1) limit the parameter space to only use values that result in errors 2) find and fix the bug in the segmentation code (report as a pull request) 3) use input tests to pick out input that will cause the problem and return an erorr or a default value or 4) try to catch this inside the code?

The first step is to build a test that can reproduce the problem and then see what can be changed in the test to fix the bug.