You may now use `dustmaps` in stack packages

Tags: #<Tag:0x00007fb380131f60>

As of the lsst-scipipe-0.3.1 stack conda env, the dustmaps package is now available as a third party dependency. In addition to the dustmaps package, there is also a new stack package called dustmaps_cachedata that contains cached versions of the SFD dust maps used by dustmaps.

If you create a package that uses dustmaps, please add the dustmaps_cachedata package to the eups table file. You will also need to add a line to your tests/SConscript file in order to let through the environment variable needed by dustmaps to find the overridden data cache location:

env['ENV']['DUSTMAPS_CONFIG_FNAME'] = os.environ['DUSTMAPS_CONFIG_FNAME']

That environment variable is set when the dustmaps_cachedata package is setup, so no user intervention is needed. See an example here which will be moved here shortly.

As mentioned above, only the SFD maps are distributed as a cached dataset. This decision was made by taking an informal census of the people on the project who currently use the dustmaps package. If you wish to add more data to the cached data package, please file an RFC requesting the addition. Note that this package is not a git-lfs package, so adding maps that exceed the GitHub 100MB limit will require extra work.

2 Likes

Apologies. @laurenam points out that the link to the SConscript file is not the right one at the moment. The correct one is still on a branch, but hopefully will merge today. For the moment, see here for the example.