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

Consistency across hardware #39

Open
curtispuetz opened this issue Sep 15, 2024 · 0 comments
Open

Consistency across hardware #39

curtispuetz opened this issue Sep 15, 2024 · 0 comments

Comments

@curtispuetz
Copy link

curtispuetz commented Sep 15, 2024

Can you get consistent noise generation across different hardware by specifying a seed?

I have one computer where I use import random; random.seed(1234) to set the seed and the perlin noise generated is always the same. But with the same seed on another computer, the perlin noise is like-wise always the same, but different from the first computer.

For instance

import random
from noise import pnoise2

random.seed(1234)
perlin_base = random.randint(0, 2000)

result = pnoise2(
    0.01,
    0.01,
    octaves=6,
    persistence=0.2,
    lacunarity=2.0,
    base=perlin_base,
)

print(result)  # Result is -0.013092000968754292 on computer 1, and -0.013136674650013447 on computer 2
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