cosmoDC2 from the LSST DESC

If you use cosmoDC2 in your work, please cite Korytov et al. (LSST DESC), ApJS, 245, 26 (2019). In addition, if you use GCRCatalogs as described here to access cosmoDC2, please also cite Mao et al. (LSST DESC), ApJS, 234, 36 (2018).

Obtain data files via DESC data portal (recommanded)

Please visit the DESC data portal lsstdesc-portal.nersc.gov and follow the instructions therein.

Obtain data files via HTTP

We recommand that you obtain data files via the DESC data portal (see above) and follow the instructions therein. The following instructions were only for users who obtain data files via HTTP. If you use the data portal, please disregard the content below.

Step 1: Download cosmoDC2 catalog files

The catalog files of cosmoDC2 can be downloaded from here. Put the files you downloaded into a single directory. Do not rename the files.

Step 2: Install GCRCatalogs

To help you access the cosmoDC2 data, the LSST DESC has developed the GCRCatalogs Pyhton package. While there are detailed instructions and tutorials available or linked from the GitHub repository of GCRCatalogs, they generally assume that the user is a DESC member and is running the code on NERSC. Nevertheless, some simple customization can enable you to use GCRCatalogs to access cosmoDC2 on your local machine.

GCRCatalogs can be installed with pip. This will also install dependencies for you.

pip install https://github.com/LSSTDESC/gcr-catalogs/archive/master.zip[cosmodc2]

GCRCatalogs is tested with Python 3.

Step 3: Load cosmoDC2 with GCRCatalogs

import GCRCatalogs

config_overwrite = dict(
    catalog_root_dir='/path/to/your/directory',
    check_file_list_complete=True,
    check_size=True,
)

cat = GCRCatalogs.load_catalog('cosmoDC2_v1.1.4_image', config_overwrite)

When you import GCRCatalogs, if you see a warning that says “Default root dir has not been set; catalogs may not be found,” please simply ignore it.

Here the config_overwrite dictionary customizes GCRCatalogs for use on your local machine. The option catalog_root_dir specifies where the catalog files are stored. If you only downloaded a subset of files, set check_file_list_complete to False so that it won’t raise an error when the file list is not complete. You can also turn off check_size to disable sanify file size check to speed up load time.

Note that you will only be able to load cosmoDC2_v1.1.4_image and cosmoDC2_v1.1.4_small on your local machine (the latter is just a subset of the former), since those are the files that you have downloaded in Step 2.

Step 4: Get familiar with GCRCatalogs and cosmoDC2

There are many tutorial notebooks showing you how to use GCRCatalogs and how to play with the cosmoDC2 data. Note that you need to apply the config_overwrite as expained in the previous step when loading the catalog.

Note that in some tutorials you may see instructions of loading other catalogs with GCRCatalogs. Those instructions will not work on your local machine. As mentioned earlier, you will only be able to load cosmoDC2_v1.1.4_image and cosmoDC2_v1.1.4_small.