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

FileNotFoundError: [WinError 2] The system cannot find the file specified #121

Closed
kordspace opened this issue Jul 7, 2020 · 8 comments
Closed

Comments

@kordspace
Copy link

kordspace commented Jul 7, 2020

(jukebox) C:\Users\Fynda\Projects\ml\jukebox>python jukebox/sample.py --model=5b_lyrics --name=sample_5b --levels=3 --sample_length_in_seconds=20 \ --total_sample_length_in_seconds=180 --sr=44100 --n_samples=6 --hop_fraction=0.5,0.5,0.125
Using cuda True
{'name': 'sample_5b', 'levels': 3, 'sample_length_in_seconds': 20, 'total_sample_length_in_seconds': 180, 'sr': 44100, 'n_samples': 6, 'hop_fraction': (0.5, 0.5, 0.125)}
Setting sample length to 881920 (i.e. 19.998185941043083 seconds) to be multiple of 128
Downloading from gce
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b/vqvae.pth.tar
Loading vqvae in eval mode
Conditioning on 1 above level(s)
Checkpointing convs
Checkpointing convs
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_artist_ids.txt
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_genre_ids.txt
Level:0, Cond downsample:4, Raw to tokens:8, Sample length:65536
Downloading from gce
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b/prior_level_0.pth.tar
Loading prior in eval mode
Conditioning on 1 above level(s)
Checkpointing convs
Checkpointing convs
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_artist_ids.txt
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_genre_ids.txt
Level:1, Cond downsample:4, Raw to tokens:32, Sample length:262144
Downloading from gce
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b/prior_level_1.pth.tar
Loading prior in eval mode
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_artist_ids.txt
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_genre_ids.txt
Level:2, Cond downsample:None, Raw to tokens:128, Sample length:1048576
Converting to fp16 params
Downloading from gce
Traceback (most recent call last):
  File "jukebox/sample.py", line 279, in <module>
    fire.Fire(run)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\site-packages\fire\core.py", line 127, in Fire
    component_trace = _Fire(component, args, context, name)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\site-packages\fire\core.py", line 366, in _Fire
    component, remaining_args)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\site-packages\fire\core.py", line 542, in _CallCallable
    result = fn(*varargs, **kwargs)
  File "jukebox/sample.py", line 276, in run
    save_samples(model, device, hps, sample_hps)
  File "jukebox/sample.py", line 181, in save_samples
    vqvae, priors = make_model(model, device, hps)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 195, in make_model
    priors = [make_prior(setup_hparams(priors[level], dict()), vqvae, 'cpu') for level in levels]
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 195, in <listcomp>
    priors = [make_prior(setup_hparams(priors[level], dict()), vqvae, 'cpu') for level in levels]
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 179, in make_prior
    restore_model(hps, prior, hps.restore_prior)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 55, in restore_model
    checkpoint = load_checkpoint(checkpoint_path)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 34, in load_checkpoint
    download(gs_path, local_path)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\utils\gcs_utils.py", line 36, in download
    subprocess.call(args)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\subprocess.py", line 339, in call
    with Popen(*popenargs, **kwargs) as p:
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\subprocess.py", line 800, in __init__
    restore_signals, start_new_session)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\subprocess.py", line 1207, in _execute_child
    startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified

I have everything installed and when I load all the models to my /.cache director from google static storage download I get this error. Seems to be something to do with importing fire in the sample.py

I am running on Windows 10 with Anaconda3 and have wget installed to windows git bash.

Not running on a linux environment...

I have 2 Nvidia RTX 2080 TI cards working on CUDA with lots of memory.
64 GB RAM
i9 CPU 5.0GHz

Saw other issues like this occur in the google collab / jupyter book and said something about wget which shouldn't be an issue? Can't run wget in my Anaconda prompt locally. Is this causing the error? What's the easiest way to add the wget cmd to the bin for anaconda3? Is this the right solution?

@NoiseGener8r
Copy link

If you have wget installed properly, you should just have to add C:\Program Files (x86)\GnuWin32\bin to PATH. See issue #89 if you haven't already.

@kordspace
Copy link
Author

kordspace commented Jul 8, 2020

If you have wget installed properly, you should just have to add C:\Program Files (x86)\GnuWin32\bin to PATH. See issue #89 if you haven't already.

Ok I am giving it a shot right now. I wasn't sure if GnuWin32 would integrate with Anaconda3 prompt wget command.

So this works but then sends me to issue #92 as it states happens in #89 ... @NoiseGener8r But do you think this is still a wget command environment PATH error? Some people on that thread are saying wget is still the issue and to switch the code out in the jukebox\utils\gcs_utils.py to not check for a certificate. I was wondering if you knew of a detail in configuring wget with GnuWin32 that I may be overlooking. I added it to my path list.

@NoiseGener8r
Copy link

Unfortunately (well, fortunately for me) I never had this error. I'm stuck on an entirely different problem myself. So no, sorry. No idea what might be causing that.

@bigboss97
Copy link

I had exactly the same problem and I added wget to my environment which has an error:

$ wget
E:/bin/wget.exe: error while loading shared libraries: ?: cannot open shared object file: No such file or directory

I simply ignored it and tried again:

