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

Problem on varying specific_sfr parameter when fitting photometry #28

Closed mengtaotang closed 8 years ago

mengtaotang commented 8 years ago

Hello, I am using BEAGLE 0.7.2 to fit observed photometry of galaxies. I varied specific star formation rate (type:fitted) in the parameter file (included below), and I got the following error message when running BEAGLE:

% docker run --rm -it -v /home/mengtao/BEAGLE/BEAGLE-general:/BEAGLE_virtual_workdir --env-file env.list beagletool/beagle:0.7.2 --parameter-file /BEAGLE_virtual_workdir/params/test/fit_RB16.param --fit

 Reading Filter File: /BEAGLE_virtual_workdir/filters/FILTERBIN.RES
 271 filters defined, out of 500                                maximum     ...done
 ---> fixed                         sfh_type                                   0
 ---> fitted                        mass                                       0
 ---> fixed                         current_sfr_timescale                      0
 ---> fitted                        redshift                                   0
 ---> dependent                     nebular_Z                                  0
 ---> fixed                         attenuation_type                           0
 ---> fitted                        tauV_eff                                   0
 ---> fixed                         mu                                         0
 ---> fitted                        tau                                        1
 ---> fitted                        metallicity                                1
 ---> fitted                        specific_sfr                               1
 ---> fitted                        nebular_logU                               1
 ---> fitted                        nebular_xi                                 1
 n_fitted:            8
 *****************************************************
 MultiNest v3.9
 Copyright Farhan Feroz & Mike Hobson
 Release Oct 2014

 no. of live points =  150
 dimensionality =    8
 *****************************************************
 Starting MultiNest
 generating live points
 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
         [ERROR: Root must be bracketed between x1 and x2! ]
 [FUNCTION: "bisec_newton_raphson_sp" ]
 [MODULE: "lib_root_finding" ]
 [BACKTRACE:   
#0  0x7FFA14747E08
#1  0x6318FC in print_backtrace at lib_messages.f90:330
#2  0x665C42 in __lib_root_finding_MOD_bisec_newton_raphson_sp at lib_root_finding.f90:49
#3  0x47486F in fill_current_sfr_bin at star_formation.f90:1343
#4  0x42A62D in __galaxy_sed_MOD_compute_sed at galaxy_SED.f90:166
#5  0x4333C1 in __likelihood_function_MOD_likelihood at likelihood_function.f90:150
#6  0x436DD5 in __likelihood_function_MOD_mc_likelihood at likelihood_function.f90:89 (discriminator 4)
#7  0x4FE2A3 in __nested_sampling_MOD_getloglike at nested_sampling.f90:206 (discriminator 6)
#8  0x52BE90 in __nested_MOD_gen_initial_live at nested.F90:536
#9  0x52D60C in __nested_MOD_nestsample at nested.F90:352
#10  0x52E6A4 in __nested_MOD_nestrun at nested.F90:239
#11  0x4FE67C in __nested_sampling_MOD_run_nested_sampling at nested_sampling.f90:134
#12  0x4F3DD2 in __prosit_MOD_sample_pdf at PROSIT.f90:314
#13  0x406FF9 in MAIN__ at BEAGLE.f90:547
 ]
 [ ***************************************** ]
 [ ----> EXITING FUNCTION / SUBROUTINE <---- ]                
 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 [ ***** STOPPING PROGRAM ***** ]
Note: The following floating-point exceptions are signalling: IEEE_UNDERFLOW_FLAG IEEE_DENORMAL

Here is my parameter file:

# This is a stripped down version of the BEAGLE parameter file for 
# with checking the correct installation of BEAGLE using Docker.
# This file will be used for producing artificial photometry using
# an analytic star formation history.
# Verbose mode: 0 ---> no info
#               1 ----> print only errors
#               2 ---> print errors and warnings
#               3 ----> print errors, warnings and info 
VERBOSE = 1

# Seed for the random number generator
SEED = 994189

#****************************************************************
#******************** COSMOLOGICAL PARAMETERS *******************
#****************************************************************
#
# If left blank, default parameter values will be used.

HUBBLE_0 = 

OMEGA_MATTER =

OMEGA_LAMBDA =

#****************************************************************
# ******************* TEMPLATES  *****************************
#****************************************************************

