CosmoCoffee Forum Index CosmoCoffee

 
 FAQFAQ   SearchSearch  MemberlistSmartFeed   MemberlistMemberlist    RegisterRegister 
   ProfileProfile   Log inLog in 
Arxiv New Filter | Bookmarks & clubs | Arxiv ref/author:

[CosmoMC] Make shows gfortran errors
 
Post new topic   Reply to topic    CosmoCoffee Forum Index -> Computers and software
View previous topic :: View next topic  
Author Message
Mason Ng



Joined: 17 May 2017
Posts: 10
Affiliation: The University of Auckland

PostPosted: June 12 2017  Reply with quote

I have successfully make'd CosmoMC on my desktop (Ubuntu). It was symbolically linked to the Planck likelihood as well. Previously, I got memory errors which prevented me from successfully running CosmoMC. I am now trying to get it working on a supercomputing cluster.

I am first trying to 'make' CosmoMC on the cluster build node -> I just 'scp'-ed cosmomc onto the cluster build node.

I have these modules loaded on the cluster environment:

Code:
  1) ifort/2017.1.132-GCC-5.4.0                 14) ncurses/6.0-gimkl-2017a        27) Python/2.7.13-gimkl-2017a
  2) impi/2017.1.132-GCC-5.4.0-2.26             15) libreadline/6.3-gimkl-2017a    28) GCCcore/6.3.0
  3) gimpi/2017a                                16) XZ/5.2.3-gimkl-2017a           29) binutils/2.27-GCCcore-6.3.0
  4) imkl/2017.1.132-gimpi-2017a                17) libxml2/2.9.4-gimkl-2017a      30) numactl/2.0.10-GCC-4.9.2
  5) gimkl/2017a                                18) libxslt/1.1.29-gimkl-2017a     31) hwloc/1.10.0-GCC-4.9.2
  6) bzip2/1.0.6-gimkl-2017a                    19) LLVM/3.8.1-gimkl-2017a         32) OpenBLAS/0.2.13-GCC-4.9.2-LAPACK-3.5.0
  7) CUDA/8.0.61                                20) Szip/2.1-gimkl-2017a           33) gompi/2015a
  8) zlib/1.2.11-gimkl-2017a                    21) HDF5/1.8.18-gimkl-2017a        34) FFTW/3.3.4-gompi-2015a
  9) libpng/1.6.28-gimkl-2017a                  22) cURL/7.52.1-gimkl-2017a        35) ScaLAPACK/2.0.2-gompi-2015a-OpenBLAS-0.2.13-LAPACK-3.5.0
 10) freetype/2.7.1-gimkl-2017a                 23) netCDF/4.4.1-gimkl-2017a       36) foss/2015a
 11) GEOS/3.6.1-gimkl-2017a                     24) SQLite/3.16.2-gimkl-2017a      37) CFITSIO/3.39-foss-2015a
 12) libgpuarray/0.6.2-gimkl-2017a-CUDA-8.0.61  25) METIS/5.1.0-gimkl-2017a        38) GCC/6.3.0
 13) libjpeg-turbo/1.5.1-gimkl-2017a            26) SuiteSparse/4.5.4-gimkl-2017a  39) OpenMPI/2.0.2-GCC-6.3.0


When I try to do 'make' on ~/cosmomc, I get

Code:
mkdir -p ReleaseMPI
cd ../camb && \
   make --file=Makefile_main libcamb OUTPUT_DIR=ReleaseMPI \
   RECOMBINATION=recfast EQUATIONS=equations_ppf NONLINEAR=halofit_ppf
make[1]: Entering directory `/gpfs1m/projects/uoa00518/cosmomc/camb'
mkdir -p ReleaseMPI
mpif90 -mkl -O3 -no-prec-div -fpp -qopenmp -xHost -DMPI -module ReleaseMPI -IReleaseMPI/ -c constants.f90 -o ReleaseMPI/constants.o
gfortran: error: unrecognized command line option ‘-mkl’
gfortran: error: unrecognized command line option ‘-no-prec-div’; did you mean ‘-fno-tree-dce’?
gfortran: error: unrecognized command line option ‘-fpp’; did you mean ‘-cpp’?
gfortran: error: unrecognized command line option ‘-qopenmp’; did you mean ‘-fopenmp’?
gfortran: error: unrecognized command line option ‘-module’; did you mean ‘-mhle’?
make[1]: *** [ReleaseMPI/constants.o] Error 1
make[1]: Leaving directory `/gpfs1m/projects/uoa00518/cosmomc/camb'
make: *** [camb] Error 2


