pytorch
af902102 - Fix discrete sampler test to correctly run Chi2 test (#73251)

Commit
2 years ago
Fix discrete sampler test to correctly run Chi2 test (#73251) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/73251 Scipy's chisquare test requires that the observed frequencies should sum up to the same number as the expected frequences. This modifies `_check_sampler_discrete` to ensure that two match. See: https://github.com/scipy/scipy/issues/12282 for details. Test Plan: Unit tests pass on platform010 Reviewed By: r-barnes Differential Revision: D34402314 fbshipit-source-id: 995b4ddf668cfb551176d3bd21fb8415dfe96cc1 (cherry picked from commit d81a133b0d2cdc621d08caf31afd69d716229b97)
Author
Neeraj Pradhan
Committer
Parents
Loading