Trace checking compares the results of the traced function to the actual function to make sure they are the same. It’s just a sanity check, but non-deterministic ops like randn_like() will cause trace checking to fail. This failure is expected, and if you really want to use non-determinism in your model then you can disable the trace checking as the warning says.