Adding imshow function to directly display image/video without moving tensor off GPU.
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 17.9k
- Forks
- 7.3k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 13
Description
🚀 Feature
Looking for a imshow function similar to that of cv2 to directly display tensor without moving it off GPU.
Motivation
The main use case is for displaying video frames for real-time applications (such as webcam demo etc).
If the image is already on the graphics card, it should be a way to directly display it. I currently cannot find other tools available to achieve this and I don't know how to implement it. I think it would be a useful function to include in torchvision.
Alternatives
Moving tensor to CPU every frame, but this is very slow for real-time.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names torchvision and cv2 but no source file, entry point, or test. Start by reviewing torchvision's existing image and video display capabilities and how GPU tensors are handled; define the supported display path and verify that real-time frames can be shown without a per-frame CPU transfer.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- opencv, python
- Domain
- computer-vision, performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100