Practical overview
When it fits
Use MolScribe when a workflow needs to turn molecular structure images into structured chemical representations, either through its linked hosted demo or the documented Python interface.
Who it is for
- Chemistry researchers digitizing molecular structure diagrams
- Developers building scientific document or chemistry-image processing workflows
Documented uses
- Convert a molecular diagram image into a machine-readable chemical structure.
- Extract SMILES, molfile, atom, bond, and confidence information from a prediction.
- Use a downloadable model checkpoint for local image prediction.
Requirements & limits
The project is open source under the MIT license. The repository links to a hosted Hugging Face demonstration and documents local Python use.
- The documented model input size is 384 × 384.
- The example initializes the model with PyTorch on CPU.
- The repository separates checkpoint-based prediction from training and evaluation, which require additional packages and datasets.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Install MolScribe and prepare a local prediction
Set up the documented Python model interface and load a checkpoint for image prediction.
Before you start
- Python environment
- MolScribe package or repository
- PyTorch
- Hugging Face Hub access to download the MolScribe checkpoint
- A molecular structure image file
Steps
Install MolScribe with pip, or clone the repository and run its setup.py install command.
Download a MolScribe checkpoint from Hugging Face Hub.
Import torch, MolScribe, and hf_hub_download, then load the checkpoint and initialize MolScribe with a device.
Pass an image path to predict_image_file; the documented example requests atom, bond, and confidence details.
Expected outcome
A prediction dictionary that can include SMILES, molfile, confidence, atom details, and bond details.
Guide limitations
- The guide covers local setup and the documented prediction call, not model accuracy for a particular image or workflow.
- The repository points to its interface module and prediction notebook for further API details.
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 17 November 2026
- Original website title
- thomas0809/MolScribe · Official homepage title · retained in its source language

