Manejo de ceros con barra en IronOCR

This article was translated from English: Does it need improvement?
Translated
View the article in English

Los ceros con barra no se reconocen correctamente, ¿se identifican como g, 6 u 8?

Esto puede ser un problema con los paquetes de idioma de Tesseract.

El siguiente paquete de idioma puede ayudar a abordar este problema con ceros tachados: SlashedZeroOCR

Esto se puede usar con la función de IronOCR para cargar paquetes de idioma personalizados: Ejemplo de idioma personalizado en IronOCR

// Import the IronOcr namespace
using IronOcr;

class Program
{
    static void Main(string[] args)
    {
        // Initialize IronTesseract class
        var Ocr = new IronTesseract();

        // Use a custom Tesseract language file, which may help with recognizing slashed zeros
        Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata");

        // Specify the OCR input image
        using (var Input = new OcrInput(@"images\image.png"))
        {
            // Perform OCR on the input image
            var Result = Ocr.Read(Input);

            // Output the recognized text to the console
            Console.WriteLine(Result.Text);
        }
    }
}
// Import the IronOcr namespace
using IronOcr;

class Program
{
    static void Main(string[] args)
    {
        // Initialize IronTesseract class
        var Ocr = new IronTesseract();

        // Use a custom Tesseract language file, which may help with recognizing slashed zeros
        Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata");

        // Specify the OCR input image
        using (var Input = new OcrInput(@"images\image.png"))
        {
            // Perform OCR on the input image
            var Result = Ocr.Read(Input);

            // Output the recognized text to the console
            Console.WriteLine(Result.Text);
        }
    }
}
' Import the IronOcr namespace
Imports IronOcr

Friend Class Program
	Shared Sub Main(ByVal args() As String)
		' Initialize IronTesseract class
		Dim Ocr = New IronTesseract()

		' Use a custom Tesseract language file, which may help with recognizing slashed zeros
		Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata")

		' Specify the OCR input image
		Using Input = New OcrInput("images\image.png")
			' Perform OCR on the input image
			Dim Result = Ocr.Read(Input)

			' Output the recognized text to the console
			Console.WriteLine(Result.Text)
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel
Curtis Chau
Escritor Técnico

Curtis Chau tiene una licenciatura en Ciencias de la Computación (Carleton University) y se especializa en el desarrollo front-end con experiencia en Node.js, TypeScript, JavaScript y React. Apasionado por crear interfaces de usuario intuitivas y estéticamente agradables, disfruta trabajando con frameworks modernos y creando manuales bien ...

Leer más
¿Listo para empezar?
Nuget Descargas 5,167,857 | Version: 2025.11 recién lanzado