Skip to content

Commit 3ca8bc2

Browse files
committed
Add benchmarks for Beta
1 parent 56d6ac2 commit 3ca8bc2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

rand_distr/benches/distributions.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
// except according to those terms.
88

99
#![feature(test)]
10+
#![feature(custom_inner_attributes)]
1011

1112
// Rustfmt slits many macro invocations to shorten lines; in this case longer-lines are more readable
1213
#![rustfmt::skip]
@@ -211,6 +212,10 @@ distr_float!(distr_normal, f64, Normal::new(-1.23, 4.56).unwrap());
211212
distr_float!(distr_log_normal, f64, LogNormal::new(-1.23, 4.56).unwrap());
212213
distr_float!(distr_gamma_large_shape, f64, Gamma::new(10., 1.0).unwrap());
213214
distr_float!(distr_gamma_small_shape, f64, Gamma::new(0.1, 1.0).unwrap());
215+
distr_float!(distr_beta_small_param, f64, Beta::new(0.1, 0.1).unwrap());
216+
distr_float!(distr_beta_large_param_similar, f64, Beta::new(101., 95.).unwrap());
217+
distr_float!(distr_beta_large_param_different, f64, Beta::new(10., 1000.).unwrap());
218+
distr_float!(distr_beta_mixed_param, f64, Beta::new(0.5, 100.).unwrap());
214219
distr_float!(distr_cauchy, f64, Cauchy::new(4.2, 6.9).unwrap());
215220
distr_float!(distr_triangular, f64, Triangular::new(0., 1., 0.9).unwrap());
216221
distr_int!(distr_binomial, u64, Binomial::new(20, 0.7).unwrap());

0 commit comments

Comments
 (0)