Commit c3886afb authored by Matthieu Tristram's avatar Matthieu Tristram
Browse files

Merge branch 'master' of https://gitlab.in2p3.fr/cosmotools/CAMEL

parents 0e9600ab 4e957c83
......@@ -2,9 +2,13 @@
#cmt stuff
if [ -z "$CMTCLASS" ] ; then
echo "CMTCLASS is undefined"
exit 1
return
else
if [ -z "$CMTPATH" ] ; then
export CMTPATH=${CMTCLASS}
else
export CMTPATH=${CMTPATH}:${CMTCLASS}
fi
fi
if [ ! -f setup.sh ] ; then
......@@ -16,18 +20,18 @@ fi
source ./setup.sh
if [ -z "$CAMELROOT" ] ; then
echo "CAMELROOT undefined ...something went wrong. do you have a requirements file?"
exit 1
return
fi
#creating link
if [ -z "${CAMEL_DATA}" ] ; then
echo "CAMEL_DATA undefined: review your installation (see http://camel.in2p3.fr/wiki/pmwiki.php?n=Main.Install)"
exit 1
return
fi
if [ ! -d "${CAMEL_DATA}" ] ; then
echo "empty CAMEL_DATA directory : please fix (see http://camel.in2p3.fr/wiki/pmwiki.php?n=Main.Install)"
exit 1
return
fi
echo CAMEL_DATA="${CAMEL_DATA}"
......@@ -79,3 +83,4 @@ echo "your CAMELROOT is $CAMELROOT"
# put 1 at the end of next line if you want a closer look at compilaton
export VERBOSE=
echo "if you want more verbose compilation define VERBOSE environement variable to 1: export VERBOSE=1"
......@@ -3,40 +3,42 @@ package CAMEL
use class HEAD
#compiler options
#macro cpp "icpc"
#macro cppflags " -O2 -ip -ansi_alias -align -Wbrief "
#default is gcc here are the C++ compiler options
macro cppflags " -O2 -pipe -ansi -Woverloaded-virtual -Wpedantic -Wunused -Wmaybe-uninitialized -Wno-deprecated -Wno-div-by-zero -Wno-variadic-macros"
macro cflags " -O2 -fopenmp "
macro cppflags " -O2 -pipe -ansi -Woverloaded-virtual -Wpedantic -Wunused -Wmaybe-uninitialized -Wno-deprecated -Wno-div-by-zero "
# although it may be strange we do not compile CAMEL with OMP because CLASS is not thread safe
# no worries: CLASS is compiled with OMP
#macro_append cppflags "-fopenmp "
macro_append cpplinkflags " -fopenmp "
#CAMEL includes
include_dirs " ../src"
include_dirs "../src/camel"
include_dirs "../src/Minuit2-5.28.00/src"
include_dirs "../src/Minuit2-5.28.00/inc"
include_dirs "../src/cxxsupport"
include_dirs "../src/AbsRand"
include_dirs "../src/camel/JLA"
include_dirs "../src/camel/JLA/jla_likelihood_v3/src"
include_dirs " $(CAMELROOT)/src"
include_dirs " $(CAMELROOT)/src/camel"
include_dirs " $(CAMELROOT)/src/Minuit2-5.28.00/src"
include_dirs " $(CAMELROOT)/src/Minuit2-5.28.00/inc"
include_dirs "$(CAMELROOT)/src/cxxsupport"
include_dirs "$(CAMELROOT)/src/AbsRand"
include_dirs "$(CAMELROOT)/src/camel/JLA"
include_dirs "$(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src"
#cfitsio
include_dirs "$(CLIKDIR)/include"
macro_append CAMEL_linkopts " -L$(CLIKDIR) -lcfitsio"
#include_dirs "$(CLIKDIR)/include"
#macro_append CAMEL_linkopts " -L$(CLIKDIR) -lcfitsio"
macro_append CAMEL_linkopts " -lcfitsio"
#JLA :requires cblas/lapack
macro_append cppflags ' -DJLA '
include_dirs "/usr/include/atlas"
macro_append CAMEL_linkopts " -L/usr/lib64/atlas -lcblas -llapack -ljla "
application test_jla -group=test -s=../src/camel test/test_jla.cc
#macro_append cppflags ' -DJLA '
#include_dirs "/usr/include/atlas"
#macro_append CAMEL_linkopts " -L/usr/lib/atlas-base -lcblas -llapack_atlas -ljla "
#application test_jla -group=test -s=$(CAMELROOT)/src/camel test/test_jla.cc
#PLANCK
macro_append cppflags " -DCLIK $(CLIKCFLAGS)"
macro_append cflags " -DCLIK $(CLIKCFLAGS)"
macro_append CAMEL_linkopts " $(CLIKLIBS) "
#macro_append cppflags " -DCLIK $(CLIKCFLAGS)"
#macro_append cflags " -DCLIK $(CLIKCFLAGS)"
#macro_append CAMEL_linkopts " $(CLIKLIBS) "
#include_dirs "$(CLIKDIR)/include"
#include_dirs "$(CLIKDIR)/src"
......@@ -44,55 +46,59 @@ macro_append CAMEL_linkopts " $(CLIKLIBS) "
#macro_append cflags " -DCLIK "
#macro_append CAMEL_linkopts "-L$(CLIKDIR)/lib -lclik "
#path_append LD_LIBRARY_PATH "$(CLIKDIR)/lib"
#application dump_clik -group=test -s=$(CAMELROOT)/src/camel test/test_clik.cc
#application dump_lensing -group=test -s=$(CAMELROOT)/src/camel test/test_lensing.cc
# PICO
macro_append cppflags " -DPICO $(PICOINC) "
macro_append CAMEL_linkopts " -L$(PICO_CODE) -lpico -lpython2.7 "
#macro_append cppflags " -DPICO $(PICOINC) "
#macro_append CAMEL_linkopts " -L$(PICO_CODE) -lpico -lpython2.7 "
# the previous line should be sufficient otherwise try the PICOLIBS
# (set in camel_setup.sh)
#macro_append CAMEL_linkopts " $(PICOLIBS)"
macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
application testPico -group=test -s=../src/camel/pico/exec testPico.cc
#macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
#application testPico -group=test -s=$(CAMELROOT)/src/camel/pico/exec testPico.cc
#CLASS optional FastPk access
macro_append cppflags " -DFASTPK "
###FROM THERE YOU DONT NEED TO TOUCH
###########################################################################################
#CAMEL LIBRARIES
library Minuit -no_share ../src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc ../src/cxxsupport/*.cc
library AbsRand -no_share ../src/AbsRand/*.cc
library CLHEP -no_share ../src/CLHEP/src/*.cc
library jla -no_share ../src/camel/JLA/jla_likelihood_v3/src/ini.c ../src/camel/JLA/jla_likelihood_v3/src/jla.cc
library Minuit -no_share $(CAMELROOT)/src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc $(CAMELROOT)/src/cxxsupport/*.cc
library AbsRand -no_share $(CAMELROOT)/src/AbsRand/*.cc
library CLHEP -no_share $(CAMELROOT)/src/CLHEP/src/*.cc
library jla -no_share $(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src/ini.c $(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src/jla.cc
macro camelsrc "*.cc CMB/*.cc BAO/*.cc Lensing/*.cc pico/*.cc JLA/*.cc Class/*.cc Constraints/*.cc"
library MinuitFit -no_share -s=../src/camel $(camelsrc)
library MCMC -no_share -s=../src/camel/MCMC *.cc
library MinuitFit -no_share -s=$(CAMELROOT)/src/camel $(camelsrc)
library MCMC -no_share -s=$(CAMELROOT)/src/camel/MCMC *.cc
macro CAMEL_linkopts "-L$(CAMEL_root)/${CMTCONFIG} -lMinuitFit -lMinuit -lMCMC -lCLHEP -lAbsRand -lUtil "
macro CAMEL_linkopts "-L$(CAMELROOT)/${CMTCONFIG} -lMinuitFit -lMinuit -lMCMC -lCLHEP -lAbsRand -lUtil "
macro_append cppflags ' -DRELPATH=\"$(CAMELROOT)/lik\" '
#CAMEL applications
# pour relinker si changement: toutes les application du package
macro CAMEL_stamps " $(PACKAGE_ROOT)/$(CMTCONFIG)/MinuitFit.stamp $(PACKAGE_ROOT)/$(CMTCONFIG)/MCMC.stamp "
macro CAMEL_stamps " $(CAMELROOT)/$(CMTCONFIG)/MinuitFit.stamp $(CAMELROOT)/$(CMTCONFIG)/MCMC.stamp "
macro application_suffix ""
#groupe exec
application writeChi2 -group=exec -s=../src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=../src/camel exec/writeSpectra.cc
application writeSpectraPk -group=exec -s=../src/camel exec/writeSpectraPk.cc
application Minimize -group=exec -s=../src/camel exec/Minimize.cc
application Profile -group=exec -s=../src/camel exec/Profile.cc
application ScanParam -group=exec -s=../src/camel exec/ScanParam.cc
application mcmc -group=exec -s=../src/camel/MCMC exec/mainMCMC.cc
application writeChi2 -group=exec -s=$(CAMELROOT)/src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=$(CAMELROOT)/src/camel exec/writeSpectra.cc
application writeSpectraPk -group=exec -s=$(CAMELROOT)/src/camel exec/writeSpectraPk.cc
application Minimize -group=exec -s=$(CAMELROOT)/src/camel exec/Minimize.cc
application Profile -group=exec -s=$(CAMELROOT)/src/camel exec/Profile.cc
application ScanParam -group=exec -s=$(CAMELROOT)/src/camel exec/ScanParam.cc
application mcmc -group=exec -s=$(CAMELROOT)/src/camel/MCMC exec/mainMCMC.cc
#tests
application testKlass -group=test -s=../src/camel test/testKlass.cc
application testCLHEP -group=test -s=../src/camel/test testCLHEP.cc
application testBAO -group=test -s=../src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=../src/camel/test testHiLLiPOP.cc
application dump_clik -group=test -s=../src/camel test/test_clik.cc
application dump_lensing -group=test -s=../src/camel test/test_lensing.cc
application testKlass -group=test -s=$(CAMELROOT)/src/camel test/testKlass.cc
application testCLHEP -group=test -s=$(CAMELROOT)/src/camel/test testCLHEP.cc
application testBAO -group=test -s=$(CAMELROOT)/src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=$(CAMELROOT)/src/camel/test testHiLLiPOP.cc
#lIST OF ALL DEPENDENCIES
macro_append Minimize_dependencies " MinuitFit "
......@@ -111,5 +117,4 @@ macro_append testCLHEP_dependencies " CLHEP "
macro_append testBAO_dependencies " MinuitFit "
macro_append testHiLLiPOP_dependencies " MinuitFit "
macro_append test_jla_dependencies " MinuitFit "
macro_append testPico_dependencies " MinuitFit "
......@@ -7,20 +7,20 @@ macro cpp "icpc"
macro cppflags " -O2 -ip -ansi_alias -align -Wbrief -Wdeprecated -Wuninitialized -align -Wbrief -Wunused-function -Wpointer-arith -Wreturn-type"
#CAMEL includes
include_dirs " ../src"
include_dirs "../src/camel"
include_dirs "../src/Minuit2-5.28.00/src"
include_dirs "../src/Minuit2-5.28.00/inc"
include_dirs "../src/cxxsupport"
include_dirs "../src/AbsRand"
include_dirs "../src/camel/JLA"
include_dirs "../src/camel/JLA/jla_likelihood_v3/src"
include_dirs " $(CAMELROOT)/src"
include_dirs "$(CAMELROOT)/src/camel"
include_dirs "$(CAMELROOT)/src/Minuit2-5.28.00/src"
include_dirs "$(CAMELROOT)/src/Minuit2-5.28.00/inc"
include_dirs "$(CAMELROOT)/src/cxxsupport"
include_dirs "$(CAMELROOT)/src/AbsRand"
include_dirs "$(CAMELROOT)/src/camel/JLA"
include_dirs "$(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src"
#JLA :requires cblas/lapack (use intel versions)
macro_append cppflags " -DJLA "
macro_append CAMEL_linkopts " -L$(MKLROOT)/lib/intel64 -lmkl_intel_lp64 -lmkl_core -lmkl_intel_thread -ljla "
application test_jla -group=test -s=../src/camel test/test_jla.cc
application test_jla -group=test -s=$(CAMELROOT)/src/camel test/test_jla.cc
#cfitsio
#cfitsio: here the CLIK version (below) will be used so no need
......@@ -38,20 +38,20 @@ macro_append CAMEL_linkopts " $(CLIKLIBS) "
macro_append cppflags " -DPICO $(PICOINC) "
macro_append CAMEL_linkopts " $(PICOLIBS)"
macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
application testPico -group=test -s=../src/camel/pico/exec testPico.cc
application FitClassFromPico -group=exec -s=../src/camel exec/FitClassFromPico.cc
application testPico -group=test -s=$(CAMELROOT)/src/camel/pico/exec testPico.cc
application FitClassFromPico -group=exec -s=$(CAMELROOT)/src/camel exec/FitClassFromPico.cc
#CAMEL LIBRARIES
library Minuit -no_share ../src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc ../src/cxxsupport/*.cc
library AbsRand -no_share ../src/AbsRand/*.cc
library CLHEP -no_share ../src/CLHEP/src/*.cc
library jla -no_share ../src/camel/JLA/jla_likelihood_v3/src/ini.c ../src/camel/JLA/jla_likelihood_v3/src/jla.cc
library Minuit -no_share $(CAMELROOT)/src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc $(CAMELROOT)/src/cxxsupport/*.cc
library AbsRand -no_share $(CAMELROOT)/src/AbsRand/*.cc
library CLHEP -no_share $(CAMELROOT)/src/CLHEP/src/*.cc
library jla -no_share $(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src/ini.c $(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src/jla.cc
macro camelsrc "*.cc CMB/*.cc BAO/*.cc Lensing/*.cc pico/*.cc JLA/*.cc Class/*.cc Constraints/*.cc"
library MinuitFit -no_share -s=../src/camel $(camelsrc)
library MCMC -no_share -s=../src/camel/MCMC *.cc
library MinuitFit -no_share -s=$(CAMELROOT)/src/camel $(camelsrc)
library MCMC -no_share -s=$(CAMELROOT)/src/camel/MCMC *.cc
macro CAMEL_linkopts "-L$(CAMEL_root)/${CMTCONFIG} -lMinuitFit -lMinuit -lMCMC -lCLHEP -lAbsRand -lUtil "
macro_append cppflags ' -DRELPATH=\"$(CAMELROOT)/lik\" '
......@@ -59,26 +59,26 @@ macro_append cppflags ' -DRELPATH=\"$(CAMELROOT)/lik\" '
#CAMEL applications
# pour relinker si changement: toutes les application du package
macro CAMEL_stamps " $(PACKAGE_ROOT)/$(CMTCONFIG)/MinuitFit.stamp $(PACKAGE_ROOT)/$(CMTCONFIG)/MCMC.stamp "
macro CAMEL_stamps " $(CAMELROOT)/$(CMTCONFIG)/MinuitFit.stamp $(CAMELROOT)/$(CMTCONFIG)/MCMC.stamp "
macro application_suffix ""
#groupe exec
application writeChi2 -group=exec -s=../src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=../src/camel exec/writeSpectra.cc
application writeSpectraPk -group=exec -s=../src/camel exec/writeSpectraPk.cc
application Minimize -group=exec -s=../src/camel exec/Minimize.cc
application Profile -group=exec -s=../src/camel exec/Profile.cc
application ScanParam -group=exec -s=../src/camel exec/ScanParam.cc
application mcmc -group=exec -s=../src/camel/MCMC exec/mainMCMC.cc
application writeChi2 -group=exec -s=$(CAMELROOT)/src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=$(CAMELROOT)/src/camel exec/writeSpectra.cc
application writeSpectraPk -group=exec -s=$(CAMELROOT)/src/camel exec/writeSpectraPk.cc
application Minimize -group=exec -s=$(CAMELROOT)/src/camel exec/Minimize.cc
application Profile -group=exec -s=$(CAMELROOT)/src/camel exec/Profile.cc
application ScanParam -group=exec -s=$(CAMELROOT)/src/camel exec/ScanParam.cc
application mcmc -group=exec -s=$(CAMELROOT)/src/camel/MCMC exec/mainMCMC.cc
#tests
application testKlass -group=test -s=../src/camel test/testKlass.cc
application testCLHEP -group=test -s=../src/camel/test testCLHEP.cc
application testBAO -group=test -s=../src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=../src/camel/test testHiLLiPOP.cc
application dump_clik -group=test -s=../src/camel test/test_clik.cc
application dump_lensing -group=test -s=../src/camel test/test_lensing.cc
application testKlass -group=test -s=$(CAMELROOT)/src/camel test/testKlass.cc
application testCLHEP -group=test -s=$(CAMELROOT)/src/camel/test testCLHEP.cc
application testBAO -group=test -s=$(CAMELROOT)/src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=$(CAMELROOT)/src/camel/test testHiLLiPOP.cc
application dump_clik -group=test -s=$(CAMELROOT)/src/camel test/test_clik.cc
application dump_lensing -group=test -s=$(CAMELROOT)/src/camel test/test_lensing.cc
#lIST OF ALL DEPENDENCIES
macro_append Minimize_dependencies " MinuitFit "
......
package CAMEL
#THE FOLLWING LINKS TO YOUR CLASS LIBRARY- YOU CAN TEST WHICH ONE IN YOUR
#SHELL WITH THE FOLLWING COMMAND : cmt show uses
# you may put an explicit version instead of * (as v2.4.4 or v2.*...)
use class *
#CLASS optional FastPk access
#macro_append cppflags " -DFASTPK "
#COMPILER - TO EASE PAIN USE THE SAME THAN FOR CLASS/CLIK COMPILATION
# DEFAULT IS gcc SO DO NOT UNCOMMENT IF YOUR ARE HAPPY WITH THIS (EXAMPLE FOR CHANGING TO ICPC)
#macro cpp "icpc"
#COMPILER FLAGS for default=gcc
#C++ flags
macro cppflags " -O2 -pipe -ansi -Woverloaded-virtual -Wpedantic -Wunused -Wmaybe-uninitialized -Wno-deprecated -Wno-div-by-zero -Wno-variadic-macros"
# C flags
macro cflags " -O2 -fopenmp "
#compiler options
#default is gcc here are the C++ compiler options
macro cppflags " -O3 -pipe -ansi -fPIC -Wall "
# or for icpc (if you changed previously the compiler otherwise don't touch)
#macro cppflags " -O2 -ip -ansi_alias -align -Wbrief "
#do we need optimzations here?
#macro_append cppflags "-ffast-math -m64 "
#
# CFITSIO IS REQUIRED.
# include_dirs indicates the path to fitsio.h/ and CAMEL_linkopts teh
# link to the propoer library. In the following we use the one that was
# compiled when building CLIK but it can be also found
# in your /usr area. If the library is shared you may need to update your
# LD_LIBRARY_PATH or uncomment the next line before sourcing camel_setup.sh
#path_append LD_LIBRARY_PATH "$(CLIKDIR)/lib"
# although it may be strange we do not compile CAMEL with OMP because CLASS is not thread safe
# no worries: CLASS is compiled with OMP
#macro_append cppflags "-fopenmp "
macro_append cpplinkflags " -fopenmp "
include_dirs "$(CLIKDIR)/include"
macro_append CAMEL_linkopts " -L$(CLIKDIR)/lib -lcfitsio"
#CAMEL includes
include_dirs " $(CAMELROOT)/src"
include_dirs " $(CAMELROOT)/src/camel"
include_dirs " $(CAMELROOT)/src/Minuit2-5.28.00/src"
include_dirs " $(CAMELROOT)/src/Minuit2-5.28.00/inc"
include_dirs "$(CAMELROOT)/src/cxxsupport"
include_dirs "$(CAMELROOT)/src/AbsRand"
include_dirs "$(CAMELROOT)/src/camel/JLA"
include_dirs "$(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src"
#cfitsio
include_dirs "/usr/include/cfitsio"
macro_append CAMEL_linkopts " -lcfitsio"
#JLA :requires cblas/lapack
#macro_append cppflags ' -DJLA '
#include_dirs "/usr/include/atlas"
#macro_append CAMEL_linkopts " -L/usr/lib64/atlas -ltatlas -llapack -ljla "
#application test_jla -group=test -s=$(CAMELROOT)/src/camel test/test_jla.cc
#library jla -no_share $(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src/ini.c $(CAMELROOT)/src/camel/JLA/jla_likelihood_v3/src/jla.cc
# PLANCK CLIK support [optional]
# NB: you always have access to PLanck/Hillipop (high-ell) likelihood since
# it is native in CAMEL.
# CLIKCFLAGS and CLIKLIBS were defined when you ran: camel_setup.sh
#PLANCK
#macro_append cppflags " -DCLIK $(CLIKCFLAGS)"
#macro_append cflags " -DCLIK $(CLIKCFLAGS)"
#macro_append CAMEL_linkopts " $(CLIKLIBS) "
#include_dirs "$(CLIKDIR)/include"
#include_dirs "$(CLIKDIR)/src"
#macro_append cppflags " -DCLIK "
#macro_append cflags " -DCLIK "
#macro_append CAMEL_linkopts "-L$(CLIKDIR)/lib -lclik "
#application dump_clik -group=test -s=../src/camel test/test_clik.cc
#application dump_lensing -group=test -s=../src/camel test/test_lensing.cc
#JLA [optional] :requires cblas/lapack
# in most linux distributions packaged with the atlas library.
# if you installed CLIK you may also look for them in teh MKLROOT you used.
# macro_append cppflags ' -DJLA '
#include_dirs "/usr/include/atlas"
#macro_append CAMEL_linkopts " -L/usr/lib64/atlas -lcblas -llapack -ljla "
#application test_jla -group=test -s=../src/camel test/test_jla.cc
#path_append LD_LIBRARY_PATH "$(CLIKDIR)/lib"
#application dump_clik -group=test -s=$(CAMELROOT)/src/camel test/test_clik.cc
#application dump_lensing -group=test -s=$(CAMELROOT)/src/camel test/test_lensing.cc
# PICO [optional]
# PICO
#macro_append cppflags " -DPICO $(PICOINC) "
#macro_append CAMEL_linkopts " -L$(PICO_CODE) -lpico -lpython2.7 "
# if the previous link fails try using the PICOLIBS defined in camel_setup.sh
# the previous line should be sufficient otherwise try the PICOLIBS
# (set in camel_setup.sh)
#macro_append CAMEL_linkopts " $(PICOLIBS)"
#macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
#application testPico -group=test -s=../src/camel/pico/exec testPico.cc
#application testPico -group=test -s=$(CAMELROOT)/src/camel/pico/exec testPico.cc
#macro_append cppflags " -DPICO "
#include_dirs "/usr/include/python2.7"
#include_dirs "/usr/lib64/python2.7/site-packages/numpy/core/include"
#include_dirs "$(PICO_CODE)/pypico"
#macro_append CAMEL_linkopts " -L$(PICO_CODE)/build/temp.linux-x86_64-2.7 -lpico -L/usr/lib64/python2.7/config -lpython2.7 "
#macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
#application testPico -group=test -s=../src/camel/pico/exec testPico.cc
#application FitClassFromPico -group=exec -s=../src/camel exec/FitClassFromPico.cc
###########################################################################################
###FROM THERE YOU SHOUL NOT NEED TO TOUCH ANYTHING
###########################################################################################
#CAMEL includes
include_dirs " ../src"
include_dirs "../src/camel"
include_dirs "../src/Minuit2-5.28.00/src"
include_dirs "../src/Minuit2-5.28.00/inc"
include_dirs "../src/cxxsupport"
include_dirs "../src/AbsRand"
include_dirs "../src/camel/JLA"
include_dirs "../src/camel/JLA/jla_likelihood_v3/src"
###FROM THERE YOU DONT NEED TO TOUCH
###########################################################################################
#CAMEL LIBRARIES
library Minuit -no_share ../src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc ../src/cxxsupport/*.cc
library AbsRand -no_share ../src/AbsRand/*.cc
library CLHEP -no_share ../src/CLHEP/src/*.cc
library jla -no_share ../src/camel/JLA/jla_likelihood_v3/src/ini.c ../src/camel/JLA/jla_likelihood_v3/src/jla.cc
library Minuit -no_share $(CAMELROOT)/src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc $(CAMELROOT)/src/cxxsupport/*.cc
library AbsRand -no_share $(CAMELROOT)/src/AbsRand/*.cc
library CLHEP -no_share $(CAMELROOT)/src/CLHEP/src/*.cc
macro camelsrc "*.cc CMB/*.cc BAO/*.cc Lensing/*.cc pico/*.cc JLA/*.cc Class/*.cc Constraints/*.cc"
library MinuitFit -no_share -s=../src/camel $(camelsrc)
library MCMC -no_share -s=../src/camel/MCMC *.cc
macro camelsrc "*.cc CMB/*.cc BAO/*.cc Lensing/*.cc pico/*.cc JLA/*.cc Class/*.cc Constraints/*.cc Pk/*.cc"
library MinuitFit -no_share -s=$(CAMELROOT)/src/camel $(camelsrc)
library MCMC -no_share -s=$(CAMELROOT)/src/camel/MCMC *.cc
macro CAMEL_linkopts "-L$(CAMEL_root)/${CMTCONFIG} -lMinuitFit -lMinuit -lMCMC -lCLHEP -lAbsRand -lUtil "
macro CAMEL_linkopts "-L$(CAMELROOT)/${CMTCONFIG} -lMinuitFit -lMinuit -lMCMC -lCLHEP -lAbsRand -lUtil "
macro_append cppflags ' -DRELPATH=\"$(CAMELROOT)/lik\" '
#CAMEL applications
# pour relinker si changement: toutes les application du package
macro CAMEL_stamps $(PACKAGE_ROOT)/$(CMTCONFIG)/MinuitFit.stamp
macro CAMEL_stamps " $(CAMELROOT)/$(CMTCONFIG)/MinuitFit.stamp $(CAMELROOT)/$(CMTCONFIG)/MCMC.stamp "
macro application_suffix ""
#groupe exec: to build run: make exec
application writeChi2 -group=exec -s=../src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=../src/camel exec/writeSpectra.cc
application Minimize -group=exec -s=../src/camel exec/Minimize.cc
application ScanParam -group=exec -s=../src/camel exec/ScanParam.cc
application mcmc -group=exec -s=../src/camel/MCMC exec/mainMCMC.cc
#groupe exec
application writeChi2 -group=exec -s=$(CAMELROOT)/src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=$(CAMELROOT)/src/camel exec/writeSpectra.cc
application writeSpectraPk -group=exec -s=$(CAMELROOT)/src/camel exec/writeSpectraPk.cc
application Minimize -group=exec -s=$(CAMELROOT)/src/camel exec/Minimize.cc
application Profile -group=exec -s=$(CAMELROOT)/src/camel exec/Profile.cc
application ScanParam -group=exec -s=$(CAMELROOT)/src/camel exec/ScanParam.cc
application mcmc -group=exec -s=$(CAMELROOT)/src/camel/MCMC exec/mainMCMC.cc
#tests
application testKlass -group=test -s=../src/camel test/testKlass.cc
application testCLHEP -group=test -s=../src/camel/test testCLHEP.cc
application testBAO -group=test -s=../src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=../src/camel/test testHiLLiPOP.cc
application testKlass -group=test -s=$(CAMELROOT)/src/camel test/testKlass.cc
application testCLHEP -group=test -s=$(CAMELROOT)/src/camel/test testCLHEP.cc
application testBAO -group=test -s=$(CAMELROOT)/src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=$(CAMELROOT)/src/camel/test testHiLLiPOP.cc
#lIST OF ALL DEPENDENCIES
macro_append Minimize_dependencies " MinuitFit "
macro_append Profile_dependencies " MinuitFit "
macro_append ScanParam_dependencies " MinuitFit "
macro_append writeChi2_dependencies " MinuitFit "
macro_append writeSpectra_dependencies " MinuitFit "
macro_append mcmc_dependencies " MinuitFit MCMC"
macro_append writeSpectraPkependencies " MinuitFit "
macro_append mcmc_dependencies " MinuitFit "
macro_append mcmc_dependencies " MCMC "
macro_append testKlass_dependencies " MinuitFit"
macro_append clik_example_CC_dependencies " MinuitFit "
macro_append test_clik_dependencies " MinuitFit "
......@@ -128,5 +119,4 @@ macro_append testCLHEP_dependencies " CLHEP "
macro_append testBAO_dependencies " MinuitFit "
macro_append testHiLLiPOP_dependencies " MinuitFit "
macro_append test_jla_dependencies " MinuitFit "
macro_append testPico_dependencies " MinuitFit "
# for adding comment # followed by a space (only on a new line)
# input data for BAO
# in/fix | name | num of data | z | value | error | out of diag| elements (eventually)
in 6dF 1 0.106 457 27
fix SDSS(R) 1 0.35 8.88 0.17
fix BOSS(DR9) 1 0.57 13.67 0.22
fix BOSS-CMASS(DR11) 1 0.57 2056 20
fix BOSS-LOWZ(DR11) 1 0.32 1264 25
fix WiggleZ 3 0.44 0.0916 0.0071 0.60 0.0726 0.0034 0.73 0.0592 0.0032 0.003068 0.0 0.00222005
fix SDSS 2 0.20 0.1905 0.0061 0.35 0.1097 0.0036 0.002723
in SDSS-MGS 1 0.15 664 25
# for adding comment # followed by a space (only on a new line)
# input data for BAO
# in/fix | name | num of data | z | value | error | out of diag| elements (eventually)
in 6dF 1 0.106 457 27
fix SDSS(R) 1 0.35 8.88 0.17
fix BOSS(DR9) 1 0.57 13.67 0.22
fix BOSS-CMASS(DR11) 1 0.57 2056 20
in BOSS-LOWZ(DR11) 1 0.32 1264 25
fix WiggleZ 3 0.44 0.0916 0.0071 0.60 0.0726 0.0034 0.73 0.0592 0.0032 0.003068 0.0 0.00222005
fix SDSS 2 0.20 0.1905 0.0061 0.35 0.1097 0.0036 0.002723
in SDSS-MGS 1 0.15 664 25
MultipolesRange = camel_data/Hillipop/Binning/binning.fits
Beams = camel_data/Hillipop/Data/DX11d_r3_HM/LALmaskSuperExt-ConservativeCO/bell/beam
XSpectra = camel_data/Hillipop/Data/DX11d_r3_HM/LALmaskSuperExt-ConservativeCO/spectra/cross_DX11d_HM_SuperExtCO
XSpectraErrors = camel_data/Hillipop/Data/DX11d_r3_HM/LALmaskSuperExt-ConservativeCO/spectra/cross_DX11d_HM_SuperExtCO
CovMatrix = camel_data/Hillipop/Data/DX11d_r3_HM/LALmaskSuperExt-ConservativeCO/pclcvm/invfll_DX11dr3HM_SG_pack
SZ = camel_data/Hillipop/Foregrounds/ClSZ_poiss_corr_MD2_cppp_bestCl_NILC_extra12_cibps_lmax10000.fits
kSZ = camel_data/Hillipop/Foregrounds/ksz_shaw_bat_PWAS_MD_tau062.fits
CIB = camel_data/Hillipop/Foregrounds/CIB_v3
SZxCIB = camel_data/Hillipop/Foregrounds/SZxCIB
Dust = camel_data/Hillipop/Foregrounds/Dust_LALmaskSuperExt-ConservativeCO_DX11d
TT = 0
EE = 0
BB = 0
TE = 1
ET = 1
map = 6
freq0 = 100
freq1 = 100
freq2 = 143
freq3 = 143
freq4 = 217
freq5 = 217
FileOut =
......@@ -64,6 +64,8 @@ double BAO_chi2::chi2_eff(const std::vector<double>& par) const
if((_data_name[i]=="BOSS-CMASS(DR11)")&&(_data[i]==1421)) cosmo[i]=(engine->get_Da(_z[i]))*149.28/rs_drag;
// if((_data_name[i]=="BOSS-CMASS(DR11)")&&(_data[i]==1421)) cout <<"Da(z=0.57) ="<< engine->get_Da(_z[i]) <<endl;
if((_data_name[i]=="BOSS-CMASS(DR11)")&&(_data[i]==96.8)) cosmo[i]=(engine->get_H(_z[i]))*rs_drag/149.28;
if((_data_name[i]=="SDSS-MGS")&&(_data[i]==664.)) cosmo[i]=engine->get_Dv(_z[i])*rs_drag/149.69;
//cout << " _data_name[i] "<< cosmo[i]<<" "<< _data[i] << endl;
// if((_data_name[i]=="BOSS-CMASS(DR11)")&&(_data[i]==96.8)) cout <<"H(z=0.57) ="<< engine->get_H(_z[i]) <<endl;
}
......@@ -75,7 +77,7 @@ double BAO_chi2::chi2_eff(const std::vector<double>& par) const
//chi2 actual calculation
HepVector diff;
diff=cosmo-_data;
//this computes xT*_inv_cov*x
chi2=_inv_cov.similarity(diff);
//cout<< "chi2 bao="<< chi2 <<endl;
......
......@@ -86,15 +86,10 @@ Chi2Combiner::chi2_eff(const std::vector<double>& par) const {
copy(par.begin(),par.end(),ostream_iterator<double>(os,"\t"));
}
//update Engine
//1 seul thread
#pragma omp critical
#pragma omp critical
{
self->OK=engine->updateParValues(par);
}
if (!OK) {
//A TUNER!!!!!!!!!!!!!1
chi2=chi2_prev*10.;
......
......@@ -159,9 +159,10 @@ Chi2Factory::gimeChi2(Parser& parser){
allCl->add(acte);