Normally distributed MPSMatrixRandom number generation generates NaN

When generating large arrays of random numbers, NaNs show up. They also show up at the same indices when using the same seed, leading me to believe that this is a bug with MPSMatrixRandom's normally distributed Float32 random number distribution.

Happens with both Philox and MTGP32.

Is this intentional and how do I work around this?

See the original post for a MWE in Swift and Julia: https://github.com/JuliaGPU/Metal.jl/issues/474

Answered by DTS Engineer in 818341022

Hi, thank you for bringing this up.

To investigate this further please create a bug report with the Feedback Assistant and provide instructions on how to use Metal.jl to reproduce https://github.com/JuliaGPU/Metal.jl/issues/474.

If possible attach a sample project that reproduces the issue.

Hi, thank you for bringing this up.

To investigate this further please create a bug report with the Feedback Assistant and provide instructions on how to use Metal.jl to reproduce https://github.com/JuliaGPU/Metal.jl/issues/474.

If possible attach a sample project that reproduces the issue.

Normally distributed MPSMatrixRandom number generation generates NaN
 
 
Q