-
Notifications
You must be signed in to change notification settings - Fork 4
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
How to add a BB model within speedyfit? #8
Comments
Hi,
Do you want to fit a binary of which one component is a BB (2 components
total) or fit a binary with a BB as an extra component (3 components total)?
In the first case, just specify blackbody as the atmosphere model to use,
and set logg to 5. Logg doesn't have an effect, but the algorithm needs a
value for it.
In the second case, I need to test how to do it.
Cheers
Joris
…On Sat, 4 Jun 2022, 13:09 AstroJLin, ***@***.***> wrote:
Hi,
How to an extra model of blackbody within SED using the speedyfit?
Thanks!
—
Reply to this email directly, view it on GitHub
<#8>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63C5DSAZEUUORIDKQD3VNM2OXANCNFSM5X3IVOLQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Ok, so in this situation you have a kurucz atmosphere for the star, and
want to add a BB model to simulate an accretion disc. So for speedyfit this
would be a standard binary fit where the logg of the secondary (the BB
model) is fixed cause the BB doesn't depend on logg.
Based on the image you include, it can very well be that the wise W3 and W4
are just not very accurate. It is possible a BB won't really help here. But
worth a try.
Last remark, it looks like the sdss photometry is far off. Maybe because
the target is too bright for sdss?
Hope this helps.
…On Sat, 4 Jun 2022, 17:26 AstroJLin, ***@***.***> wrote:
Hi Joris,
I want to fit a binary of which one component is a BB that may result from
accretion disk. Here, when I use a BB to fit my source, I find that the
WISE W3 and W4 band also have a very bad fit. Therefore, I want to add to a
BB within the model so that
see if it can fit well.
In addition, If I consider a BB from the accretion disk, should I use the
first case and does a the atmosphere model of star still apply?
Fitting results of the main sequence star model as follow:
[image: pic]
<https://user-images.githubusercontent.com/86318178/172011487-37364b94-0b9a-4fae-b4c3-53239ef8f0a8.png>
Thanks!
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63HXPQ5MTXBKNW64BGLVNNYQZANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Hi Joris, Here, I should how to set up to add BB model into the speedyfit (add BB model to **.yaml?). Could you give my a model of 2 components? This source has a V band magnitude of approximately 13.7, it may be too bright for sdss? Thanks! |
If you run
*speedyfit* setup <*object_name*> -grid binary
It will create a default setup file for a binary model with a hot and cold
component. You can then change the atmosphere models in the setup file to
kurucz and blackbody.
13.7 is probably on the edge for sdss. I am not 100% sure though. Best to
check sdss documentation.
Cheers
Joris
…On Sat, 4 Jun 2022, 18:12 AstroJLin, ***@***.***> wrote:
Hi Joris,
Thank you for your reply.
Here, I should how to set up to add BB model into the speedyfit (add BB
model to **.yaml?). Could you give my a model of 2 components?
This source has a V band magnitude of approximately 13.7, it may be too
bright for sdss?
Thanks!
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63HAF3KGEILBEDIYD3DVNN563ANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Sure, blackbody can go as low as 100 kelvin.
You have to adjust the limits. They are in the same order as the pnames. So
if you set the second atmosphere to blackbody, you have to change the line
[20000, 80000] to e.g. [500, 3000] to simulate a disc.
Cheers
Joris
…On Sat, 4 Jun 2022, 19:45 AstroJLin, ***@***.***> wrote:
Hi Joris,
Here, I try to use the grid binary model, but the model of blackbody seems
too hot for an accretion disc. Here, Is the speedyfit have able to set up a
cold temperature blackbody (e.g 2000-4000 K)?
If I'm not mistaken, it only be set up like this:
[image: Screenshot from 2022-06-05 01-34-44]
<https://user-images.githubusercontent.com/86318178/172019376-08e56c63-ffd1-4031-b881-013aeedbabc7.png>
Thanks!
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63GIELQUDNBMOIR4XEDVNOI2HANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Hi Joris, I try to adjust the limits ([500, 3000]), but the speedyfit throw an error. Could you tell me the reason for this error? The error is as follow: |
Can you send me the full setup file?
…On Sat, 4 Jun 2022, 20:23 AstroJLin, ***@***.***> wrote:
Hi Joris,
I try to adjust the limits ([500, 3000]), but the speedyfit throw an
error. Could you tell me the reason for this error?
My settings are as follows:
[image: Screenshot from 2022-06-05 02-22-57]
<https://user-images.githubusercontent.com/86318178/172020674-fde32d4b-f448-4d19-b8a9-1e061966dbc1.png>
The error is as follow:
/home/jlin/anaconda3/lib/python3.8/site-packages/secretstorage/dhcrypto.py:16:
CryptographyDeprecationWarning: int_from_bytes is deprecated, use
int.from_bytes instead
from cryptography.utils import int_from_bytes
/home/jlin/anaconda3/lib/python3.8/site-packages/secretstorage/util.py:25:
CryptographyDeprecationWarning: int_from_bytes is deprecated, use
int.from_bytes instead
from cryptography.utils import int_from_bytes
Going to read Vizier photometry catalog from
/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/vizier_cats_phot.cfg.
Going to read TAP photometry catalog from
/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/tap_cats_phot.cfg.
Applied constraints:
distance = 117.9704366085859 - 0.15447896544118625 + 0.15447896544118625
/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/interpol.py:79:
FutureWarning: Using a non-tuple sequence for multidimensional indexing is
deprecated; use arr[tuple(seq)] instead of arr[seq]. In the future this
will be interpreted as an array index, arr[np.array(seq)], which will
result either in an error or a different result.
pixelgrid[indices] = grid_data.T
Traceback (most recent call last):
File "/home/jlin/anaconda3/bin/speedyfit", line 8, in
sys.exit(main())
File "/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/main.py",
line 506, in main
args.func(args)
File "/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/main.py",
line 418, in perform_fit
results, samples, constraints, gridnames = fit_sed(setup, photbands, obs,
obs_err)
File "/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/main.py",
line 157, in fit_sed
grids = model.load_grids(gridnames, pnames, limits, photbands)
File
"/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/model.py", line
158, in load_grids
axis_values, grid_pars, pixelgrid, grid_names = prepare_grid(photbands,
name,
File
"/home/jlin/anaconda3/lib/python3.8/site-packages/speedyfit/model.py", line
188, in prepare_grid
lidx = np.abs(ext.data.field(name)[ext.data.field(name) <= low] -
low).argmin()
ValueError: attempt to get argmin of an empty sequence
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63G3K2Y7DJ5BAAPSCR3VNONKPANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Hi Joris, This is setup file! Thanks! |
Hi,
No, that is not a problem. All grids have their own wavelength scale. This
is taken into account when combining the grids.
You need to specify the correct grid in your input file. You can requesting
a TMAP model with a Teff between 500 - 3000 K, but TMAP is for hot stars
only. in the grid section, make sure the second one is called 'blackbody'.
You can find more detailed docs here:
https://speedyfit.readthedocs.io/en/stable/userguide/setup_file.html#fit-and-constraints-setup
Cheers
Joris
…On Sun, 5 Jun 2022 at 22:04, AstroJLin ***@***.***> wrote:
Hi Joris,
Here, I try to use the get_table_single of speedyfit.model to combine
'kurucz' and 'blackbody', but I discovery that the shapes of the array is
not consistent. Therefore, I guess the former error may be same this reason?
The error is as follow:
[image: Screenshot from 2022-06-06 03-56-48]
<https://user-images.githubusercontent.com/86318178/172068249-131e0538-9dee-4cb0-9ade-3d40401341b1.png>
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63DY5NK6CBZG5HOPAQTVNUB5PANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
m.v.g.
Joris Vos
|
Hi,
There is only very minor improvement in the fit: chi2 = 855.9 -> 853.8
Based on that I would argue that the BB doesn't add significant
contribution to the model, and can be removed.
On these figure the symbols have the following meaning:
lines: atmosphere model, these are approximations and only show to give the
user a rough idea. (not used in the fit)
circles: the observed fluxes (used in the fit)
crosses: the modelled fluxes (used in the fit) Because they are integrated
and due to the logarithmic scale, they can sometimes differ quite a bit
from the model shown by line. But the crosses are the actual best fitting
fluxes.
O-C means observed - calculated, so the difference between the observations
and the model. Warning: the O-C plot uses magnitudes as unit, because it is
clearer to see differences for all photbands than if fluxes were used. This
is due to fluxes spanning several orders of magnitudes.
Hope this helps!
…On Mon, 6 Jun 2022 at 11:58, AstroJLin ***@***.***> wrote:
Hi Joris,
Thank you for your help!
Here,I have the ability to fit the SED combining kurucz atmosphere and
blackbody. The result of combining kurucz atmosphere and blackbody model
fit well compared to the kurucz atmosphere. Do you think it is more
reasonable to add BB's model for fitting?
In addition, I don't understand what the symbol of the cross (×) on the
graph represents and what the C of O-C refers to the calculation result
from?
Thanks!
The result of kurucz atmosphere model:
[image: kurucz-model]
<https://user-images.githubusercontent.com/86318178/172139355-531d8776-c7b5-4c01-a9e9-342d300bfa03.png>
The result of combining kurucz atmosphere and blackbody model :
[image: kurucz+bb]
<https://user-images.githubusercontent.com/86318178/172139392-9a338c07-94ae-4578-8169-2ef1140c1991.png>
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63BFPVYVF3MHVKOMSCLVNXDTXANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
m.v.g.
Joris Vos
|
Hi, If the crosses is the modelled fluxes, then the WISE W3 is lower compare with the modelled fluxes. Why is W3 so low, what may be the reason for this, do you have any suggestions for this? Thanks! |
Hi,
I can't give you a direct answer to that question. There can be many
reasons why W3 is low. But I have seen this before, and it is likely
because the target is very close to the detection limit of WISE.
If you encounter strange or unexpected photometric values, it is best to
check the source catalog and see if there are any flags that can identify
problems. You can find the origin of each catalog in the user guide:
https://speedyfit.readthedocs.io/en/latest/userguide/photometry_catalogs.html
For WISE you can also have a look at the images from which the photometry
is derived. You can query them on:
https://irsa.ipac.caltech.edu/applications/wise/
Cheers
…On Mon, 6 Jun 2022 at 15:54, AstroJLin ***@***.***> wrote:
Hi,
Thank you for your reply again.
If the crosses is the modelled fluxes, then the WISE W3 is lower compare
with the modelled fluxes. Why is W3 so low, what may be the reason for
this, do you have any suggestions for this?
Thanks!
—
Reply to this email directly, view it on GitHub
<#8 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASU63BAIHA7LLGUG4OJ5IDVNX7JLANCNFSM5X3IVOLQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
m.v.g.
Joris Vos
|
Hi Joris, Thank you very much for your patience and help! |
No problem. Glad I could help. |
Hi,
How to an extra model of blackbody within SED using the speedyfit?
Thanks!
The text was updated successfully, but these errors were encountered: