Small bug fix in the Planck Likelihood Code

30th April 2021


When working on the Hubble rate project, I am led to install Montepython to perform Markov Chain Monte Carlo sampling with Planck 2018 data. The Planck 2018 data can be downloaded from the Planck Legacy Archive together with the Planck Likelihood Code (plc), which provides C, Fortran and Python libraries allowing to compute the log likelihoods of the temperature, polarisation, and lensing maps. See readme.md of plc-3.01.

Following the documentation of Montepython, one needs to configure plc before installing it,

$ ./waf configure --lapack_mkl=${MKLROOT} --install_all_deps

which essentially checks and installs dependencies. Now, if no cfitsio has been installed, the program probably hangs during its automatic installation, before hitting a timeout error. This error occurs with COM_Likelihood_Code-v3.0_R3.01.

Solution

The error results from an attempt to download the file,

ftp://heasarc.gsfc.nasa.gov/software/fitsio/c/cfitsio3280.tar.gz

This looks suspicious in 2021 as major browsers are stopping FTP support, See https://blog.mozilla.org/security/2021/07/20/stopping-ftp-support-in-firefox-90/ and https://www.chromestatus.com/feature/6246151319715840. and websites are probably moving to more secure protocols, too.

It is indeed the case here, and the solution is to replace the above url by, Alternatively, choose https://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/cfitsio-3.49.tar.gz to specify a version. Note that v3.28 is not released this way and v3.49 is the closest available.

https://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/cfitsio_latest.tar.gz

in ./waf_tools/cfitsio.py. After downloading the package, automatic installation of cfitsio could still run into errors due to change in naming convention. Rename the path cfitsio-VERSION inside ./build to cfitsio and the problem is fully solved.

Update

The May 10th 2021 update of plc fixes this bug.

(Last updated on 06/01/2022)

All logs | Working with multiple branches 1