I should note that I have successfully compiled CosmoMC before (and symbolically linking to Planck likelihoods), and that is all fine. I did "mpirun -np 1 ./cosmomc test.ini" and also with "test_planck.ini" to make sure.
These are the modules I used that was fine for CosmoMC:
Code: Select all
1) OpenBLAS/0.2.13-GCC-4.9.2-LAPACK-3.5.0 11) libpng/1.6.28-gimkl-2017a 21) libxml2/2.9.4-gimkl-2017a 31) icc/2017.1.132-GCC-5.4.0
2) GCCcore/5.4.0 12) freetype/2.7.1-gimkl-2017a 22) libxslt/1.1.29-gimkl-2017a 32) ifort/2017.1.132-GCC-5.4.0
3) binutils/2.26-GCCcore-5.4.0 13) GEOS/3.6.1-gimkl-2017a 23) LLVM/3.8.1-gimkl-2017a 33) iccifort/2017.1.132-GCC-5.4.0
4) GCC/5.4.0-2.26 14) Szip/2.1-gimkl-2017a 24) cURL/7.52.1-gimkl-2017a 34) impi/2017.1.132-iccifort-2017.1.132-GCC-5.4.0
5) gimpi/2017a 15) HDF5/1.8.18-gimkl-2017a 25) netCDF/4.4.1-gimkl-2017a 35) iimpi/2017a
6) gimkl/2017a 16) libgpuarray/0.6.2-gimkl-2017a-CUDA-8.0.61 26) Tcl/8.6.6-gimkl-2017a 36) imkl/2017.1.132-iimpi-2017a
7) bzip2/1.0.6-gimkl-2017a 17) libjpeg-turbo/1.5.1-gimkl-2017a 27) SQLite/3.16.2-gimkl-2017a 37) intel/2017a
8) CUDA/8.0.61 18) ncurses/6.0-gimkl-2017a 28) METIS/5.1.0-gimkl-2017a
9) FFTW/3.3.5-gimkl-2017a 19) libreadline/6.3-gimkl-2017a 29) SuiteSparse/4.5.4-gimkl-2017a
10) zlib/1.2.11-gimkl-2017a 20) XZ/5.2.3-gimkl-2017a 30) Python/2.7.13-gimkl-2017a
Now for trying to integrate CosmoChord:
After unpacking a fresh CosmoMC (Nov 2016), I simply unzipped the CosmoChord files in the CosmoMC folder.
If I try to make CosmoMC (with CosmoChord files in) with the above modules, I get
Code: Select all
(using make clean)
cd ./source && make clean
make[1]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/source'
rm -f ReleaseMPI/*.o ReleaseMPI/*.mod ../core
rm -rf Release*
rm -rf Debug*
cd ../polychord; make clean
make[2]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/polychord'
rm -f *.o *.mod *.MOD
make[2]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/polychord'
cd ../camb; make clean
make[2]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/camb'
rm -f *.o *.a *.d core *.mod Releaselib/*.o Releaselib/*.mod
rm -f *.o *.a *.d core *.mod ReleaseMPI/*.o ReleaseMPI/*.mod pycamb/camb/*.so
rm -rf Release*
rm -rf Debug*
make[2]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/camb'
make[1]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/source'
(using make)
cd ./source && make cosmomc BUILD=MPI
make[1]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/source'
mkdir -p ReleaseMPI
cd ../polychord; make all BUILD=MPI
make[2]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/polychord'
mpif90 -mkl -openmp -O3 -no-prec-div -fpp -xHost -DMPI -DCLIK -assume noold_maxminloc -c utils.f90
ifort: command line remark #10411: option '-openmp' is deprecated and will be removed in a future release. Please use the replacement option '-qopenmp'
utils.f90(1025): error #7013: This module file was not generated by any release of this compiler. [MPI]
use mpi,only: MPI_Wtime
------------^
utils.f90(1031): error #6406: Conflicting attributes or multiple declaration of name. [MPI_WTIME]
time = MPI_Wtime()
---------------^
utils.f90(1025): error #6580: Name in only-list does not exist. [MPI_WTIME]
use mpi,only: MPI_Wtime
----------------------^
compilation aborted for utils.f90 (code 1)
make[2]: *** [utils.o] Error 1
make[2]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/polychord'
make[1]: *** [polychord] Error 2
make[1]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/source'
make: *** [cosmomc] Error 2
foss: GCC, OpenMPI, OpenBLAS/LAPACK, ScaLAPACK(/BLACS), FFTW
intel: icc, ifort, impi, imkl
gimkl: GCC, impi, imkl""
Anyways I tried to follow the instructions, so I now have this for the modules list:
Code: Select all
1) OpenBLAS/0.2.13-GCC-4.9.2-LAPACK-3.5.0 9) libreadline/6.3-foss-2015a 17) CUDA/7.5.18 25) Python/2.7.11-foss-2015a
2) numactl/2.0.10-GCC-4.9.2 10) ncurses/5.9-foss-2015a 18) Szip/2.1-foss-2015a 26) GCCcore/6.3.0
3) hwloc/1.10.0-GCC-4.9.2 11) LLVM/3.7.1-foss-2015a 19) HDF5/1.8.16-foss-2015a 27) binutils/2.27-GCCcore-6.3.0
4) gompi/2015a 12) zlib/1.2.8-foss-2015a 20) GEOS/3.5.0-foss-2015a 28) GCC/6.3.0
5) FFTW/3.3.4-gompi-2015a 13) Tcl/8.6.4-foss-2015a 21) NASM/2.11.08-foss-2015a 29) OpenMPI/2.0.2-GCC-6.3.0
6) ScaLAPACK/2.0.2-gompi-2015a-OpenBLAS-0.2.13-LAPACK-3.5.0 14) SQLite/3.10.0-foss-2015a 22) libjpeg-turbo/1.4.0-foss-2015a
7) foss/2015a 15) libxml2/2.9.3-foss-2015a 23) libpng/1.6.20-foss-2015a
8) bzip2/1.0.6-foss-2015a 16) libxslt/1.1.28-foss-2015a 24) freetype/2.6.2-foss-2015a
Code: Select all
make[2]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/polychord'
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c utils.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c abort.F90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c array_utils.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c settings.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c calculate.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c mpi_utils.F90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c random_utils.F90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c chordal_sampling.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c run_time_info.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c clustering.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c params.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c priors.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c read_write.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c feedback.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c generate.F90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c ini.f90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c nested_sampling.F90
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -c interfaces.F90
ar r libchord.a abort.o array_utils.o calculate.o chordal_sampling.o clustering.o feedback.o generate.o ini.o interfaces.o mpi_utils.o nested_sampling.o params.o priors.o random_utils.o read_write.o run_time_info.o settings.o utils.o
ar: creating libchord.a
make[2]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/polychord'
cd ../camb && \
make --file=Makefile_main libcamb OUTPUT_DIR=ReleaseMPI \
RECOMBINATION=recfast EQUATIONS=equations_ppf NONLINEAR=halofit_ppf
make[2]: Entering directory `/gpfs1m/projects/uoa00518/Work/cosmomc/camb'
mkdir -p ReleaseMPI
mpif90 -cpp -O3 -ffast-math -ffree-line-length-none -fopenmp -fmax-errors=4 -march=native -DMPI -DCLIK -JReleaseMPI -IReleaseMPI/ -c constants.f90 -o ReleaseMPI/constants.o
constants.f90:90:29:
if (id==0) error stop('Error id must be non-zero')
1
Error: Blank required in ERROR STOP statement near (1)
make[2]: *** [ReleaseMPI/constants.o] Error 1
make[2]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/camb'
make[1]: *** [camb] Error 2
make[1]: Leaving directory `/gpfs1m/projects/uoa00518/Work/cosmomc/source'
make: *** [cosmomc] Error 2
Could someone please advise?