-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: interpolation between models supported
Interpolations between Kurucz format models are now available, and the code will judge autometically whether interpolation is required based on Delaunay triangulation. fix #9
- Loading branch information
1 parent
d4bff85
commit 8641d5d
Showing
27 changed files
with
8,064 additions
and
8,888 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
#!/usr/bin/python | ||
# The deprecate functions are stored here. | ||
# WARNING: the depandence of the functions here are not supported. | ||
from PyAstronomy import pyasl | ||
import os | ||
|
||
MOOG_path = '{}/.pymoog/moog_nosm/moog_nosm_FEB2017/'.format(os.environ['HOME']) | ||
MOOG_run_path = '{}/.pymoog/rundir/'.format(os.environ['HOME']) | ||
MOOG_file_path = '{}/.pymoog/files/'.format(os.environ['HOME']) | ||
|
||
def KURUCZ_download(teff, logg, m_h, save_name=None): | ||
''' | ||
Download the Kurucz ATLAS9 model using pyasl. | ||
Parameters | ||
---------- | ||
teff : int | ||
The effective temperature of the model | ||
logg : float | ||
logg value of the model | ||
m_h : float | ||
[M/H] value (overall metallicity) of the model | ||
save_name : str | ||
The path to save the model file (including the name). | ||
Returns | ||
---------- | ||
self.model_path : str | ||
The path and name of saved model. | ||
''' | ||
|
||
# The model is invoked here | ||
model = pyasl.getKuruczModel(teff, logg, m_h) | ||
|
||
# Save the model file to specified position | ||
if save_name == None: | ||
output_file_name = MOOG_run_path + 'model.mod' | ||
else: | ||
output_file_name = save_name | ||
output_file = open(output_file_name,"w") | ||
|
||
for line in model: | ||
output_file.write(line + "\n") | ||
|
||
output_file.close() | ||
|
||
model_path = output_file_name | ||
return model_path |
Oops, something went wrong.