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

Is there a file missing or am I doing something wrong? FileNotFoundError: [Errno 2] No such file or directory: '/home/Project/musicautobot/data/numpy/musicitem_data_save.pkl' #30

Open
Centrino999 opened this issue Sep 13, 2022 · 1 comment

Comments

@Centrino999
Copy link

I am trying to start the Flask server. This results in the following error message:

(base) felix@LAPTOP:~/Project/musicautobot/serve$ python run.py
Traceback (most recent call last):
  File "/home/felix/Project/musicautobot/serve/run.py", line 2, in <module>
    from api import app
  File "/home/felix/Project/musicautobot/serve/api/__init__.py", line 38, in <module>
    from .predict_multitask import *
  File "/home/felix/Project/musicautobot/serve/api/predict_multitask.py", line 16, in <module>
    data = load_data(app.config['DATA_PATH'], app.config['DATA_SAVE_NAME'], num_workers=1)
  File "/home/felix/anaconda3/lib/python3.9/site-packages/fastai/basic_data.py", line 281, in load_data
    ll = torch.load(source, map_location='cpu') if defaults.device == torch.device('cpu') else torch.load(source)
  File "/home/felix/anaconda3/lib/python3.9/site-packages/torch/serialization.py", line 699, in load
    with _open_file_like(f, 'rb') as opened_file:
  File "/home/felix/anaconda3/lib/python3.9/site-packages/torch/serialization.py", line 230, in _open_file_like
    return _open_file(name_or_buffer, mode)
  File "/home/felix/anaconda3/lib/python3.9/site-packages/torch/serialization.py", line 211, in __init__
    super(_open_file, self).__init__(open(name, mode))
FileNotFoundError: [Errno 2] No such file or directory: '/home/felix/Project/musicautobot/data/numpy/musicitem_data_save.pkl'

Since I didn't find a matching file in the repository, I just created an empty file, which doesn't do much either:

> (base) felix@LAPTOP:~/Project/musicautobot/serve$ python run.py
Traceback (most recent call last):
  File "/home/felix/Project/musicautobot/serve/run.py", line 2, in <module>
    from api import app
  File "/home/felix/Project/musicautobot/serve/api/__init__.py", line 38, in <module>
    from .predict_multitask import *
  File "/home/felix/Project/musicautobot/serve/api/predict_multitask.py", line 16, in <module>
    data = load_data(app.config['DATA_PATH'], app.config['DATA_SAVE_NAME'], num_workers=1)
  File "/home/felix/anaconda3/lib/python3.9/site-packages/fastai/basic_data.py", line 281, in load_data
    ll = torch.load(source, map_location='cpu') if defaults.device == torch.device('cpu') else torch.load(source)
  File "/home/felix/anaconda3/lib/python3.9/site-packages/torch/serialization.py", line 713, in load
    return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args)
  File "/home/felix/anaconda3/lib/python3.9/site-packages/torch/serialization.py", line 920, in _legacy_load
    magic_number = pickle_module.load(f, **pickle_load_args)
EOFError: Ran out of input

I only edited the api.cfg file as follows, nothing more:

# Input bucket name only. Not the whole s3 URL
S3_BUCKET_NAME = 'MultitaskLarge'

How can I solve the problem? I followed the instructions in the readme file during the installation. Where is the error?

@Centrino999 Centrino999 changed the title Is there a file missing or am I doing something wrong? FileNotFoundError: [Errno 2] No such file or directory: '/home/felix/Project/musicautobot/data/numpy/musicitem_data_save.pkl' Is there a file missing or am I doing something wrong? FileNotFoundError: [Errno 2] No such file or directory: '/home/Project/musicautobot/data/numpy/musicitem_data_save.pkl' Sep 13, 2022
@phaschwazzi
Copy link

I have also run into this error.

I will update here if I'm able to find a solution. Please do the same if you find something also. Thanks!

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