You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Clarify behavior on standard deviations with <1 degree of freedom and silence some unit test warnings (#2357)
Summary:
## Motivation
Unit tests were producing a lot of warnings about taking standard deviations across fewer than 2 observations, and it was not clear to me if these warnings were legitimate in context.
* For checking the standardization of input data, no longer check the standard deviation if there is just one observation.
* For the standardize input transform, explicitly set standard deviations to 1 when there is only one observation. This actually matches the legacy behavior, but previously it wasn't clear because the standard deviation would become NaN before being corrected to 1.
* Error on attempting to standardize 0 observations. This never worked so now it is more clear.
Pull Request resolved: #2357
Test Plan:
Added units
## Related PRs
Reviewed By: Balandat
Differential Revision: D57931412
Pulled By: esantorella
fbshipit-source-id: 36a9c81a950a0b92749673fdd22aec62b45aaae9
0 commit comments