We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

OMR Template Editor Threshold issue

Hi,


I’m using the template editor and setting different values for the threshold (through Edit/Settings/OMR Features /Custom Value) and I’m getting some weird results:

For both examples the threshold is set to 0.5

Attachment 1: It picks up the box as filled, the amount of black pixels is visibly less than 50%
Attachment 1: It doesn’t pick up the box as filled.

Is this related to the automatic white pixel trimming? Is there any way to turn that off from the editor tool?

Thanks!



Hi Ignacio,

Thank you for your inquiry.

Threshold is actually the percentage of the black pixels in the OMR mark area to consider it as filled. Setting the mark threshold level allows Aspose.OCR to determine which area is actually filled. This value directs how leniently or strictly the API will interpret the OMR marks. The default FillThreshold value is set to 0.45 whereas the maximum value is 1.0.

With threshold value as low as 0.1 (10%) all marks are recognized as filled. Marks are considered to be filled because even the empty mark circle takes about 26% to 30% of the area depending on area size, whereas actually filled mark takes about 60% to 70% of the area. Therefore, even if threshold value is set less than 30%, all marks are recognized as filled. Sample images are attached showing the percentage for better understanding.

Hope the above information helps. Feel free to contact us in case of any query or comments.

Thanks Ikram,


I understand that the threshold works as you described. But in the case I posted I’m setting it to be 0.5 which is 50%, and if you look at the attached images the amount if black pixels on that area is not even close to that, its more like 5-10% and the Aspose tool is still picking up the boxes as marked.

Thanks again.
Hi Ignacio,

Thank you for more details.

You had shared screenshots. Please share sample OMR template and OMR scanned sheet image with us that you are using at your end. We will look into it and update you about our findings via this forum thread.