-
Notifications
You must be signed in to change notification settings - Fork 15
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
example_16: added color and negative blending prior #122
Conversation
…sources and color prior
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #122 +/- ##
==========================================
- Coverage 83.61% 83.59% -0.03%
==========================================
Files 52 52
Lines 8271 8313 +42
==========================================
+ Hits 6916 6949 +33
- Misses 1355 1364 +9
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There are a few things to discuss or modify:
|
@mjmroz If you want to finish this, then I suggest you start with 1st and 4th item on the list above. There is not much work needed. |
@mjmroz Did you need negative blending flux prior for more than one dataset? |
My only sugggestion to this new API is to replace source_number and similar words to source_flux or data_number or data_label, so it's not confused with having more than one source star. @mjmroz I have some minor suggestions to make the code more readable, we can chat in person if you want. |
Hi. |
Sorry, closed by mistake. Reopening. |
One more aspect that I think should be changed is how the user specifies datasets to be used. Instead of numbers (which are easy to confuse, e.g., when somebody adds a dataset to existing yaml file), I suggest to use labels that can be accessed via |
dataset for color and blending constrain can be define by index or lable
for i in arange(len(self._n_fluxes_per_dataset) - 1):
inside += self._sumup_inside_prior(fluxes, key, inside, i) |
@rpoleski Have you considered adding an option to declare different identifiers for datasets in the input YAML file that are not passed to MulensData.plot_properties['label']? One might need to have more than one dataset on the plot under one label but treat them differently in modeling. Which way of declaring color prior in the YAML file do you prefer?
or
|
Line 1525 says
No. It's not needed at this point. Preferred formats:
i.e., IDs instead of numbers and distribution clearly specified. One aspect is missing at this point: do we want flux ratio or magnitude difference? I'll be for the latter because that is what astronomers are used to. I also suggest:
|
I meant this line 1525 :) : As I wrote, it checks if one is trying to calculate color from the same datasets, for example, color = OGLE-I/OGLE-I. In our previous live conversation, when you asked if I have a check to ensure datasets' labels are different, I misunderstood you and thought you were asking about this one, so I said yes. I'm sorry for that. color: gauss 2.0 0.1 "OGLE V-band" "OGLE I-band" or:color: [gauss, 2.0, 0.1, OGLE V-band, "OGLE I-band"] The first option is now implemented, but it requires importing modules like shlex to deal with quotations inside a str. I will use the latter one. I'm using fluxes because it was the easiest way in my case. I needed a color prior when I was adding a second source to the model, so I already had results in fluxes for the first source. If you think it won't be the most common case, I will change to magnitudes or add an option for both: |
Current summary of what is missing:
Current format of input with shlex is ok. I've realized the other one (with a list) would require some more checks and there is no need for that now. |
Thanks for all these updates and for correcting older spelling errors. Two final corrections:
I'll merge this PR afterwards. Thanks once more. |
For both sources