Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Updates the
autogalaxy.convert
package with the following additional checks:When
ell_comps
of a mass profile or light are converted to anangle
, theangle
must be between -45.0 and 135.0 degrees without a loop at the boundaries.When
gamma_1
andgamma_2
of a shear are converted to a shearangle
, theangle
must be between -45.0 and 135.0 degrees without a loop at the boundaries.When
multipole_comps
are converted tophi_m
, the multipole angle, it must be between values which again removing a boundary loop.All checks ensure that when these values are computed to estimate their errors from a non-linear search, the estimation does not cycle around a boudnary and bias the inferred value.
This PR also adds docstrings.
Thank you @samlange04 for doing the hard work of figuring out the required conversions!