jacopo-chevallard / BEAGLE-general

Basic information to get started with the galaxy spectral modelling tool Beagle
https://www.iap.fr/beagle/
9 stars 0 forks source link

Templates file "doesn't exist"? #35

Closed rmastand closed 7 years ago

rmastand commented 7 years ago

I've made a param file with:

TEMPLATES = BEAGLE_TEMPLATES/cb2013_s2_z001y250n_chab_hr_xmiless_ssp.4color
FILTERS FILE = $BEAGLE_FILTERS/filters_test.dat
PHOTOMETRIC CATALOGUE = $BEAGLE_DATA/test.csv  (my own data)
FIT PHOTOMETRY = T

The rest looks like the default file.

However, when I run BEAGLE, I get the following error:

[ERROR: The file: "BEAGLE_TEMPLATES/cb2013_s2_z001y250n_chab_hr_xmiless_ssp.4color" that 
         you want to copy does not exist! ]

This cannot be right, because this file does exist (I just checked that it is). Further, I'm sure the path to it is right (I have a bash file describing what BEAGLE_TEMPLATES it). Has this error come up before? Maybe something else in my params file is the cause of the error?

jacopo-chevallard commented 7 years ago

HI Radha, are you using the fit_photometry_example.param parameter file as a starting point for your parameter file? Since the TEMPLATES keyword must hold a file containing a list of the template SSPs, e.g.

TEMPLATES = $BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_chab_ssp

where the bc2003_hr_xmiless_chab_ssp file contains

$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m22_chab_ssp.ised      0.0001
$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m32_chab_ssp.ised      0.0004
$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m42_chab_ssp.ised      0.004
$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m52_chab_ssp.ised      0.008
$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m62_chab_ssp.ised      0.02
$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m72_chab_ssp.ised      0.05
$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_m82_chab_ssp.ised      0.1

Note also the missing dollar sign $ in front of the BEAGLE_TEMPLATES environment variable in your implementation (which was triggering the error your reported).

rmastand commented 7 years ago

Did as you suggested and got:

screen shot 2016-12-19 at 10 48 46 pm

The file cb2013_s2_chab_hr_xmiless_ssp looks like:

cb2013_s2_z0001y249n_chab_hr_xmiless_ssp.ised      0.0001
cb2013_s2_z0002y249n_chab_hr_xmiless_ssp.ised      0.0002
cb2013_s2_z0005y249n_chab_hr_xmiless_ssp.ised      0.0005
cb2013_s2_z001y250n_chab_hr_xmiless_ssp.ised       0.001
cb2013_s2_z002y252n_chab_hr_xmiless_ssp.ised       0.002
cb2013_s2_z004y256n_chab_hr_xmiless_ssp.ised       0.004
cb2013_s2_z006y259n_chab_hr_xmiless_ssp.ised       0.006
cb2013_s2_z008y263n_chab_hr_xmiless_ssp.ised       0.008
cb2013_s2_z010y267n_chab_hr_xmiless_ssp.ised       0.010
cb2013_s2_z014y273n_chab_hr_xmiless_ssp.ised       0.014
cb2013_s2_z017y279n_chab_hr_xmiless_ssp.ised       0.017
cb2013_s2_z020y284n_chab_hr_xmiless_ssp.ised       0.020
cb2013_s2_z030y302n_chab_hr_xmiless_ssp.ised       0.030

So there appears to be a mixup with cb and bc...I should note that all of my template files start with cb2013, not bc03/bc2003

rmastand commented 7 years ago

My main confusion is I'm not from what file it's pulling the TEMPLATES=$BEAGLE_TEMPLATES/bc03/bc2003_hr_xmiless_chab_ssp

jacopo-chevallard commented 7 years ago

Your file looks fine, the error you're getting says

 [ERROR: The results directory contains a parameter file which differs from the one you are  
         using in the current run. Please, specify a different results directory, or clean the 
         existing one from its content. ]

and indeed you should either clean the results directory, or select a new one (through the RESULTS DIRECTORY keyword in the parameter file)

rmastand commented 7 years ago

Fixes the error! Thank you!