Closed ajvanengelen closed 5 years ago
I turned off the pathway to the bug for now, raising an excepttion if that routine is called without a predetermined (shape, wcs): https://github.com/ACTCollaboration/actsims/commit/358326047dd5b1ef02ef91350c61e6e77e3c34af
case closed
SignalGen.get_template gets its shape and wcs from data_model.get_mask, however this mask has a slightly different wcs compared to what is expected (but the same shape). This leads to an assertion error at line 117 of simgen.py:
117 assert wcsutils.equal(owcs,noises.wcs)
For the patch I am using the mask is /global/project/projectdirs/act/data/spartial_window_functions/mr3c_20181012_190203/deep5_mr3c_20181012_190203_master_apo_w0.fits' and this has a slightly different wcs (different
crpix
) compared to the noise template.Now the bug seems to be, if no one ever calls get_template, then the wcs defaults to what the code expects. But otherwise it gets the wcs info from the mask file, and this throws the assertion failure later on.
I am pretty sure that if we change the details of SignalGen.get_template to something that matches the wcs of everything else, it will be fine.