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

question on model generation / random seed. #14

Open
johndpope opened this issue Nov 12, 2021 · 0 comments
Open

question on model generation / random seed. #14

johndpope opened this issue Nov 12, 2021 · 0 comments

Comments

@johndpope
Copy link

johndpope commented Nov 12, 2021

I trained all day - and ran generator pointing to saved pytorch file / to spit out 5 files.
param_fp = f'checkpoints/save/20211112_074506/model/params.Generator.best_Convergence.torch'

is it a case that the model spits out will be same 5 times? is there a random seed that can be swiched in on each run to make different sounds ( explore latent space)?

UPDATE
woops just found this - need to update the readme to make it clear.

parser.add_argument(
    '--seed',
    dest='seed',
    default=123,
    help='Random seed. Default: 123'
)

the logic seems flawed - seems like each new sample will carry same seed?

# ### Process ###
torch.manual_seed(seed)
for ii in range(num_samples):
    print(f'Generate sample {ii}')

maybe something like

from random import randint

    for ii in range(num_samples):
        if seed != 123:
            torch.manual_seed(seed)
        else: 
            x = randint(0,1000000)
            torch.manual_seed(x)

doesn't seem to make a difference to the end generated mp3.
UPDATE
maybe there's something wrong with my training.

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

1 participant