Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interop kornia::Tensor with ort::Tensor (including cuda) #126

Open
edgarriba opened this issue Sep 5, 2024 · 0 comments
Open

Interop kornia::Tensor with ort::Tensor (including cuda) #126

edgarriba opened this issue Sep 5, 2024 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@edgarriba
Copy link
Member

Integration with CUDA buffers would have to go through a different API, TensorRefMut::from_raw. It just needs a pointer and shape, so Kornia's existing APIs suffice. TensorRefMuts can be used zero-copy in session inputs just like a Value, but since the memory is user-managed, it does have a lifetime bound. See ort's cudarc example: https://github.com/pykeio/ort/blob/60f6ecae9064a75a474678998af42ea87067b1b1/examples/cudarc/src/main.rs#L35-L43

Originally posted by @decahedron1 in #125 (comment)

@edgarriba edgarriba added enhancement New feature or request help wanted Extra attention is needed labels Sep 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant