Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add albedo correction #128

Open
samaloney opened this issue Nov 9, 2023 · 9 comments · May be fixed by #161
Open

Add albedo correction #128

samaloney opened this issue Nov 9, 2023 · 9 comments · May be fixed by #161

Comments

@samaloney
Copy link
Collaborator

Describe the feature

A few people have been asking if we have implemented the albedo correction similar to OSPEX

Proposed solution

No response

@settwi
Copy link
Contributor

settwi commented Nov 9, 2023

I think that would be an excellent addition. I believe OSPEX implements it as a “pseudo-model” but it shouldn’t be too hard to add if we look up the proper equations.

@KriSun95
Copy link
Collaborator

This has been on my to-do list for a while, I've just never been able to get around to it properly.

I think OSPEX does it via altering the response matrix before the fit and I think the main files to look at are drm_albedo.pro and drm_correct_albedo.pro (found here with some description).

Instructions on how the user interacts with this in OSPEX and some history is here.

@samaloney
Copy link
Collaborator Author

Yea those sav files are nightmare fuel do we have any idea how they were generated? @KriSun95 I think you are correct about the current implementation/approach here's the relevant paper but not clear if that the best way or have a model chain physical-model->albedo-model->SRM

@KriSun95
Copy link
Collaborator

KriSun95 commented Dec 7, 2023

@samaloney, I think your idea of physical-model->albedo-model->SRM makes more sense to me. I don't like the idea of editing the response any more than we really need to while having the correction as a model will help keep things transparent and make it easier to apply to different data too, I'd imagine.

@samaloney
Copy link
Collaborator Author

For RHESSI the albedo correction is included as part of the DRM, the logic being that it's not the observed spectrum I_O you want to fit but the emitted I_E where I_0=I_E + I_A. At the GX_SIMULATOR meeting and found out Edward/Gelu have implemented the Albedo correction as an addition to the model spectrum so we should be able to use the same approach https://github.com/Gelu-Nita/GX_SIMULATOR/blob/d772a411705ceed9db2a5b6eadfa14cd5dda190f/userslib/xray/xray_tt_albedo.pro

@edkontar
Copy link

Green function matrices are now available in JSON format (also as IDL SAVE files) https://github.com/edkontar/albedo

@settwi
Copy link
Contributor

settwi commented Sep 11, 2024

@edkontar thanks, Eduard! this will be very useful for albedo corrections going forward.

would you like to help implement the corrections in Python?

@edkontar
Copy link

would you like to help implement the corrections in Python?

Yes, I would be happy to help

@samaloney
Copy link
Collaborator Author

I have a draft PR open which uses the sav files from SSW in #161

What we eventually need is the ability to generate the "green's matrices"

@samaloney samaloney linked a pull request Sep 12, 2024 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants