How to Improve OCR Accuracy
Summary
TLDRThe video script provides a detailed tutorial on using Scan2CAD's OCR functionality to convert raster images with text into editable vector text. It emphasizes the importance of high-quality, clear images for optimal OCR results and discusses the manual cleanup of small or touching text elements that may hinder recognition. The script guides viewers through setting OCR parameters, including character size and confidence levels, and offers tips for handling intersecting lines and vertical text. It concludes with manual editing techniques for perfecting the conversion and exporting the final vectorized document.
Takeaways
- 🔍 Use high-quality, high-resolution images with minimal pixelation and blurriness for the best OCR results.
- 📚 Ensure the text in the image is clear and easy to read for effective text recognition.
- 🖋 Handwritten or stylized text may not be recognized well by OCR, especially if it's not clear.
- 🔍 Small text details, like holes in letters, can be lost, affecting OCR accuracy.
- 👀 Scan2CAD's OCR functionality can convert raster text into editable vector text.
- ✂️ Manual editing may be necessary for text that is too close or has intersecting lines.
- 🔢 Set the maximum character size using 'Select from Image' for accurate OCR settings.
- 📏 The minimum character size is usually calculated automatically but can be adjusted manually.
- 📈 Minimum confidence level determines the display of text objects based on their recognition certainty.
- 🔄 Character rotation options should be used based on the presence of vertical or angular text.
- 🌐 Choose the appropriate language and document type for more accurate OCR results.
- 🖼️ After conversion, manually adjust and clean up the text for optimal results.
- 🖊️ Use the 'Draw Text' tool to replace or complete text that wasn't converted properly.
- 🖼️ The 'Highlight Vectors' feature helps in identifying and editing different vector elements.
Q & A
What is the main issue with converting raster text to vector lines using automatic conversion programs?
-The main issue is that the text often ends up as vector polylines, which are not editable as true type vector text.
What does OCR stand for and what does it do in the context of Scan2CAD?
-OCR stands for Optical Character Recognition. In Scan2CAD, it recognizes the text objects in a raster image and converts them into editable true type vector text.
What are the key factors to consider when choosing a document for automatic conversion?
-The document should have good quality, high resolution, minimal pixelation, and blurriness, with clear and easy-to-read text.
Why might Scan2CAD struggle with converting handwritten text?
-Handwritten text, especially if stylized, may not be recognized well by Scan2CAD due to variations in handwriting and potential pixelation issues.
What can be done if the text in the image is too small or lacks fine details?
-For smaller text, you can manually erase parts that are touching or add details like holes in letters to make them more recognizable for Scan2CAD.
What is the purpose of setting the maximum character size in Scan2CAD's OCR functionality?
-Setting the maximum character size helps Scan2CAD to identify and convert the largest characters in the image, which in turn assists in automatically calculating the minimum character size.
What does the minimum confidence level in OCR represent?
-The minimum confidence level represents the certainty of Scan2CAD in converting text objects. Text objects below this level may not be displayed if they do not meet the set confidence threshold.
Why is it important to consider character rotation settings in OCR?
-Character rotation settings are important to ensure that Scan2CAD can recognize and convert text that is not only horizontal but also vertical or at an angle.
What should be the default document type setting for technical drawings in Scan2CAD?
-The default document type setting for technical drawings should be 'technical' to optimize the OCR conversion process.
How can you manually correct the converted text in Scan2CAD if it's not accurate?
-You can use the 'Highlight Vectors' feature to see the converted vectors, then use the erase tool to remove inaccurate parts and the text tool to manually add or correct the text.
What is the recommended minimum confidence level setting for most conversions in Scan2CAD?
-The recommended default minimum confidence level is 60, which should be used unless there is a specific reason to adjust it.
Outlines
📚 Advanced OCR Functionality in Scan2CAD
This paragraph discusses the process of converting raster text to editable vector text using Scan2CAD's Optical Character Recognition (OCR) feature. It emphasizes the importance of high-quality, high-resolution images with clear, easily readable text for optimal OCR results. The script mentions challenges with stylized handwriting and small text details, such as holes in letters, that may not be recognized properly. It provides tips for cleaning up images, such as using the erase tool to separate touching letters and restore details. The paragraph also explains the OCR settings, including character size selection, minimum character size, confidence level, character rotation, and language options, to ensure the best conversion results.
🖌️ Post-OCR Image Cleanup and Finalization
The second paragraph focuses on the post-OCR conversion steps in Scan2CAD. It describes generating a preview to assess the OCR results, noting issues with letters that were too close together and not converting well. The script suggests adjusting the minimum confidence level setting and provides a caution against setting it too high, which could result in the disappearance of text objects. It also touches on the option to handle intersecting lines and the manual correction process, including using the 'Highlight Vectors' feature, erasing incorrect vector lines, and adding true type text. The paragraph concludes with the finalization of conversions, adjusting text placement, and exporting the cleaned-up file in the desired format, showcasing Scan2CAD's capability to convert technical images with text effectively.
Mindmap
Keywords
💡Automatic Conversion Programs
💡Raster Text
💡Vector Text
💡Optical Character Recognition (OCR)
💡High Resolution
💡Pixelation
💡Handwritten Text
💡Minimum Confidence Level
💡Character Rotation
💡Vectorizing OCR
💡Intersecting Lines
Highlights
Automatic conversion programs often create vector polylines from raster text, which is not always desirable.
Scan2CAD has advanced OCR functionality to convert raster text into editable vector text.
High-resolution, clear images with minimal pixelation and blurriness are recommended for conversion.
Handwritten, stylized text may not work well with OCR due to recognition challenges.
Small text details like holes in letters can be lost, affecting OCR accuracy.
Letters touching each other may be recognized as a single pixel cluster, not individual text.
Manually editing the image to separate touching letters can improve OCR results.
Clicking 'Convert Raster Image' and selecting 'Vectorizing OCR' initiates the OCR process.
Setting the maximum character size using 'Select from Image' helps in accurate OCR.
Minimum character size is automatically calculated or can be set manually.
Minimum confidence level determines the display of text objects based on OCR certainty.
High confidence levels are assigned to clear, minimally pixelated text.
Adjusting the minimum confidence level can affect the visibility of converted text.
Character rotation settings can be customized for horizontal, vertical, or angular text.
Language and document type selections are crucial for accurate OCR results.
Running the OCR generates a preview of the converted text.
Post-OCR, manual adjustments can be made to clean up the converted text.
Using 'Highlight Vectors' helps in identifying and correcting converted vector objects.
Finalizing conversions and exporting the file completes the OCR process.
Scan2CAD's OCR can effectively convert various technical images with text.
Transcripts
[music]
Usually, when you use automatic conversion programs to convert
documents like this one that have raster text, you're gonna end up with a lot of vector lines,
and even the text ends up as vector polylines. And sometimes you don't want that, you want to
convert them into actual editable two-type vector text. Luckily enough Scan2CAD has
really advanced OCR functionality, which just means Optical Character Recognition, which should
recognize the text objects in this raster image and convert them into editable two-type text.
Now with any file that you want to convert automatically, you're gonna want to get the file
that has good quality, high resolution, minimal pixelation, and blurriness. As for the text in the
image, you're gonna want to make sure that they're really clear and easy to read.
Sometimes, you're gonna have a document with handwritten text.
And that doesn't really work well, especially if the handwriting is a little bit more stylized.
For the smaller text, you can see that some of them don't really have
fine details, the holes in the A's are erased, for example. And some of the left letters are
a bit too close to each other so much so that the pixels are actually touching,
Scan2CAD might not recognize this very readily. If these letters are touching, Scan2CAD recognizes
as one single pixel cluster, so they won't be recognized as individual text. If you can
get images that don't have these types of texts, or you can manually erase the parts that are
touching by clicking on the erase tool here, and just going over and making gaps between these two
letters. You can even put some holes in the A's here. In any case, if you have a better quality
document, you shouldn't be having those problems here.
Once you've had some time to clean up the image, you can click on "Convert Raster Image". Click on
"Vectorizing OCR". Once you click that, there's an OCR tab that pops up here, click on that.
You wanna set the maximum character size, you can click on "Select from Image", look for the largest
characters here, which I think might be the room label. So let's zoom in on any one of them.
Click and drag from the top to the bottom or from the bottom to the top.
Once you let go, it automatically sets the maximum character size here.
And by default, the minimum character size will also be calculated automatically from the
maximum character size. You can set it up manually by un-ticking this one and just
typing it in. But usually, you're gonna wanna keep that ticked to get the best results.
Another thing I want to talk about is the minimum confidence level.
Basically based on the quality of the image, based on the pixelation, based on the
quality of the individual raster text, Scan2CAD assigns all of these text objects a certain
confidence level in percent. If it's sure that it converted it properly, because it's a clear word,
and has minimal pixelation, it has very clear letters, then it's gonna assign it a high
confidence level. If it's a little bit more blurry, if it's not super clear, it's gonna
assign it a lower confidence level. This minimum percentage here just makes it so that any text
object that's below this minimum confidence level won't be displayed. The default value is 60,
if you set it to 90 for example, once you convert the file, a lot of these
text objects might start to disappear because they don't reach the minimum confidence level that
you set here. For character rotation, by default, horizontal is ticked and vertical angular are not.
If you have any vertical or angular text here, then you might as well
take them but as much as possible leave them unticked if you don't need to use them anyway.
Because if you leave them ticked, it might create some false positives.
As for the language, you can choose between all of the languages that we have here. By default is
going to be English, and for the document type and technical drawings such as this one should
be set the technical and if you have a mostly text-based raster file, then click on text here.
With all these settings, set the default and just put the maximum character size
ready here, then click on "Run" to generate a preview. See what we get.
It's pretty clean. But like I expected, some of these letters that were too
close to each other didn't convert very well. But as you can see,
the word here that we took the time to clean up, which is arched, converted with no problem. Again,
it's just a matter of cleaning up the images as much as you can.
Like I mentioned before, if you set this to let's say the highest possible value of 99,
Click on "Run", you're gonna see a lot of these words start to disappear.
Like so, 'cause nothing can go higher than 99. So stick to the default level at 60.
Also, we have an option I forgot to mention that has intersecting lines. I think it's
just for these niche situations where some of these others are kind of intersecting.
Again, this isn't the most ideal placement for a letter, so this should help,
but I think for this particular one, it's just too...
Well, for one, the line that's intersecting is too thick and it's intersecting where there are
two points. So this might not be recognized, but let's see if it helps. I think for certain
letters that are more legible, it should help. Yeah, no, it didn't really help that much,
but I think for these other ones, it kind of did. Okay. Let's click on "Okay" to finalize all of
these conversions. Now, if you want to manually change this, you can go to the both tab here,
click on "Highlight Vectors" to see the converted vectors on top of the original raster.
If you wanna turn this into a raster object, rather no, a true type object,
you can click on the erase tool, erase the lines that were converted, click on the
text tool. Actually, I wanna check how large these characters are. So I'm gonna click on one,
vector information says that the size is 20. So I'm going to click on
"Draw Text", click here, set the size to 20, and then just type in the word down.
Let's click on the arrow tool and just drag this to its proper placement over here.
What else do we wanna change? Okay, for example, we have this one where
part of the word was converted, but the rest wasn't. You can actually just
erase the part of the word that wasn't converted back to the both tab to see the reference.
Click on the arrow tool, click on the R, and then add the rest of the word.
Click on okay. Move it a little bit 'cause it's intersecting the next word,
so just move it over here like this. You can take your time and clean up the whole image.
Also, if you click on the "Highlight Vectors" button here, it just makes all of the
unique vector line types into different colors. So, polylines are red, arcs are magenta,
text objects are also magenta, as you can see, dashes are black, and if you're happy with this,
un-tick the "Highlight Vectors" button, and you can click on export here in the upper
right to just save the file into whatever file format it is that you wanna use. With the OCR
functionality of Scan2CAD, you can convert many various types of technical images that
have text on them with no problem, you don't have to worry about the polythyne text anymore.
Weitere ähnliche Videos ansehen
Training Tesseract 5 for a New Font
Introduction to OCR (OCR in Python Tutorials 01.01)
Automatic number plate recognition (ANPR) with Yolov9 and EasyOCR
Python ANPR with OpenCV and EasyOCR in 25 Minutes | Automatic Number Plate Recognition Tutorial
Reading text from images with either Tesseract or Darknet/YOLO
Optical Character Recognition (OCR)
5.0 / 5 (0 votes)