Open dsalcedo opened 4 years ago
You could try removing the binarization step completely and directly re-coloring each blob. The idea would be to extract the circles outlining the letters instead of the letters themselves. The weakness of this CAPTCHA is that each letter is a different color, so you don't want to flatten the image to just black and white and lose that extra information.
var cbl = new CBL({
preprocess: function(img)
{
img.debugImage("debugPreprocessed");
img.colorRegions(5, true, 5);
img.debugImage("debugPreprocessed");
},
exact_characters: 6,
character_set: "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789",
blob_min_pixels: 100,
blob_max_pixels: 10000,
pattern_width: 25,
pattern_height: 25,
perceptive_colorspace: true,
allow_console_log: true,
blob_console_debug: true,
blob_debug: "debugSegmented"
});
Another option plays on the observation that there are always 6 characters and they're always in the same locations... You can mark the fixed character locations like this example.
But not solved 🤔