drphilmarshall / Pangloss

Line of sight mass reconstruction in the Universe
GNU General Public License v2.0
10 stars 10 forks source link

Pangloss

Pangloss is software module for reconstructing all the mass within a light cone through the Universe. Understanding complex mass distributions like this is important for accurate time delay lens cosmography, and also for accurate lens magnification estimation. It aspires to use all available data in an attempt to make the best of all mass maps. However, this problem is sufficiently difficult that we are mostly spending our time cultivating a garden of toy models and baby steps.

If you are interested in the ongoing investigation of this interesting problem, you should:

License

Pangloss is distributed under the Gnu Public License (GPL) v2, a copy of which is delivered with this code. This basically means you can do anything you like with it, as long as you keep propagating the license information.

However, when reporting on your use of Pangloss, we do ask that you include:

Installation

After cloning or forking the repository, add the following lines (or similar) to your .login file:

setenv PANGLOSS_DIR ${WORK_DIR}/Pangloss
setenv PYTHONPATH ${PANGLOSS_DIR}/Pangloss:${PYTHONPATH}
setenv PATH ${PATH}:${PANGLOSS_DIR}

Then "import pangloss" from python should just work, and the command line scripts should too. However, you will need to have the following packages installed as well:

import atpy,asciitable,pyfits
import numpy,scipy,getopt,matplotlib

Most (if not all) are available via pip and/or homebrew.

Example use

Right now, there are three main scripts that carry out Pangloss's functions:

They all take, as their sole input, the same configuration file, an example of which is given here.

In the calib directory we include the means to obtain the halo catalog for a 1x1 square degree patch of Millennium Simulation sky, and its associated ray traced convergence map, for making the calibration lightcones. A small mock observed galaxy catalog is included in the example directory, for testing.

To get the test data, please do the following:

cd calib
Fetch.csh

The Fetch script uses wget. Additional galaxy catalogs and ray-traced convergence maps from the Millenium Simulation are available from Stefan Hilbert on request.

You should then be able to execute the following example analysis:

cd example
Drill.py example.config
Reconstruct.py example.config
Calibrate.py example.config

Analysing from start to finish will take some time. Be patient! (Drill ~2 mins, Reconstruct ~10 mins)

For more details of what the Pangloss scripts are doing, start reading the code here.

Also, check out Tom's flowchart that describes the process of data simulation and testing carried out in Collett et al (2013):

Collet et al 2013 flowchart

PDFs based on overdensities

The original Pangloss has been modified so that it can be used to find convergence and magnification pdfs for any given group of fields based on comparing overdensities of the observed fields with simulation lightcones.