mcyc / mufasa

MUlti-component Fitter for Astrophysical Spectral Applications
GNU General Public License v3.0
0 stars 2 forks source link

Filenames of additional maps are identical if 'para' is not included in paraNameRoot #8

Closed taiwithers closed 2 years ago

taiwithers commented 2 years ago

In the master_fitter method save_best_2comp_fit the savename variable assumes 'para' is in the user-provided paraNameRoot and provides no warning if this is not the case. If 'para' is not included, every map using that convention for generating a filename is stored under the same name, overwriting each of them. An alternative solution would be to instead of replacing 'para' with the desired name, simply appending the desired name onto the end of paraNameRoot. Lines using this convention: 302, 306, 311, 326, 331, 337, 347, 350

mcyc commented 2 years ago

Thanks for the suggestion and for catching that oversight. I've addressed this issue in 13784ab49d95214c593282246b508171b226406d by simply appending the desired name onto the end of the paraNameRoot if paraNameRoot doesn't contain strings that are "parameters", "parameter", or "para". If paraNameRoot does contain these three exact strings, these strings will be replaced with the key associated with the map to be saved (e.g., "lnk21").