#429429th of 433 in ML frameworks and libraries
torchview
Graphviz visualizations of PyTorch model graphs with tensor shapes
Watch puts torchview on your watch list: its new releases and known problems since your last visit. Kept in this browser, no account.torchview is on your watch list. Its new releases and problems show there.
- Stars
- 1.1k
- License
- MIT
- Last commit
- Feb 2026
- Last release
- Feb 2023
- Language
- Python
1,044 on 8 May 20261,094 on 27 Nov 2026
From GitHub's daily star counts.
Checked on GitHub.
Overview
Torchview is a Python library that draws PyTorch models as Graphviz graphs, showing modules, torch functions, tensors and input/output shapes. It records the graph during a forward pass using __torch_function__ and a Tensor subclass, and can run on meta tensors so large models use no memory. It is described as a PyTorch counterpart to Keras plot_model.
Who it is for: PyTorch developers who want architecture diagrams of their models
Strengths
- Meta-device mode builds graphs without allocating memory for large models (PyTorch 1.13+)
- Shows operations between tensors, not just module calls
- Rolls recursive modules such as RNNs into a compact view
- Handles nested inputs (dict, list) and Hugging Face tokenizer outputs
Weaknesses
- Requires the Graphviz system binary (dot) in addition to the Python package
- Last release was 2023-02-14, though commits continue
- No module parameter info and no graph neural network support yet (listed in TODO)
- SVG output can be cropped in VS Code notebooks without a PNG workaround
What it needs
- no GPU
- Needs graphviz (dot), PyTorch
- Models: PyTorch nn.Module, Hugging Face models
What changed
From the release notes. No flag means the note does not say so, not that the upgrade is safe. Releases and problems by RSS
Also in ML frameworks and libraries
See all 433| Rank | Project | Score |
|---|---|---|
| #427 | sumo-rlGymnasium and PettingZoo environments for RL traffic signal control in SUMO | 9 out of 100 |
| #428 | xaiPython library for data imbalance and model bias analysis in tabular ML | 8 out of 100 |
| #430 | sklearn-crfsuitescikit-learn-style Python wrapper for CRFsuite sequence labeling | 7 out of 100 |
| #431 | drl-robot-navigationTD3 reinforcement learning for robot goal navigation in ROS Gazebo | 6 out of 100 |
| #432 | adbenchBenchmark suite for tabular anomaly detection algorithms and datasets | 5 out of 100 |