Malayalam OCR in C# and .NET
Curtis Chau
Updated: 2026年4月23日
IronOCR 是一个 C# 软件组件,允许 .NET 程序员从图像和 PDF 文档中读取 126 种语言(包括马拉雅拉姆语)的文本。 它是 Tesseract 的一个高级分支,专为 .NET 开发人员构建,在速度和准确性方面通常优于其他 Tesseract 引擎。
IronOcr 的内容。语言。马拉雅拉姆语
此软件包包含 126 种适用于 .NET 的 OCR 语言:
- 马拉雅拉姆语
- 马拉雅拉姆语Best
- 马拉雅拉姆语Fast -马拉雅拉姆语字母表 -马拉雅拉姆语字母表Best -马拉雅拉姆语字母表Fast
下载
马拉雅拉姆语语言包[马拉雅拉姆语]
下载为Zip 文件
- 使用NuGet安装
安装
我们首先需要做的是将Malayalam OCR 包安装到您的 .NET 项目中。
代码示例
此 C# 代码示例从图像或 PDF 文档中读取马拉雅拉姆语文本。
// Import the IronOcr namespace
using IronOcr;
class Program
{
static void Main()
{
// Create a new instance of IronTesseract
var Ocr = new IronTesseract();
// Set the language to Malayalam
Ocr.Language = OcrLanguage.Malayalam;
// Process the image to extract text using OCR
using (var Input = new OcrInput(@"images\Malayalam.png"))
{
// Read the text from the input object
var Result = Ocr.Read(Input);
// Extract and store the recognized text
var AllText = Result.Text;
// Output the recognized text
Console.WriteLine(AllText);
}
}
}' Import the IronOcr namespace
Imports IronOcr
Module Program
Sub Main()
' Create a new instance of IronTesseract
Dim Ocr As New IronTesseract()
' Set the language to Malayalam
Ocr.Language = OcrLanguage.Malayalam
' Process the image to extract text using OCR
Using Input As New OcrInput("images\Malayalam.png")
' Read the text from the input object
Dim Result = Ocr.Read(Input)
' Extract and store the recognized text
Dim AllText = Result.Text
' Output the recognized text
Console.WriteLine(AllText)
End Using
End Sub
End Module- 该代码演示了如何设置 IronOCR 以对指定图像执行马拉雅拉姆语的 OCR 识别。
OcrInput对象用于输入图像文件。Ocr.Read函数处理图像并提取文本。- 提取的文本存储在
AllText中并打印到控制台。

技术作家
Curtis Chau 拥有卡尔顿大学的计算机科学学士学位,专注于前端开发,精通 Node.js、TypeScript、JavaScript 和 React。他热衷于打造直观且美观的用户界面,喜欢使用现代框架并创建结构良好、视觉吸引力强的手册。
...
阅读更多