Italian OCR Error Correction Sequence-to-Sequence Model
Model Details
This model represents the first version of an experimental sequence-to-sequence architecture designed specifically for the Italian language. It aims to correct approximately 93% of the errors generated by low-quality Optical Character Recognition (OCR) systems, which tend to perform poorly on Italian text. By taking raw, OCR-scanned text as input, the model outputs the corrected version of the text, significantly reducing errors and improving readability and accuracy.
Intended Use
Primary Use
: This model is intended for use in processing and correcting Italian text that has been digitized using OCR technology. It is particularly useful for texts scanned at low quality, where the OCR's error rate is noticeably high.
Users
: It is designed for developers, researchers, and archivists working with Italian historical documents, books, and any digitized material where OCR errors are prevalent.
Limitations
While the model corrects approximately 93% of OCR errors, there may be certain types of errors or specific contexts where its performance could be lower.
The model is specifically trained on Italian text and may not perform well on texts in other languages or texts that include significant amounts of non-Italian languages.
How to Use
import torch
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
device = "cuda"if torch.cuda.is_available() else"cpu"
MODEL_NAME = "DeepMount00/OCR_corrector"
model = AutoModelForSeq2SeqLM.from_pretrained(MODEL_NAME).eval()
tokenizer = AutoTokenizer.from_pretrained(MODEL_NAME)
model.to(device)
my_text = "In un'epca lontnaa, un re goernava le sue tere con saggez2a e giustiia. Sotot il suo regno, il rgeno prosperava e la getne era flice. Ma un gionro, un drgoa feroce attcò il regno, semniando ditruzione e paurra tra i suoi abtanti."
inputs = tokenizer(my_text, return_tensors="pt").to(device)
outputs = model.generate(input_ids=inputs['input_ids'],
attention_mask=inputs['attention_mask'],
num_beams=2, max_length=1050, top_k=10)
clean_text = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(clean_text)
Runs of DeepMount00 OCR_corrector on huggingface.co
92
Total runs
0
24-hour runs
2
3-day runs
12
7-day runs
73
30-day runs
More Information About OCR_corrector huggingface.co Model
OCR_corrector huggingface.co is an AI model on huggingface.co that provides OCR_corrector's model effect (), which can be used instantly with this DeepMount00 OCR_corrector model. huggingface.co supports a free trial of the OCR_corrector model, and also provides paid use of the OCR_corrector. Support call OCR_corrector model through api, including Node.js, Python, http.
OCR_corrector huggingface.co is an online trial and call api platform, which integrates OCR_corrector's modeling effects, including api services, and provides a free online trial of OCR_corrector, you can try OCR_corrector online for free by clicking the link below.
DeepMount00 OCR_corrector online free url in huggingface.co:
OCR_corrector is an open source model from GitHub that offers a free installation service, and any user can find OCR_corrector on GitHub to install. At the same time, huggingface.co provides the effect of OCR_corrector install, users can directly use OCR_corrector installed effect in huggingface.co for debugging and trial. It also supports api for free installation.