Open hamogu opened 1 year ago
This functionality is available through SIMPUT. Marx has a SIMPUT source and SIMPUT does provide exactly this functionality. It's a little more work to set up then using a build-in marx source, but I'd prefer not to duplicate existing functionality if I can avoid it. While it's not hard in principle to modify the IMAGE source for this, there are restrictions: Which WCS systems should be supported? TAN projection is relatively easy, but how about others? Do I re-implement here or use WCSlib as an additional dependency? I'll close this as "won't do", but it could be resurrected if a use case that cannot be covered by SIMPUT emerges.
Hmm. If I build marx agains the CIAO libraries, then I have access to the WCSlib which would make this much easier to implement. In that case, it might be worthwhile to have this natively in marx without requiering SIMPUT.
The existing image source only uses the pixel scale from the WCS in the image, but always assumes that the center of the input image is at the optical axis of marx. That's done as a convenience for a typical use case: Take an observed image from one source and use it as input to simulate the same spatial distribution, but a different detector, different exposure time, or different position on the sky.
However, that leads to annoying side effects:
So, I should make a new source class. Name open for discussion, but something like "S-Image-WCS".