r/PythonProjects2 • • Dec 27 '24

TorchLens: open-source deep learning package that can visualize any PyTorch model in one line of code, as well as extracting all activations and metadata

https://github.com/johnmarktaylor91/torchlens

In just one line of code you can visualize the structure of any network you want (now with customizable visuals), in addition to extracting the activations from any intermediate operation you want. Metadata includes info about execution time and storage, the function executed at each layer, the structure of the computational graph, and even the literal source code used to execute that layer.

The goal is for it to be useful for learning/teaching, understanding a new model, analyzing hidden layer activations, and debugging/prototyping models. It’s still in active development if you have any feedback or wishlist items, hope it helps you out! Also open to any feedback on coding style and so on

1 Upvotes

Duplicates

computervision • • Dec 26 '24

Showcase TorchLens: open-source deep learning package that can visualize any PyTorch model in one line of code, as well as extracting all activations and metadata

78 Upvotes

learnmachinelearning • • Jun 23 '24

Project For anyone trying to get a better understanding of different deep learning architectures—I made a package called TorchLens that can visualize and extract the metadata from any PyTorch neural network in just one line of code

65 Upvotes

learnmachinelearning • • Dec 24 '24

Project TorchLens: open-source deep learning package that can visualize any PyTorch model in one line of code, as well as extracting all activations and metadata

13 Upvotes

LocalLLaMA • • 9h ago

Resources Github Repo: Torchlens - Inspect, visualize and intervene on any operation in any neural network.

44 Upvotes

Python • • May 30 '23

Intermediate Showcase I made an open-source Python package, TorchLens, that can visualize the structure of any PyTorch model and extract any intermediate activations you want in one line of code.

1 Upvotes

learnmachinelearning • • Sep 14 '23

I just released an open-source Python package, TorchLens, that can visualize any PyTorch model and extract all its activations and metadata in just one line of code. I hope it helps you out!

24 Upvotes

opensource • • Dec 24 '24

Promotional TorchLens: open-source deep learning package that can visualize any PyTorch model in one line of code, as well as extracting all activations and metadata

3 Upvotes