General clean-ups and speed-ups for DR9 work #658
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR cleans-up (and speeds-up) some functionality as we move towards producing DR9 targets and fiberassign files. It includes:
skies
into their correct HEALPixels.skies
are run in bricks that are centered in HEALPixels, rather than in the actual boundaries of a HEALPixel, so they need to be "repartitioned" into the correct pixels (see Repartition sky files so sky locations lie within HEALPixel boundaries #621); this PR changes the organization of the input/output files to automatically reflect the data model that I have started to use when releasing targets.desitarget.io.read_targets_in_X
functions:read_targets_in_tiles(quick=True)
,read_targets_in_box(quick=True)
,read_targets_in_cap(quick=True)
,read_targets_in_hp(quick=True)
."quick=True"
versions are more fragile).nside
. Comparing targets partitioned into files atnside=2
versusnside=8
, the speed-up was 5x.MASKBITS
combinations for all of the target classes that can be read via convenience functions, and using those convenience functions to automatically inform the"FRACAREA_X"
calculations inpixweight
files.MASKBITS
cuts adopted by the target files are always aligned with those calculated in thepixweight
files.