# kingyiusuen/image-to-latex

Convert images of LaTex math equations into LaTex code.

Repository: https://github.com/kingyiusuen/image-to-latex
Canonical: https://ross.abutalabs.com/products/image-to-latex
Language: Python
License: MIT
License Family: permissive
Topics: pytorch, deep-learning, transformer, encoder-decoder, streamlit-webapp, latex, end-to-end-machine-learning, computer-vision
Last push: 2022-10-04T20:50:32+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 1927, "days_push": 1429, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2159, forks 311 (observed 2026-08-28T04:06:19.924537+00:00)

## What it is
A PyTorch application that converts images of LaTeX math equations into LaTeX code using a ResNet-18 encoder and Transformer decoder trained on the im2markup dataset. It includes a Streamlit web app for uploading equation screenshots and getting LaTeX output.

## Use cases
- convert a screenshot of a math equation to latex code
- extract latex from an image of a formula
- ocr for handwritten or rendered math equations
- learn how to build an image-to-sequence deep learning model
- run an end-to-end ml project with training, evaluation, and a web demo

## When to choose
- you need to transcribe rendered math equation images into latex
- you want a reference implementation of a CNN encoder + Transformer decoder for image-to-text tasks
- you want a small, readable end-to-end ML project with a Streamlit demo

## When to avoid
- you need production-grade math OCR for arbitrary fonts, handwriting, or noisy scans
- you need a maintained tool with recent updates or broad ecosystem support
- you need general document OCR rather than isolated equation images

## Facets
- artifact type: application
- maturity: maintenance
- function: machine-learning, deep-learning, computer-vision, ocr, nlp
- domain: computer-vision, deep-learning, pdf, education, machine-learning
- platform: python, cross-platform
- tags: image-to-latex, encoder-decoder, transformer, resnet, streamlit, pytorch, im2markup, math-ocr

## Member repositories
- kingyiusuen/image-to-latex (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:19.924537+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:50:20.337327+00:00, confidence not recorded.
  - readme: https://github.com/kingyiusuen/image-to-latex (fetched 2026-08-28T04:06:19.924537+00:00, sha 954bef906163)
- Data as of 2026-08-30T08:39:29.467469+00:00.
