Closed mcara closed 1 year ago
Why won't the CI tests run?
The CI needed a manual restart. It was disabled because of inactivity for more than 60 days.
Tests are failing
@nden fixed
Patch coverage: 91.66%
and project coverage change: +0.59%
:tada:
Comparison is base (
4a27b3b
) 65.09% compared to head (d841821
) 65.68%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Can you add a test? Perhaps one of the examples in the tickets.
It would be nice to indicate what the current tolerance corresponds to in arcseconds in the event that HST7 has sufficient resolution to care.
I hope the code in the graph
could be fixed or significantly improved by the time HST7
is launched.
@perrygreenfield Please verify these handwaving calculations:
Assuming dx
is along a circle and dy=dz=0
, 5e-9
is in radians (when dx
is small), and so, converting this to acrseconds:
(180/pi)*3600*5e-9 = 0.0010313 arcsec
If all directions are allowed for errors (dy!=0
and dz!=0
), then we could increase the above estimate by sqrt(3)<2
or so. Then, let's say if vertices are closer to each other by less than 0.002 arcsec, then we will consider two polygons to be the same polygon.
In terms of JWST pixel scale of 0.11 arcsec, this is 1/50 of a pixel and on the surface of the Earth (mean R), this would be equivalent to two vertices being closer than about 3 mm
.
Does this seem reasonable?
Yes, that seems reasonable, though the combined error would be more like sqrt(2) larger than for one dimension (the three coordinates are constrained to be on the surface of a sphere). Actually, this may be large enough for HST2 or HST3 to worry about. Hopefully you will fix the bug by then (they being multiple decades away).
Yes, that seems reasonable, though the combined error would be more like sqrt(2) larger than for one dimension (the three coordinates are constrained to be on the surface of a sphere).
I agree. I just wanted to be very conservative.
Actually, this may be large enough for HST2 or HST3 to worry about. Hopefully you will fix the bug by then (they being multiple decades away).
My hope was that you were the last person to look at the multi_union
and Graph
code... 🤞
Based on @perrygreenfield comment, adjusted tolerance estimate is:
If vertices are closer to each other by less than 0.0015 arcsec, then we will consider two polygons to be the same polygon.
In terms of JWST pixel scale of 0.11 arcsec, this is 1/75 of a pixel and on the surface of the Earth (mean R), this would be equivalent to two vertices being closer than about 2 mm
.
JWST pipeline regression tests are running here: https://plwishmaster.stsci.edu:8081/job/RT/job/JWST-Developers-Pull-Requests/814/
Should anything be added to the documentation, explaining the choice of the tolerance value?
Closes #232 Closes #209
Both #232 and #209 report the same error that occasionally may happen when computing a
multi_union()
. #232 reports that this is happening when some of the input polygons are nearly identical (having very close to each other vertices).This PR, while not a real fix to the root-cause of the bug (or likely accuracy limitation) in the
graph
code, it provides a workaround that could help while the graph code is being investigated.