read_image(Fabrik, 'fabrik')
gen_rectangle2(Rectangle_Label,243,320,-1.55,62,28)
reduce_domain(Fabrik, Rectangle_Label, Fabrik_Label)
* Character extraction without gray value expansion:
mean_image(Fabrik_Label,Label_Mean_normal,31,31)
dyn_threshold(Fabrik_Label,Label_Mean_normal,Characters_normal,10,'dark')
dev_display(Fabrik)
dev_display(Characters_normal)
* The characters in the border region are not extracted !
stop()
* Character extraction with gray value expansion:
expand_domain_gray(Fabrik_Label, Label_expanded,15)
reduce_domain(Label_expanded,Rectangle_Label, Label_expanded_reduced)
mean_image(Label_expanded_reduced,Label_Mean_expanded,31,31)
dyn_threshold(Fabrik_Label,Label_Mean_expanded,Characters_expanded,10,'dark')
dev_display(Fabrik)
dev_display(Characters_expanded)
* Now, even in the border region the characters are recognized
expand_domain_gray
![](https://img-home.csdnimg.cn/images/20240711042549.png)