stam.utils.write_config
- stam.utils.write_config(config_file='config.ini', log_path='./log/', log_console_level='INFO', log_file_level='DEBUG', general_save='TRUE', general_path='.', general_output_type='csv', general_csv_format='.8f', gaia_path='./Gaia/', gaia_file='Gaia.fits', gaia_correct_extinction='TRUE', binary_consider_twins='TRUE', binary_flux_ratio_min=1.9, binary_flux_ratio_max=2, models_source='PARSEC', models_m_min=0.15, models_m_max=1.05, models_m_step=0.05, models_age=5, models_mh_pre_ms=0.7, models_smooth='True', models_smooth_sigma=3, models_exclude_pre_ms_masses=[], parsec_path='./PARSEC/', interp_method='rbf', interp_rbf_fun='linear', mass_n_realizations=10, mh_n_realizations=10)[source]
- write_config(config_file=”config.ini”,
log_path=”./log/”, log_console_level=”INFO”, log_file_level=”DEBUG”, general_save=”TRUE”, general_path=”.”, general_output_type=”csv”, general_csv_format=”.8f”, gaia_path=”./Gaia/”, gaia_file=”Gaia.fits”, gaia_correct_extinction=”TRUE”, binary_consider_twins=”TRUE”, binary_flux_ratio_min=1.9, binary_flux_ratio_max=2, models_source=”PARSEC”, models_m_min=0.15, models_m_max=1.05, models_m_step=0.05, models_age=5, models_mh_pre_ms=0.7, models_smooth=”True”, models_smooth_sigma=3, models_exclude_pre_ms_masses=[], parsec_path=”./PARSEC/”, interp_method=”rbf”, interp_rbf_fun=”linear”, mass_n_realizations=10, mh_n_realizations=10)
Write config file.
- Parameters:
config_file (str, optional) – The configuration file name, including path (default: “config.ini”).
log_path (str, optional) – Log file path (default: “./log/”).
log_console_level (str, optional) – Console log level (DEBUG, INFO, WARNING, ERROR, CRITICAL; default: “INFO”).
log_file_level (str, optional) – File log level (DEBUG, INFO, WARNING, ERROR, CRITICAL; default: “DEBUG”).
general_save (str, optional) – save results to file? (default: “TRUE”).
general_path (str, optional) – Result file destination path (default: “.”).
general_output_type (str, optional) – Output type (npy, csv; default: “csv”).
general_csv_format (str, optional) – CSV format (without “%”; default: “.8f”).
gaia_path (str, optional) – Path to Gaia data folder (default: “./Gaia/”).
gaia_file (str, optional) – Gaia data file name (only works for FITS files; default: “Gaia.fits”).
gaia_correct_extinction (str, optional) – Correct Gaia data for extinction? (default: “TRUE”).
binary_consider_twins (str, optional) – Consider equal-mass binary sequence when assigning mass/metallicity/age? (default: “TRUE”).
binary_flux_ratio_min (float, optional) – Minimal binary twin flux ratio (default: 1.9).
binary_flux_ratio_max (float, optional) – Maximal binary twin flux ratio (default: 2).
models_source (str, optional) – Which isochrone models to use? (default: “PARSEC”).
models_m_min (float, optional) – Minimum track mass in Msun (default: 0.15).
models_m_max (float, optional) – Maximum track mass in Msun (default: 1.05).
models_m_step (float, optional) – Track mass step in Msun (default: 0.05).
models_age (float, optional) – Age of the MS tracks in Gyr (default: 5).
models_mh_pre_ms (float, optional) – Pre-MS track [M/H] metallicity (default: 0.7).
models_smooth (str, optional) – Smooth track? (default: “TRUE”).
models_smooth_sigma (float, optional) – Gaussian smoothing sigma (default: 3).
models_exclude_pre_ms_masses (list, optional) – Exclude the pre-MS tracks of these masses in Msun (to avoid crossing other tracks), leave empty to include all (default: []).
parsec_path (str, optional) – Path to the PARSEC *.dat tables (concatenates all *.dat files in the folder to a single table) (default: “./PARSEC/”).
interp_method (str, optional) – Interpolation method (rbf, griddata, nurbs; default: “rbf”).
interp_rbf_fun (str, optional) – SciPy’s RBF interpolation function (default: “linear”).
mass_n_realizations (float, optional) – Number of realizations for mass assignment (default: 10).
mh_n_realizations (float, optional) – Number of realizations for metallicity assignment (default: 10).