Fix Version/s: None
Sprint:Alert Production S17 - 3
When an lsst.afw.geom.Transform is constructed from an astshim.FrameSet the internal frames in the frame set are lost. I strongly suspect what is happening is that the mapping constructor of Transform is being called, instead of the FrameSet constructor. Reversing the order in the pybind11 wrapper file should fix the problem. A unit test is required.
- is blocked by
DM-9899 FrameSet.permAxes will fail if nIn != nOut
I requested a few changes on GitHub, but overall looks nice. I especially like the extra testing infrastructure you added to test_transform.py.
Thank you for your very helpful review. I feel test_transform.py is much better based on your suggestions and some of the documentation should also be clearer. I have rebased the changes and will merge to master once a Jenkins run passes.
Transform(FrameSet) was never called in Python, because
Transform(Mapping) was listed first in the pybind11 wrapper,
and so was always called.
Fixing this turned up several bugs in normalizing frames:
were fooled when a FrameSet was passed in as a Frame.
was called on the frame argument, rather than a copy
when the frame was a FrameSet.
I added tests for all this in tests/test_transform.py. I'm afraid that file is getting rather large, but I'm not sure what to do about it. Perhaps some refactoring could make it smaller.
I also replaced all usage of self.assertTrue(numpy.allclose(...)) with numpy.testing.assert_allclose(...) as a separate commit.