-
Notifications
You must be signed in to change notification settings - Fork 7.1k
UserWarning: video_reader video backend is not available #2216
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
Comments
Hi, This is expected, as we don't ship Note that it will require As such, I'm closing this issue but let us know if you have issues compiling torchvision from source. |
I'll try building.
Is this documented anywhere? |
Got this after building from source and running the command I mentioned above. Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/tmp/vision/torchvision/__init__.py", line 5, in <module>
from torchvision import models
File "/private/tmp/vision/torchvision/models/__init__.py", line 12, in <module>
from . import detection
File "/private/tmp/vision/torchvision/models/detection/__init__.py", line 1, in <module>
from .faster_rcnn import *
File "/private/tmp/vision/torchvision/models/detection/faster_rcnn.py", line 7, in <module>
from torchvision.ops import misc as misc_nn_ops
File "/private/tmp/vision/torchvision/ops/__init__.py", line 1, in <module>
from .boxes import nms, box_iou
File "/private/tmp/vision/torchvision/ops/boxes.py", line 8, in <module>
def nms(boxes, scores, iou_threshold):
File "/usr/local/Caskroom/miniconda/base/envs/tv/lib/python3.8/site-packages/torch/jit/__init__.py", line 1290, in script
fn = torch._C._jit_script_compile(qualified_name, ast, _rcb, get_default_args(obj))
RuntimeError:
object has no attribute nms:
File "/private/tmp/vision/torchvision/ops/boxes.py", line 41
by NMS, sorted in decreasing order of scores
"""
return torch.ops.torchvision.nms(boxes, scores, iou_threshold)
~~~~~~~~~~~~~~~~~~~~~~~~~ <--- HERE Here's my environment:
|
it is explained in the release notes https://github.com/pytorch/vision/releases/tag/v0.4.2 but maybe we can make it more explicit in the error message About the error you got, looks like the compilation didn't succeed properly (you might have had error messages showing up). |
Let me know if there's anything I can do to help.
I compiled it from source in a fresh environment.
You're right. I'll see if there are issues about that and, if not, I'll create one. |
@fepegar if you could send a PR modifying the error message with |
Ok, I will! But should I wait until #2220 is resolved? |
I'm looking at #2220 now, and I think I reproduced the error |
As requested by @fmassa in comment #2216 (comment) from #2216.
Hi, I was digging into video_reader backend and this may be interesting #2490 |
Hi, just an addition to this, Compiling torchvision requires a nightly version of PyTorch, this should be in the readme (took me a few to figure out why the compilation was failing). |
🐛 Bug
I get a "
video_reader
video backend is not available" warning when trying to set it.To Reproduce
Steps to reproduce the behavior:
Output:
I'm using the nightly version because I hoped this would be fixed in #2183.
I get only the warning (i.e. last two lines) in the stable pip release.
Expected behavior
No warning when I set the backend.
Environment
PyTorch version: 1.6.0.dev20200514
Is debug build: No
CUDA used to build PyTorch: None
OS: Mac OSX 10.15.4
GCC version: Could not collect
CMake version: version 3.17.2
Python version: 3.8
Is CUDA available: No
CUDA runtime version: No CUDA
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA
Versions of relevant libraries:
[pip] numpy==1.18.4
[pip] torch==1.6.0.dev20200514
[pip] torchvision==0.7.0.dev20200514
[conda] numpy 1.18.4 pypi_0 pypi
[conda] torch 1.6.0.dev20200514 pypi_0 pypi
[conda] torchvision 0.7.0.dev20200514 pypi_0 pypi
Additional context
Discovered when I tried following @bjuncek advice in #1884.
The text was updated successfully, but these errors were encountered: