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

[Lang] Add ti.randn #2266

Merged
merged 9 commits into from
Apr 25, 2021
Merged

[Lang] Add ti.randn #2266

merged 9 commits into from
Apr 25, 2021

Conversation

victoriacity
Copy link
Member

@victoriacity victoriacity commented Apr 15, 2021

Related issue = #2251, close #2235


Adds ti.randn() to generate standard Gaussian random numbers. The implementation uses the Box-Muller transform. The implementation choice is made because:

The function is tested in the test_random suite by checking the accuracy 1st-4th moments with 1024^2 samples to the absolute error of 0.03.

@CLAassistant
Copy link

CLAassistant commented Apr 15, 2021

CLA assistant check
All committers have signed the CLA.

@yuanming-hu yuanming-hu requested a review from ljcc0930 April 16, 2021 08:47
Copy link
Contributor

@ljcc0930 ljcc0930 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@k-ye k-ye merged commit 3711a04 into taichi-dev:master Apr 25, 2021
@k-ye k-ye mentioned this pull request Apr 25, 2021
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

Successfully merging this pull request may close these issues.

Gaussian random number
5 participants