This gets confusing, but there is an open source alternative to MathPix called 
Pix2Text [1]. It uses LateX-OCR but it has had some work done on handwritten 
equations. Unfortunately, the model used doesn't seem to be part of the 
distribution yet, but is available in the web version [2]. One positive in your 
sample is that the equation is written in a different colour, I tried using 
OpenCV to isolate the colour, and then used the attached against the web 
version. I couldn't get a faithful rendering for the LaTeX but it might be 
worth investigating:

\int_{x}\,x^{2}\,\,d x\;\;+\,\,\sqrt{d}

Good luck, the handwritten aspect of your quest makes it a difficult one, but 
Pix2Text shows some promise for typeset equations at least.

art
---
1. https://github.com/breezedeus/Pix2Text
2. https://p2t.breezedeus.com/
From: tesseract-ocr@googlegroups.com <tesseract-ocr@googlegroups.com> On Behalf 
Of muhammad hamad
Sent: Thursday, November 2, 2023 10:00 AM
To: tesseract-ocr <tesseract-ocr@googlegroups.com>
Subject: [tesseract-ocr] Hi there! I am looking for the open source solution to 
convert an image (having math equation written on it) into Latex

You don't often get email from 
muhammadhamad...@gmail.com<mailto:muhammadhamad...@gmail.com>. Learn why this 
is important<https://aka.ms/LearnAboutSenderIdentification>
I have tried LateX-OCR [ https://github.com/lukas-blecher/LaTeX-OCR ] but it is 
not fruit full. Do you have any suggestions. Thanks in advance!

Example:
Input Image: Attached Below
Output in LaTex: \begin{equation}\int_{2}^{1}x^{2}dx+\sqrt[3]{2}\end{equation}
--
You received this message because you are subscribed to the Google Groups 
"tesseract-ocr" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
tesseract-ocr+unsubscr...@googlegroups.com<mailto:tesseract-ocr+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tesseract-ocr/1006e0ea-8c0b-4b7d-a2c0-f50d9d46b8d9n%40googlegroups.com<https://groups.google.com/d/msgid/tesseract-ocr/1006e0ea-8c0b-4b7d-a2c0-f50d9d46b8d9n%40googlegroups.com?utm_medium=email&utm_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"tesseract-ocr" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tesseract-ocr+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tesseract-ocr/YT2PR01MB98898595ADECFE8FE9D9BD2DDCA6A%40YT2PR01MB9889.CANPRD01.PROD.OUTLOOK.COM.

Reply via email to