Open 99Jannis opened 6 hours ago
problem is probably with shape detection. I encounter the problem with test_image_03.jpg
result.JPG as well and I think I also found the probable error source. further info in the next comment.
Input result.jpg: Output result.jpg:
The shape detection looks for ALL contours of an image and if the blur matrix isn't big enough it detects MORE contours.
So there are probably hundreds of contours it detects and then also wants to detect their color and write it on the image.
a relative blur in regards to the size of the image instead of an absolute one, could maybe fix the problem but I'm not sure...
We could probably implement some kind of thresholds which are dynamic, reduced until we get a set amount of detected shapes. The downside of it is that it'll almost any time give us the wrong amount of shapes.
Another feature could be a slider in the GUI with the function to set the thresholds manually.
Thus, I'm not sure how important this is for the grading, but we could definitely put some work in it.
possible solution
a relative blur in regards to the size of the image instead of an absolute one, could maybe fix the problem but I'm not sure...
I tried this and it didn't work. It made it even worse. but what improved a bit was the recognition if I changed the blur from gaussian to the non-weighted one
if I currently use the Gui with shape detection it outputs this image: I will try to further look into the source of the problem, but would be glad with some help