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

CLI broken: PytorchStreamReader failed reading zip archive #92

Open
ibevers opened this issue Nov 15, 2024 · 2 comments
Open

CLI broken: PytorchStreamReader failed reading zip archive #92

ibevers opened this issue Nov 15, 2024 · 2 comments

Comments

@ibevers
Copy link
Contributor

ibevers commented Nov 15, 2024

(.venv) isaacbevers@MacBook-Pro-87 b2aiprep % b2aiprep-cli --help                                     
100%|███████████████████████████████████████████████████████████████████████████████████████████████████| 28.2M/28.2M [00:02<00:00, 10.0MB/s]
100%|████████████████████████████████████████████████████████████████████████████████████████████████████▉| 360M/360M [00:41<00:00, 9.07MB/s]
Traceback (most recent call last):
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/bin/b2aiprep-cli", line 5, in <module>
    from b2aiprep.cli import cli
  File "/Users/isaacbevers/sensein/b2ai-wrapper/b2aiprep/src/b2aiprep/cli.py", line 8, in <module>
    from b2aiprep.commands import (  # gensynthtabdata,
  File "/Users/isaacbevers/sensein/b2ai-wrapper/b2aiprep/src/b2aiprep/commands.py", line 47, in <module>
    from b2aiprep.prepare.prepare import extract_features_workflow, validate_bids_data
  File "/Users/isaacbevers/sensein/b2ai-wrapper/b2aiprep/src/b2aiprep/prepare/prepare.py", line 49, in <module>
    from senselab.audio.tasks.features_extraction.api import extract_features_from_audios
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/senselab/audio/tasks/features_extraction/api.py", line 16, in <module>
    from .torchaudio_squim import extract_objective_quality_features_from_audios
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/senselab/audio/tasks/features_extraction/torchaudio_squim.py", line 11, in <module>
    subjective_model = SQUIM_SUBJECTIVE.get_model()
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/torchaudio/pipelines/_squim_pipeline.py", line 129, in get_model
    state_dict = torch.load(path, weights_only=True)
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/torch/serialization.py", line 1326, in load
    with _open_zipfile_reader(opened_file) as opened_zipfile:
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/torch/serialization.py", line 671, in __init__
    super().__init__(torch._C.PyTorchFileReader(name_or_buffer))
RuntimeError: PytorchStreamReader failed reading zip archive: failed finding central directory
(.venv) isaacbevers@MacBook-Pro-87 b2aiprep % b2aiprep-cli --help
Traceback (most recent call last):
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/bin/b2aiprep-cli", line 5, in <module>
    from b2aiprep.cli import cli
  File "/Users/isaacbevers/sensein/b2ai-wrapper/b2aiprep/src/b2aiprep/cli.py", line 8, in <module>
    from b2aiprep.commands import (  # gensynthtabdata,
  File "/Users/isaacbevers/sensein/b2ai-wrapper/b2aiprep/src/b2aiprep/commands.py", line 47, in <module>
    from b2aiprep.prepare.prepare import extract_features_workflow, validate_bids_data
  File "/Users/isaacbevers/sensein/b2ai-wrapper/b2aiprep/src/b2aiprep/prepare/prepare.py", line 49, in <module>
    from senselab.audio.tasks.features_extraction.api import extract_features_from_audios
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/senselab/audio/tasks/features_extraction/api.py", line 16, in <module>
    from .torchaudio_squim import extract_objective_quality_features_from_audios
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/senselab/audio/tasks/features_extraction/torchaudio_squim.py", line 11, in <module>
    subjective_model = SQUIM_SUBJECTIVE.get_model()
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/torchaudio/pipelines/_squim_pipeline.py", line 129, in get_model
    state_dict = torch.load(path, weights_only=True)
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/torch/serialization.py", line 1326, in load
    with _open_zipfile_reader(opened_file) as opened_zipfile:
  File "/Users/isaacbevers/sensein/b2ai-wrapper/.venv/lib/python3.10/site-packages/torch/serialization.py", line 671, in __init__
    super().__init__(torch._C.PyTorchFileReader(name_or_buffer))
RuntimeError: PytorchStreamReader failed reading zip archive: failed finding central directory




@ibevers ibevers changed the title CLI broken CLI broken: PytorchStreamReader failed reading zip archive Nov 15, 2024
@fabiocat93
Copy link
Contributor

fabiocat93 commented Nov 15, 2024

Hi @ibevers , I noticed the issue and tried reproducing it locally. I used the function from senselab.audio.tasks.features_extraction.api import import extract_features_from_audios on my MacBook worked fine without errors.

Could you please provide additional details to help us reproduce the problem? This information will help in debugging the issue more effectively. Thank you!

@ibevers
Copy link
Contributor Author

ibevers commented Nov 18, 2024

Hi @fabiocat93, this is not a blocker at the moment, but I will loop back and give more detail if it becomes one. Thank you for being willing to help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants