Skip to main content

Buy Me A Coffee Twitter Twitter PyPI version Downloads

cudacanvas

CudaCanvas: Real-time PyTorch Tensor Image Visualisation in CUDA, Eliminating CPU Transfer

CudaCanvas is a simple Python module that eliminates CPU transfer for Pytorch tensors for displaying and rendering images in the training or evaluation phase, ideal for machine learning scientists and engineers.

Simplified version that directly displays the image without explicit window creation (cudacanvas >= v1.0.1)

import torch
import cudacanvas


#REPLACE THIS with you training loop
while (True):

    #REPLACE THIS with you training code and generation of data
    noise_image = torch.rand((4, 500, 500), device="cuda")

    #Visualise your data in real-time
    cudacanvas.im_show(noise_image)

    #OPTIONAL: Terminate training when the window is closed
    if cudacanvas.should_close():
        #end process if the window is closed
        break

And with explicit window creation

import torch
import cudacanvas

noise_image = torch.rand((4, 500, 500), device="cuda")

cudacanvas.set_image(noise_image)
cudacanvas.create_window()

#replace this with you training loop
while (True):

    cudacanvas.render()

    if cudacanvas.should_close():
        #end process if the window is closed
        break

Installation

Before instllation make sure you have torch with cuda support already installed on your machine

We aligned pytorch and cuda version with our package the supporting packages are torch (2.0.1, 2.1.2 and 2.2.2) and (11.8 and 12.1)

Identify your current torch and cuda version

import torch
torch.__version__

Depending on your torch and cuda you can install the relevant cudacanvas package, for the latest 2.2.2+cu121 you can simply download the latest package

pip install cudacanvas

For other torch and cuda packages put the torch and cuda version after that cudacanvas version for example for 2.1.2+cu181 the Cudacanvas package you require is 1.0.1.post212181

pip install cudacanvas==1.0.1.post212181 --force-reinstall

Support

Also support my channel ☕ ☕ : https://www.buymeacoffee.com/outofai

Metadata

Release files for cudacanvas 1.0.1.post201118

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for cudacanvas 1.0.1.post201118
File Actions
cudacanvas-1.0.1.post201118-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details for cudacanvas-1.0.1.post201118-cp311-cp311-win_amd64.whl
cudacanvas-1.0.1.post201118-cp311-cp311-manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details for cudacanvas-1.0.1.post201118-cp311-cp311-manylinux2014_x86_64.whl
cudacanvas-1.0.1.post201118-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details for cudacanvas-1.0.1.post201118-cp310-cp310-win_amd64.whl
cudacanvas-1.0.1.post201118-cp310-cp310-manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details for cudacanvas-1.0.1.post201118-cp310-cp310-manylinux2014_x86_64.whl
cudacanvas-1.0.1.post201118-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details for cudacanvas-1.0.1.post201118-cp39-cp39-win_amd64.whl
cudacanvas-1.0.1.post201118-cp39-cp39-manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details for cudacanvas-1.0.1.post201118-cp39-cp39-manylinux2014_x86_64.whl
cudacanvas-1.0.1.post201118-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details for cudacanvas-1.0.1.post201118-cp38-cp38-win_amd64.whl
cudacanvas-1.0.1.post201118-cp38-cp38-manylinux2014_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.17+ x86-64 Details for cudacanvas-1.0.1.post201118-cp38-cp38-manylinux2014_x86_64.whl

Total release size: 3.5 MB

Release files / cudacanvas-1.0.1.post201118-cp311-cp311-win_amd64.whl

Download URL cudacanvas-1.0.1.post201118-cp311-cp311-win_amd64.whl
Size 99.4 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
02068b77037ff66d0793b6ab911f32912c9e09c67a6fed8d13c76d50ae48c7df
BLAKE2b-256 checksum
How to use checksums
f6bd3ca74459b862bc0520cb037e5546cc3f52a191d33f1417338b16d2b0c4fd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.11

Release files / cudacanvas-1.0.1.post201118-cp311-cp311-manylinux2014_x86_64.whl

Download URL cudacanvas-1.0.1.post201118-cp311-cp311-manylinux2014_x86_64.whl
Size 81.5 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
1350c5e6bdf5afc36174b92678ee2cf8ad6cc25b0a6cb1e19fbb6a4239535467
BLAKE2b-256 checksum
How to use checksums
d630e87ce4b04cd4041b43f356daa91ebbc38a0833eba94fba2ae35636833117
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.11

Release files / cudacanvas-1.0.1.post201118-cp310-cp310-win_amd64.whl

Download URL cudacanvas-1.0.1.post201118-cp310-cp310-win_amd64.whl
Size 99.0 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
039b63cb6c93de667d20271adc556ab6f2a3832f4325278c567574c6b2ab4660
BLAKE2b-256 checksum
How to use checksums
1f1181ea1c322cedb15d8992f53cccc5d22cef9f73587af9a1878d030034ff32
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release files / cudacanvas-1.0.1.post201118-cp310-cp310-manylinux2014_x86_64.whl

Download URL cudacanvas-1.0.1.post201118-cp310-cp310-manylinux2014_x86_64.whl
Size 81.2 kB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
7a38782878c4f592a00673d6a76b7a9f42ec7f28021a7a0f746c5a20f362d153
BLAKE2b-256 checksum
How to use checksums
1975f8910c1a28d954301ae425ea7a872a0701a5bfda6edf8f757335c132d496
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release files / cudacanvas-1.0.1.post201118-cp39-cp39-win_amd64.whl

Download URL cudacanvas-1.0.1.post201118-cp39-cp39-win_amd64.whl
Size 101.6 kB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
43e2eaab8b1718d7b4c2807a39380c0673ec7a3e2ea8bc91eba4a0bd244495c1
BLAKE2b-256 checksum
How to use checksums
4380d9d8962f336912dbfcc504c14f68224876bd29ad1304594e88ff1d88cb63
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release files / cudacanvas-1.0.1.post201118-cp39-cp39-manylinux2014_x86_64.whl

Download URL cudacanvas-1.0.1.post201118-cp39-cp39-manylinux2014_x86_64.whl
Size 80.4 kB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
931c017920cf9ae7faa7a407db90360fc87a7157f32f57bf39d037cebbafb48f
BLAKE2b-256 checksum
How to use checksums
fa3bb94a79db99e6f0e8792cbc97d5d88159f219e74a83beb6ea8683c18238ad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release files / cudacanvas-1.0.1.post201118-cp38-cp38-win_amd64.whl

Download URL cudacanvas-1.0.1.post201118-cp38-cp38-win_amd64.whl
Size 101.4 kB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
01cdc48d6267157413517bf0cb9db1a297c8b18fe7a87fdb86222f4db7c93c68
BLAKE2b-256 checksum
How to use checksums
3fc786ac1e486556deb5c6730336bc3b415ce5b67af12da7443792b8ac208bee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release files / cudacanvas-1.0.1.post201118-cp38-cp38-manylinux2014_x86_64.whl

Download URL cudacanvas-1.0.1.post201118-cp38-cp38-manylinux2014_x86_64.whl
Size 2.9 MB
Tags CPython 3.8 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
0343a36cec158fc4683067cb151e08b90a55447c07fa079317da3f5ab0fb95ca
BLAKE2b-256 checksum
How to use checksums
afb3210f6eb853f426e4cfdf8481536c139499b74fd3320fa4cf95942574afce
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Security for cudacanvas 1.0.1.post201118

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page