#TEMPLATES = $BEAGLE_TEMPLATES/bc03/bc03_miles_chab_spectra
TEMPLATES NEBULAR = $BEAGLE_TEMPLATES/ineb_Jan16_C100/cb2013_n2_mup100_N015_O01_deplO70_C100_Jan16
EMISSION LINES CONFIGURATION = $BEAGLE_TEMPLATES/ineb_Jan16_C100/cb2013_n2_mup100_N015_O01_deplO70_C100_Jan16_line_wavelengths_PHOTOMETRY.dat

SHRINK TEMPLATES WL RANGE = 900 60000
REBIN TEMPLATES = 10

#SPECTRAL INDICES CONFIGURATION =

#SPECTRAL INDICES CATALOGUE = 

#****************************************************************
# ******************* PHOTOMETRY *****************************
#****************************************************************

FILTERS FILE = $BEAGLE_FILTERS/test/filters_RB16.dat

PHOTOMETRIC CATALOGUE = $BEAGLE_DATA/test/RB16_phot.fits
PRIORS CATALOGUE = $BEAGLE_DATA/test/RB16_phot.fits

FIT PHOTOMETRY = T
FIT SPECTRUM = F

#****************************************************************
#******************** DUST ATTENUATION AND IGM ABSORPTION *******
#****************************************************************
#
IGM ABSORPTION = Inoue

# File containing set of radiativa transfer (RT) calculations of dust attenuation of starlight
#RT CALCULATIONS = Tuffs_bulge_NEW-28-11.dat Tuffs_thick_NEW-28-11.dat Tuffs_thin_NEW-28-11.dat
#RT COMPONENTS NAMES = bulge thick_disc thin_disc

# **************************************************
# ************** SF BIN #1 **************************
# **************************************************
SF_PARAMETER  = name:sfh_type                 type:fixed  char_value:delayed
#options for analytic SFHs are 'ssp' (for a burst), 'constant', 'exponential', 'delayed', 'rising'

# In log(yr)
SF_PARAMETER  = name:tau                      type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[7.,10.5]

# in log(Z/Z_sun)
SF_PARAMETER  = name:metallicity              type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[-2.2,0.25]

# In log(M/M_sun)
SF_PARAMETER  = name:mass                     type:fitted  order_priority:0  prior:distribution:uniform  prior:range:[5.,12.] 

# **************************************************
# **************  OTHER SF PARAMETERS **************************
# **************************************************

# In log(yr^-1)
SF_PARAMETER  = name:specific_sfr                type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[-14.,7.]

# In log(yr)
SF_PARAMETER  = name:current_sfr_timescale        type:fixed  value:7.

#****************************************************************
# ******************* PRINTED OUTPUT  *****************************
#****************************************************************

RESULTS DIRECTORY = $BEAGLE_RESULTS/RB16/

#MOCK CATALOGUE NAME = 

PRINT PHOTOMETRY = T
PRINT SPECTRUM = F
PRINT SPECTRAL INDICES = F
PRINT SF AND ChE HISTORIES = F

#****************************************************************
# ******************* PARAMETERS HANDLING  *****************************
#****************************************************************

PDF SAMPLER FILE = $BEAGLE_PARAM_DIR/MCMC_example.param

PARAMETER  = name:redshift     type:fitted  order_priority:0    prior:distribution:dirac  prior:colName:spec_z

PARAMETER  = name:nebular_logU type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[-4.,-1.]

PARAMETER  = name:nebular_xi   type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[0.1,0.5]

PARAMETER  = name:nebular_Z    type:dependent 

PARAMETER  = name:attenuation_type  type:fixed  char_value:CF00   
# values can be: CF00, Calzetti, CCWW13_universal, CCWW13_full

PARAMETER  = name:tauV_eff     type:fitted  order_priority:0      prior:distribution:uniform   prior:range:[0.001,5.]

PARAMETER  = name:mu           type:fixed   value:0.4

The error message is removed when I comment

SF_PARAMETER  = name:specific_sfr                type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[-14.,7.]

in OTHER SF PARAMETERS. I am wondering if there is any problem on varying sSFR when fitting photometry, or this parameter should be set in another way?

Thanks!

jacopo-chevallard commented 8 years ago

Hi Mengtao, the prior range in this line

SF_PARAMETER  = name:specific_sfr                type:fitted  order_priority:1  prior:distribution:uniform  prior:range:[-14.,7.]

is incorrect, there is a - sign missing in front of the 7, this is causing the error

mengtaotang commented 8 years ago

It's my fault. Problem fixed. Thank you!