Closed sschmidt23 closed 1 year ago
Patch coverage: 100.00%
and project coverage change: +0.04%
:tada:
Comparison is base (
a2f2546
) 95.38% compared to head (eb08ead
) 95.43%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Sorry, what I was referring to was just that this PR (like future bugfixes that arise from discoveries along the way to pipeline development/validation) ought to have included the addition of a unit test of the edge that triggered the problem that was fixed. @sschmidt23 Would you mind writing one on the same branch you used for this PR?
Ok, that makes sense, sorry for misunderstanding, a unit test is a good idea here. I'll add one soon.
This PR just adds a TEENY number to the distances in k_nearneigh, as when you have an exact match to a spectroscopic point (e.g. if you accidentally run with the same training and test data) you get a distance = 0 and because we have a weight = 1/dist factor you can get infs and/or NaNs. Adding TEENY to the distances makes sure we do not have a divide by zero.