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

ValueError: Unknown sample mode\. #123

Closed
kordspace opened this issue Jul 9, 2020 · 2 comments
Closed

ValueError: Unknown sample mode\. #123

kordspace opened this issue Jul 9, 2020 · 2 comments

Comments

@kordspace
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
SYSTEM_WGETRC = c:/progra~1/wget/etc/wgetrc
syswgetrc = C:\Program Files (x86)\GnuWin32/etc/wgetrc
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
SYSTEM_WGETRC = c:/progra~1/wget/etc/wgetrc
syswgetrc = C:\Program Files (x86)\GnuWin32/etc/wgetrc
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
SYSTEM_WGETRC = c:/progra~1/wget/etc/wgetrc
syswgetrc = C:\Program Files (x86)\GnuWin32/etc/wgetrc
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
SYSTEM_WGETRC = c:/progra~1/wget/etc/wgetrc
syswgetrc = C:\Program Files (x86)\GnuWin32/etc/wgetrc
Restored from C:\Users\marco/.cache\jukebox-assets/models/5b_lyrics/prior_level_2.pth.tar
Loading prior in eval mode
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 266, in save_samples
    raise ValueError(f'Unknown sample mode {sample_hps.mode}.')
ValueError: Unknown sample mode \.

So I was able to get my environment set up with GNUWin32 and wget but after I resolve that issue I get a string error from the certificate error in #92

After removing the certificate check I get the unknown sample error above. Any ideas?

@NoiseGener8r
Copy link

You can't actually have the backslash in the command. The way it is provided doesn't work properly because it's on two lines.
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
This is the correct command.

@kordspace
Copy link
Author

@NoiseGener8r Agh so stupid. I should have saw that. Thanks. That worked! Just need to configure my cards for CUDA.

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