and I'm not quite sure what it all means. It would be great if someone could point in the right direction! The paper 1409.1354v3 did not quite resolve my issues, from what I can see.
Back to top
View user's profile  
Antony Lewis



Joined: 23 Sep 2004
Posts: 1243
Affiliation: University of Sussex

PostPosted: June 12 2017  Reply with quote

You may need to use mpif90 -f90=ifort or similar.
Back to top
View user's profile [ Hidden ] Visit poster's website
Mason Ng



Joined: 17 May 2017
Posts: 10
Affiliation: The University of Auckland

PostPosted: June 12 2017  Reply with quote

Antony Lewis wrote:
You may need to use mpif90 -f90=ifort or similar.


Hi Antony, thanks for the reply. The relevant part of source/Makefile now looks like
Code:

OUTPUT_DIR ?= Release

BUILD ?= MPI
#set BUILD to MPI to force MPI, should be set in ../Makefile

#MPIF90C ?= mpif90
MPIF90C ?= mpiifort

ifortErr = $(shell which ifort >/dev/null; echo $$?)

#these settings for ifort 14 and higher. Earlier versions will not work.
ifeq "$(ifortErr)" "0"
#ifort; Can remove -xHost if your cluster is not uniform, or specify specific processor optimizations -x...

#F90C     = ifort
mpif90 -f90=ifort
#use this if mpif90 is trying to use gfortran: MPIF90C = mpif90 -f90=ifort


but the output is

Code:
cd ./source && make cosmomc BUILD=MPI
make[1]: Entering directory `/gpfs1m/projects/uoa00518/cosmomc/source'
mkdir -p ReleaseMPI
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/cosmomc/camb'
mkdir -p ReleaseMPI
mpiifort -mkl -O3 -no-prec-div -fpp -qopenmp -xHost -DMPI -module ReleaseMPI -IReleaseMPI/ -c constants.f90 -o ReleaseMPI/constants.o
gfortran: error: unrecognized command line option ‘-mkl’
gfortran: error: unrecognized command line option ‘-no-prec-div’; did you mean ‘-fno-tree-dce’?
gfortran: error: unrecognized command line option ‘-fpp’; did you mean ‘-cpp’?
gfortran: error: unrecognized command line option ‘-qopenmp’; did you mean ‘-fopenmp’?
gfortran: error: unrecognized command line option ‘-module’; did you mean ‘-mhle’?
make[2]: *** [ReleaseMPI/constants.o] Error 1
make[2]: Leaving directory `/gpfs1m/projects/uoa00518/cosmomc/camb'
make[1]: *** [camb] Error 2
make[1]: Leaving directory `/gpfs1m/projects/uoa00518/cosmomc/source'
make: *** [cosmomc] Error 2


unfortunately..
Back to top
View user's profile  
Antony Lewis



Joined: 23 Sep 2004
Posts: 1243
Affiliation: University of Sussex

PostPosted: June 12 2017  Reply with quote

Looks like a local configuration problem, presumably mpiifort is not supposed to be calling gfortran.
Back to top
View user's profile [ Hidden ] Visit poster's website
Mason Ng



Joined: 17 May 2017
Posts: 10
Affiliation: The University of Auckland

PostPosted: June 15 2017  Reply with quote

Antony Lewis wrote:
Looks like a local configuration problem, presumably mpiifort is not supposed to be calling gfortran.


That sounds right. I took this up with the cluster technical support team and it boiled down to loading the right modules/environments for CosmoMC to run it. Thanks!
Back to top
View user's profile  
Display posts from previous:   
Post new topic   Reply to topic    CosmoCoffee Forum Index -> Computers and software All times are GMT + 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group. Sponsored by WordWeb online dictionary and dictionary software.