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

sampletype of Uniform #1406

Closed
jw3126 opened this issue Oct 15, 2021 · 2 comments
Closed

sampletype of Uniform #1406

jw3126 opened this issue Oct 15, 2021 · 2 comments

Comments

@jw3126
Copy link
Contributor

jw3126 commented Oct 15, 2021

It seems that Uniform always samples Float64?

using Distributions
@show typeof(rand(Normal(0f0, 1f0)))    # Float32 as expected
@show typeof(rand(Uniform(0f0, 1f0)))   # Float64 gotcha
@devmotion
Copy link
Member

Yes, this is intended. Actually, Normal is the odd fish here.

I'll close this since it is a duplicate of #1071.

@jw3126
Copy link
Contributor Author

jw3126 commented Oct 15, 2021

Ok 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