Currently there is a feature for the optional dependency rand in the simba crate. However, only the scalar types implement the traits from rand.
I don't see a reason why the Distribution trait can't be implemented with the SIMD types for Standard, such as AutoSimd. The implementation would simply generate a random value for each of the lanes of the SIMD vector. This is pretty easy to implement since impls already exist for every type used as a SIMD element.
Implementing this would allow better integration with the rand crate which is already an optional dependency.
Currently there is a feature for the optional dependency
rand
in the simba crate. However, only the scalar types implement the traits fromrand
.I don't see a reason why the
Distribution
trait can't be implemented with the SIMD types forStandard
, such asAutoSimd
. The implementation would simply generate a random value for each of the lanes of the SIMD vector. This is pretty easy to implement since impls already exist for every type used as a SIMD element.Implementing this would allow better integration with the
rand
crate which is already an optional dependency.