23-02-23 06:49 PM
Hello Community,
I've been using the core Blue Prism product for little more than a year now. One of the product features that I found very interesting is Surface Automation. And this post is a direct consequence of me venturing into this area.
Background:
The Surface Automation course is a solid 36 hours long. It took me several weeks to learn and work through several of the exercises. I'm surprised how well Surface Automation works and how it could be used to solve some if not all business problems.
Unfortunately, when it came to using the Desktop App that comes as part of this course, it was unusable because it required me to activate .NET3.5 and we did not have permissions on our work laptops to do so. Obviously, I could have approached our IT Helpdesk to make this happen, but then scaling it up to a large group of BP developers meant jumping through additional hoops.
The solution? I decided to use what I learned to Surface Automate the famous Centrix Data Solutions desktop application instead. And that is when I found myself stumbling over several times to get the Read Text with OCR action to work reliably!
Cutting to the chase:
After exhausting all the other avenues, I decided to look closer at the Tesseract Engine options that we can set as part of the Read Text with OCR Read action, particularly in this specific order:
Environmental Conditions & Disclaimer:
The experience published below is based on the following circumstances:
And therefore, what I've shared here is limited to my experience of getting past the challenges I faced in this environment, and you will need to play with these options before you can exact reliable performance from Read Text with OCR!
Try these helpful options:
A few screen shots published below show the end result. And I'm hoping that these options will help others as a starting point.
Summarization:
# |
Scale |
Page Segmentation Mode |
Character Whitelist |
Notes |
1 |
2 |
Line |
|
Worked for alpha-numeric-symbol data on Gray scale. Example: EFD-702, EDA-437,CFF-908 |
2 |
4 |
|
|
|
3 |
2 |
Character |
0123456789 |
Worked on whole numbers on Gray scale. Example: 7, 8,10,1 |
4 |
2 |
Line |
0123456789 |
Worked on long string numeric data. Example: 43723457, 90895989 |
IMPORTANT NOTES:
Test Results:
Observation: All data where 7 appears in various formats have been read reliably
Observation: Single-digit whole number data has been read as expected
Related Documentation:
Cheers!
-Andy Menon
------------------------------
Prashanth (Andy) Menon
------------------------------
02-03-23 03:44 PM
Andy, thank you for taking the time to put this together. I went through the surface automation course myself, and it took a lot longer than 36 hours! But it has been very useful in automating some troublesome applications for sure.
I was having some trouble with the read text with OCR just today. My automation was having trouble reading/interpreting the image below:
For whatever reason, it was reading it as 4224788062.
Previously the read stage worked 90% of the time. But, unfortunately, from time to time it reads wrong and adds a random number.
I solved the problem using your recommendations. For me, using scale number 3 was what did the trick.
Again, thanks for your extensive review of the subject!
------------------------------
Awoyinka Daramola
------------------------------
02-03-23 04:00 PM
Hello @Awoyinka Daramola
First off, thank you for reaching out. Truly appreciate it.
I'm glad that you were able to solve the problem based on the information published in my open discussion post.
You are correct, the course is 36 hours but it takes a lot longer to step through. As for my OCR article, it was a direct consequence of an 8-week struggle (similar to yours) to read a single digit number.
Congrats on resolving the issue!
-Andy