A neural network visualization engine, built for pytorch
Project description
Neural Network Visualization Tool
This tool is designed to provide a dynamic visualization of neural network training. It integrates with a PyTorch model's forward pass as a decorator, allowing you to visualize how neural network training occurs.
Features:
-
Supported Loss Functions:
NLLLoss
CrossEntropyLoss
-
Layer Compatibility:
- Currently supports fully connected (dense) layers.
Interactive Visualization:
- View the gradient, bias, and weight histories for both nodes and lines.
- Click on any node or line to inspect its parameters.
Installation
pip install pytorch_visualizer
How the API is used
Below is an example showing how the API can be used:
from python_visualizer.nn_visualizer import visualize
class SimpleNN(nn.Module):
def __init__(self):
super(SimpleNN, self).__init__()
self.fc1 = nn.Linear(2, 5)
self.fc2 = nn.Linear(5, 3)
self.relu = nn.ReLU()
@visualize(epochs=5, labels=None, loss_func=None, backward=False)
def forward(self, x):
x = self.fc1(x)
x = self.relu(x)
x = self.fc2(x)
return x
check demo.ipynb for a full implementation with a training loop
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pytorch_visualizer-0.1.1.tar.gz
(40.3 kB
view details)
Built Distribution
File details
Details for the file pytorch_visualizer-0.1.1.tar.gz
.
File metadata
- Download URL: pytorch_visualizer-0.1.1.tar.gz
- Upload date:
- Size: 40.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ee77f580005d3928d4196d70041b6c6020af97f4ba87d12c2c13f78cf70b69ff |
|
MD5 | 855e32d985e188d8dc044197816cd996 |
|
BLAKE2b-256 | af905d35ff5cdcfec27d890ed386d2fa19eb5b27a6aa9f4e9f7c87b9a1afb5a6 |
File details
Details for the file pytorch_visualizer-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: pytorch_visualizer-0.1.1-py3-none-any.whl
- Upload date:
- Size: 47.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b2a6336cacc53f0fe25c916967c30c56903403db75d68f660983d01754ebef9b |
|
MD5 | 9a3e7536ca8aa78cd887162707d01cc5 |
|
BLAKE2b-256 | 429181def1e7422a648a01dcacb52dadd9dd001a3bc516ad61bf1f5824c75108 |