Skip to content

RuntimeError Couldn't find appropriate backend to handle uri {uri} and format {format}. #79

Description

@Raviu56

🐛 Bug Report

Whenever I run encodec I get:

$ encodec -b 3.0 -s encodec cut_original.wav 
/tmp/encodec_vnenv/lib64/python3.11/site-packages/torch/nn/utils/weight_norm.py:30: UserWarning: torch.nn.utils.weight_norm is deprecated in favor of torch.nn.utils.parametrizations.weight_norm.
  warnings.warn("torch.nn.utils.weight_norm is deprecated in favor of torch.nn.utils.parametrizations.weight_norm.")
Traceback (most recent call last):
  File "/tmp/encodec_vnenv/bin/encodec", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/tmp/encodec_vnenv/lib/python3.11/site-packages/encodec/__main__.py", line 109, in main
    wav, sr = torchaudio.load(args.input)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/tmp/encodec_vnenv/lib64/python3.11/site-packages/torchaudio/_backend/utils.py", line 203, in load
    backend = dispatcher(uri, format, backend)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/tmp/encodec_vnenv/lib64/python3.11/site-packages/torchaudio/_backend/utils.py", line 115, in dispatcher
    raise RuntimeError(f"Couldn't find appropriate backend to handle uri {uri} and format {format}.")
RuntimeError: Couldn't find appropriate backend to handle uri cut_original.wav and format None.

To Reproduce

(Write your steps here:)

  1. create a python virtualenv
  2. activate it and run pip install -U git+https://git@github.com/facebookresearch/encodec#egg=encodec
  3. run encodec like encodec -b 3.0 -s encodec cut_original.wav I've trying different file formats mp3/m4a and others, no success
  4. also tried the stable version with pip no success

Expected behavior

It should simply work

Actual Behavior

Error above

Your Environment

$ pip freeze
einops==0.7.0
encodec @ git+https://git@github.com/facebookresearch/encodec@0e2d0aed29362c8e8f52494baf3e6f99056b214f
filelock==3.13.1
fsspec==2023.12.2
Jinja2==3.1.3
MarkupSafe==2.1.3
mpmath==1.3.0
networkx==3.2.1
numpy==1.26.3
nvidia-cublas-cu12==12.1.3.1
nvidia-cuda-cupti-cu12==12.1.105
nvidia-cuda-nvrtc-cu12==12.1.105
nvidia-cuda-runtime-cu12==12.1.105
nvidia-cudnn-cu12==8.9.2.26
nvidia-cufft-cu12==11.0.2.54
nvidia-curand-cu12==10.3.2.106
nvidia-cusolver-cu12==11.4.5.107
nvidia-cusparse-cu12==12.1.0.106
nvidia-nccl-cu12==2.18.1
nvidia-nvjitlink-cu12==12.3.101
nvidia-nvtx-cu12==12.1.105
sympy==1.12
torch==2.1.2
torchaudio==2.1.2
triton==2.1.0
typing_extensions==4.9.0
  • Python 3.11
  • Operating system: openSUSE Tumbleweed
  • Hardware (gpu or cpu, amount of RAM etc.): nvidia [GeForce RTX 3050 with installed working drivers and cuda which I've already been used for other ML projects.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions