Skip to main content

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


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.4.0.tar.gz (18.5 kB view details)

Uploaded Source

Built Distribution

superduper_torch-0.4.0-py3-none-any.whl (18.0 kB view details)

Uploaded Python 3

File details

Details for the file superduper_torch-0.4.0.tar.gz.

File metadata

  • Download URL: superduper_torch-0.4.0.tar.gz
  • Upload date:
  • Size: 18.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for superduper_torch-0.4.0.tar.gz
Algorithm Hash digest
SHA256 eaea3b4848758eb532d7c150cef64830c3580121b4b8f171186bebcafd6a659d
MD5 01462ae3068fbd5fcc3e9783cc503b2f
BLAKE2b-256 3163ab3fdd9eb2c1718459578d8b2cc8c2f677e45b616b2a56f2e5acf0086f4d

See more details on using hashes here.

Provenance

The following attestation bundles were made for superduper_torch-0.4.0.tar.gz:

Publisher: release_plugins.yaml on superduper-io/superduper

Attestations:

File details

Details for the file superduper_torch-0.4.0-py3-none-any.whl.

File metadata

File hashes

Hashes for superduper_torch-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9bb2e44ddc701908239e3287132d6a0ccc14929810231802fcb476f63ffac8f8
MD5 e366b649c5c1d0cfaa65a7fb869ead81
BLAKE2b-256 b8652af1d24c1aa0bb3a37cfb260bbb3ec06a49fa9365171d140bccfd2efa348

See more details on using hashes here.

Provenance

The following attestation bundles were made for superduper_torch-0.4.0-py3-none-any.whl:

Publisher: release_plugins.yaml on superduper-io/superduper

Attestations:

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page