You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I came across the MultipleImageHelper code while looking through the InterpolatedImage files to see what might be required to add InterpolatedKImage (ala #642), and also while thinking of profiles that are built up as series expansions (ala #628). I can't actually figure out how to use it though.
In both cases, I suspect it has something to do with me providing a python list where the c++ is expecting a std::vector, which apparently isn't compatible. My boost-fu ends about there though.
I tried grepping around for all the instances of _galsim.SBInterpolatedImage, and as far as I can tell the multi image machinery is never used or tested in any .py files. Did this get abandoned?
The text was updated successfully, but these errors were encountered:
No, it never really got used. I think Gary's idea about this was that you might want to have an object modeled as a weighted sum of several different images, and then reweight them on the fly, say to derive best fit parameters of a decomposition for instance. @gbernstein please correct me if I'm wrong here.
But we never really used it that way, and honestly, I think that kind of functionality (e.g. #628) is better implemented in the python layer by making sums of profiles (not all of which need to be InterpolatedImages). Our code for rendering sums with arbitrary scalings is I think just as efficient as what you would get by using the MultiplImageHelper, and more flexible as well.
So my inclination would be to just remove the MultipleImageHelper class and only have SBInterpolatedImage be constructible from a single image.
Then for the InterpolatedKImage, I was thinking we could add a boolean argument is_k_image that would basically swap the roles of XTable and KTable in the constructor. I'm sure there are some other tweaks that would be required as well, but that was my thought for the starting point.
you might want to have an object modeled as a weighted sum of several different images, and then reweight them on the fly
That's the exact application I had in mind.
Our code for rendering sums with arbitrary scalings is I think just as efficient
Ok. I was hoping for some magic performance enhancement. I'll try out galsim.Sum instead though.
Then for the InterpolatedKImage, I was thinking we could add a boolean argument is_k_image that would basically swap the roles of XTable and KTable in the constructor.
I guess you'd need to be able to pass in both the real and imaginary kimages at the very least (and maybe assert that this makes a Hermitian complex kimage). That's a comment for a different branch though. Closing this.
I came across the MultipleImageHelper code while looking through the InterpolatedImage files to see what might be required to add InterpolatedKImage (ala #642), and also while thinking of profiles that are built up as series expansions (ala #628). I can't actually figure out how to use it though.
This much seems to work:
but then I can't figure out how to pass this to SBInterpolatedImage:
Similarly, I can't figure out how to create a MultipleImageHelper that actually handles multiple images:
In both cases, I suspect it has something to do with me providing a python list where the c++ is expecting a std::vector, which apparently isn't compatible. My boost-fu ends about there though.
I tried grepping around for all the instances of
_galsim.SBInterpolatedImage
, and as far as I can tell the multi image machinery is never used or tested in any .py files. Did this get abandoned?The text was updated successfully, but these errors were encountered: