Closed cmbant closed 2 months ago
Attention: Patch coverage is 92.59259%
with 2 lines
in your changes missing coverage. Please review.
Please upload report for BASE (
master@660e0fa
). Learn more about missing BASE report.
Hi @cmbant, yes your code seems to reproduce what we have in the master. The current structure for effects like calibrations, polarization angles and systematic template is to call the corresponding classes in syslibrary, the library for systematic effects, as developed by @mgerbino. I guess we can have a discussion about implementing these functions directly in mflike if that is more convenient from a computational point of view (@mgerbino, @paganol, @erminiacalabrese, @xgarrido)
Thanks for checking. The others probably make more sense to have separately. This was particularly odd a) because calibrations have a trivial structure and you could argue about whether it is a systematic (and certainly isn't a residual), and b) the introspection in set_defaults() etc was being done once per call rather than at initialization, i.e. it didn't really seem to fit the structure.
(Is there an explanation somewhere of why the model.py introspections for changing defaults are needed at all? Anything like this makes it much harder for IDE tools to navigate the code/automatically check for bugs, as well as harder to understand)
I found the calibration code quite hard to understand, esp. why per likelihood it was instantiating a "residual" class in a systematics library. This just does it directly (assuming I correctly understood the original..). Rotation_alm is then not needed, and should also be faster/many fewer temporary memory allocations.