Superduper allows users to work with arbitrary `torch` models, with custom pre-, post-processing and input/ output data-types, as well as offering training with superduper
Project description
superduper_torch
Superduper allows users to work with arbitrary torch
models, with custom pre-, post-processing and input/ output data-types, as well as offering training with superduper
Installation
pip install superduper_torch
API
Class | Description |
---|---|
superduper_torch.model.TorchModel |
Torch model. This class is a wrapper around a PyTorch model. |
superduper_torch.training.TorchTrainer |
Configuration for the PyTorch trainer. |
Examples
TorchModel
import torch
from superduper_torch.model import TorchModel
model = TorchModel(
object=torch.nn.Linear(32, 1),
identifier="test",
preferred_devices=("cpu",),
postprocess=lambda x: int(torch.sigmoid(x).item() > 0.5),
)
model.predict(torch.randn(32))
Training Example
Read more about this here
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
superduper_torch-0.0.5.tar.gz
(18.7 kB
view hashes)
Built Distribution
Close
Hashes for superduper_torch-0.0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f56dd8f7a7061987c4e05ae81849201eb7e11437a771a5fa87d86f129fd40f42 |
|
MD5 | d008f09a4666e54e4bf883f1fc07be8b |
|
BLAKE2b-256 | bd0736a2d768e8e0f67d9fd90327eccdd82d166f5c37059bf3cc835a4362d152 |