Extracting text from ID cards

[ ]

An identity card (commonly abbreviated as ID) is a small plastic or paper card that is used to verify a person’s identity. This can be an identity card, work permit, residence permit, passport card or other identity document. Manually re-typing text from ID cards, especially in batch mode, is time consuming and commonly leads to errors.

Aspose.OCR offers a special recognition algorithm that extracts text from scanned or photographed ID cards, which can then be automatically saved to the database or automatically verified.

To extract text from an ID card, use RecognizeIDCard method of Aspose.OCR.AsposeOcr class.

This method allows you to customize recognition accuracy, performance, and other settings.

The method takes OcrInput object and returns a RecognitionResult object containing the identity data.

Aspose.OCR.AsposeOcr recognitionEngine = new Aspose.OCR.AsposeOcr();
// Add images to OcrInput object
Aspose.OCR.OcrInput input = new Aspose.OCR.OcrInput(Aspose.OCR.InputType.SingleImage);
// Recognition settings
Aspose.OCR.IDCardRecognitionSettings recognitionSettings = new Aspose.OCR.IDCardRecognitionSettings();
recognitionSettings.Language = Aspose.OCR.Language.Latin;
// Recognize ID cards
List<Aspose.OCR.RecognitionResult> results = recognitionEngine.RecognizeIDCard(input, recognitionSettings);
foreach(Aspose.OCR.RecognitionResult result in results)