-
Notifications
You must be signed in to change notification settings - Fork 1
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
rationalize the considered redshift when computing physical parameters or fit IR #258
Comments
Bug has been resolved in the main. Still, it could be nice to rationalize this part as proposed. |
Can closest_red remain the closest to us, and consiz be used for closest to
anything you want.... I would like closest,_red to not change meaning in
the middle of the code
Le mer. 18 déc. 2024, 15:52, Olivier Ilbert ***@***.***> a
écrit :
… Bug has been resolved in the main. Still, it could be nice to rationalize
this part as proposed.
—
Reply to this email directly, view it on GitHub
<#258 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAEPCYMYB3QIYMTVYOKEWNT2GGD2HAVCNFSM6AAAAABTYFFVI6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNJRGUYTSNRSGI>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Now methz is a book, nit a string
Le mer. 18 déc. 2024, 20:16, Johann cohen-tanugi <
***@***.***> a écrit :
… Can closest_red remain the closest to us, and consiz be used for closest
to anything you want.... I would like closest,_red to not change meaning in
the middle of the code
Le mer. 18 déc. 2024, 15:52, Olivier Ilbert ***@***.***> a
écrit :
> Bug has been resolved in the main. Still, it could be nice to rationalize
> this part as proposed.
>
> —
> Reply to this email directly, view it on GitHub
> <#258 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AAEPCYMYB3QIYMTVYOKEWNT2GGD2HAVCNFSM6AAAAABTYFFVI6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNJRGUYTSNRSGI>
> .
> You are receiving this because you are subscribed to this thread.Message
> ID: ***@***.***>
>
|
The variable closest_red is the redshift in the zgrid which is the closest to one you're interested in (that you provide in input of the function). |
When trying to simplify this part, I ended up adding more complexity than what is currently in the code (It would need to pass the zgrid to the valiLib function, and create a zLibIR for the fulllibIR library). I think it's not worth it. So, I am in favor of closing directly this issue. |
Here is a description of the various parts in which we set the considered redshift.
A possible problem arise when we use the median of the PDF to compute physical parameters. Need to check if it is not a bug.
At the end, I put few ideas to rationalize this part.
In run_photoz in photoz_lib.cpp
Not sure why doing that all the time, specially when ZFIX=NO. I have the impression that it could be done only when zfix true.
In PhotoZ::run_photoz
When we fit the IR part, the consiz is already set to the value we want (spec-z, zp min chi2, or zp med PDF).
Then we set oneObj->closest_red to the redshift of the grid corresponding to consiz which is correct.
In onesource::fitIR, need the closest_red to select the item in the IR library at the same redshift than the general grid.
// Loop over all SEDs from the library
for (size_t i = 0; i < fulllibIR.size(); i++) {
if (fulllibIR[i]->red == closest_red) {
We could use something more robust with
abs(fulllibIR[i]->red - closest_red) < 1.e-10
In PhotoZ::run_photoz
I think we are missing something here !!!!
We need to call valLib to set the valid vector. It was correct before the existence of validLib, but not anymore.
We are probably missing a line like:
In order to do the fit only when the grid goes through closest_red.
GENERAL In order to rationalize:
The text was updated successfully, but these errors were encountered: