bench: refactor random number generation in stats/base/dists/weibull#5011
bench: refactor random number generation in stats/base/dists/weibull#5011ShabiShett07 wants to merge 2 commits intostdlib-js:developfrom
stats/base/dists/weibull#5011Conversation
Coverage Report
The above coverage report was generated for the changes in this PR. |
|
Can you please change the title to: bench: refactor random number generation in |
|
Also, I am not sure if you have the most recent changes in your current branch. Try to update your branch with the latest changes so you can also apply the required changes to all the |
stats/base/dists/weibullstats/base/dists/weibull
|
Hey @anandkaranubc, Thank you for reviewing my PR. |
| len = 100; | ||
|
|
||
| x = new Float64Array( len ); |
There was a problem hiding this comment.
| len = 100; | |
| x = new Float64Array( len ); | |
| len = 100; | |
| x = new Float64Array( len ); |
No space between initializations
| b.tic(); | ||
|
|
||
| for ( i = 0; i < b.iterations; i++ ) { |
There was a problem hiding this comment.
| b.tic(); | |
| for ( i = 0; i < b.iterations; i++ ) { | |
| b.tic(); | |
| for ( i = 0; i < b.iterations; i++ ) { |
| b.tic(); | ||
|
|
||
| for ( i = 0; i < b.iterations; i++ ) { |
There was a problem hiding this comment.
| b.tic(); | |
| for ( i = 0; i < b.iterations; i++ ) { | |
| b.tic(); | |
| for ( i = 0; i < b.iterations; i++ ) { |
| b.tic(); | ||
|
|
||
| for ( i = 0; i < b.iterations; i++ ) { |
There was a problem hiding this comment.
| b.tic(); | |
| for ( i = 0; i < b.iterations; i++ ) { | |
| b.tic(); | |
| for ( i = 0; i < b.iterations; i++ ) { |
This change is required throughout the PR.
| lambda = new Float64Array( len ); | ||
| k = new Float64Array( len ); | ||
| for ( i = 0; i < len; i++ ) { | ||
| t[ i ] = uniform( EPS, 2.0 ); |
There was a problem hiding this comment.
| t[ i ] = uniform( EPS, 2.0 ); | |
| t[ i ] = uniform( EPS, 1.0 ); |
Make sure the minimum and maximum values in the uniform expressions are no different than the original ones.
| for ( i = 0; i < len; i++ ) { | ||
| t[ i ] = uniform( EPS, 2.0 ); | ||
| lambda[ i ] = uniform( EPS, 2.0 ); | ||
| k[ i ] = uniform(1.0, 2.0); |
There was a problem hiding this comment.
| k[ i ] = uniform(1.0, 2.0); | |
| k[ i ] = uniform( 1.0, 2.0 ); |
This still needs to be addressed. |
|
Ref: #5342 |
|
Thank you for working on this pull request. However, we cannot accept your contribution as the issue this pull request seeks to resolve has already been addressed in a different pull request or commit. Thank you again for your interest in stdlib, and we look forward to reviewing your future contributions. |
Resolves #4992
Description
This pull request:
stats/base/dists/weibull#4992Related Issues
This pull request:
stats/base/dists/weibull#4992 [RFC]: Refactor random number generation in JS benchmarks forstats/base/dists(tracking issue) #4993Questions
What about the benchmark of ctor? Do we need to change that too?
Other
No.
Checklist
@stdlib-js/reviewers