$ python jukebox/sample.py --model=5b_lyrics --name=sample_5b --levels=3 --sample_length_in_seconds=20 --total_sample_length_in_seconds=180 --sr=44100 --n_samples=6 --hop_fraction=0.5,0.5,0.125

  File "C:\Users\home\AppData\Local\Programs\Python\Python37\lib\site-packages\torch\serialization.py", line 525, in load
    with _open_file_like(f, 'rb') as opened_file:
  File "C:\Users\home\AppData\Local\Programs\Python\Python37\lib\site-packages\torch\serialization.py", line 212, in _open_file_like
    return _open_file(name_or_buffer, mode)
  File "C:\Users\home\AppData\Local\Programs\Python\Python37\lib\site-packages\torch\serialization.py", line 193, in __init__
    super(_open_file, self).__init__(open(name, mode))
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\home/.cache\\jukebox-assets/models/5b/vqvae.pth.tar'

Can I get the file vqvae.pth.tar from somewhere?

@NoiseGener8r
Copy link

NoiseGener8r commented Jul 9, 2020

It should auto-generate that on run. Every time I delete it it comes back.

...mine's gone.

E: So upon examining this further, it did come back after running it again. I have no idea what happened or what's happening on your end, but I'll think about it and let you know if I notice anything.

@leNicDev
Copy link

Fixed it by installing wget using Chocolatey:
choco install wget

@bigboss97
Copy link

E: So upon examining this further, it did come back after running it again. I have no idea what happened or what's happening on your end, but I'll think about it and let you know if I notice anything.

@NoiseGener8r any update?
Thanks

@cicinwad
Copy link

(jukebox) C:\Users\Fynda\Projects\ml\jukebox>python jukebox/sample.py --model=5b_lyrics --name=sample_5b --levels=3 --sample_length_in_seconds=20 \ --total_sample_length_in_seconds=180 --sr=44100 --n_samples=6 --hop_fraction=0.5,0.5,0.125
Using cuda True
{'name': 'sample_5b', 'levels': 3, 'sample_length_in_seconds': 20, 'total_sample_length_in_seconds': 180, 'sr': 44100, 'n_samples': 6, 'hop_fraction': (0.5, 0.5, 0.125)}
Setting sample length to 881920 (i.e. 19.998185941043083 seconds) to be multiple of 128
Downloading from gce
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b/vqvae.pth.tar
Loading vqvae in eval mode
Conditioning on 1 above level(s)
Checkpointing convs
Checkpointing convs
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_artist_ids.txt
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_genre_ids.txt
Level:0, Cond downsample:4, Raw to tokens:8, Sample length:65536
Downloading from gce
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b/prior_level_0.pth.tar
Loading prior in eval mode
Conditioning on 1 above level(s)
Checkpointing convs
Checkpointing convs
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_artist_ids.txt
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_genre_ids.txt
Level:1, Cond downsample:4, Raw to tokens:32, Sample length:262144
Downloading from gce
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b/prior_level_1.pth.tar
Loading prior in eval mode
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_artist_ids.txt
Loading artist IDs from c:\users\fynda\projects\ml\jukebox\jukebox\data/ids/v2_genre_ids.txt
Level:2, Cond downsample:None, Raw to tokens:128, Sample length:1048576
Converting to fp16 params
Downloading from gce
Traceback (most recent call last):
  File "jukebox/sample.py", line 279, in <module>
    fire.Fire(run)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\site-packages\fire\core.py", line 127, in Fire
    component_trace = _Fire(component, args, context, name)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\site-packages\fire\core.py", line 366, in _Fire
    component, remaining_args)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\site-packages\fire\core.py", line 542, in _CallCallable
    result = fn(*varargs, **kwargs)
  File "jukebox/sample.py", line 276, in run
    save_samples(model, device, hps, sample_hps)
  File "jukebox/sample.py", line 181, in save_samples
    vqvae, priors = make_model(model, device, hps)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 195, in make_model
    priors = [make_prior(setup_hparams(priors[level], dict()), vqvae, 'cpu') for level in levels]
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 195, in <listcomp>
    priors = [make_prior(setup_hparams(priors[level], dict()), vqvae, 'cpu') for level in levels]
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 179, in make_prior
    restore_model(hps, prior, hps.restore_prior)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 55, in restore_model
    checkpoint = load_checkpoint(checkpoint_path)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\make_models.py", line 34, in load_checkpoint
    download(gs_path, local_path)
  File "c:\users\fynda\projects\ml\jukebox\jukebox\utils\gcs_utils.py", line 36, in download
    subprocess.call(args)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\subprocess.py", line 339, in call
    with Popen(*popenargs, **kwargs) as p:
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\subprocess.py", line 800, in __init__
    restore_signals, start_new_session)
  File "C:\ProgramData\Anaconda3\envs\jukebox\lib\subprocess.py", line 1207, in _execute_child
    startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified

I have everything installed and when I load all the models to my /.cache director from google static storage download I get this error. Seems to be something to do with importing fire in the sample.py

I am running on Windows 10 with Anaconda3 and have wget installed to windows git bash.

Not running on a linux environment...

I have 2 Nvidia RTX 2080 TI cards working on CUDA with lots of memory.
64 GB RAM
i9 CPU 5.0GHz

Saw other issues like this occur in the google collab / jupyter book and said something about wget which shouldn't be an issue? Can't run wget in my Anaconda prompt locally. Is this causing the error? What's the easiest way to add the wget cmd to the bin for anaconda3? Is this the right solution?

You sould use windows 8.

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

5 participants