astronomy-commons / hipscat

Hierarchical Progressive Survey Catalog
https://hipscat.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
17 stars 3 forks source link

Optimize Inner PixelTree Alignment #259

Closed smcguire-cmu closed 5 months ago

smcguire-cmu commented 5 months ago

When performing inner pixel tree alignments, we can bound the maximum number of aligned pixels, meaning we can make inner alignments more performant by using an array of the maximum length instead of appending to a list.

Adds benchmarks for pixel tree alignment.

github-actions[bot] commented 5 months ago
Before [99bd6ca4] After [2f17347e] Ratio Benchmark (Parameter)
360±2ms 363±4ms 1.01 benchmarks.Suite.time_outer_pixel_alignment
40.7±0.8ms 41.1±1ms 1.01 benchmarks.Suite.time_pixel_tree_creation
83.6±1ms 84.0±2ms 1 benchmarks.Suite.time_paths_creation
124±0.3ms 124±0.6ms 1 benchmarks.time_test_alignment_even_sky
13.4±0.3ms 13.4±0.04ms 1 benchmarks.time_test_cone_filter_multiple_order
19.7±0.5ms 19.3±0.6ms 0.98 benchmarks.MetadataSuite.time_load_partition_info_order6
78.6±0.7ms 76.9±0.5ms 0.98 benchmarks.MetadataSuite.time_load_partition_info_order7
79.1±1ms 76.6±0.3ms 0.97 benchmarks.MetadataSuite.time_load_partition_join_info
86.5±1ms 13.2±0.2ms 0.15 benchmarks.Suite.time_inner_pixel_alignment

Click here to view all benchmarks.

codecov[bot] commented 5 months ago

Codecov Report

Attention: Patch coverage is 20.51282% with 31 lines in your changes are missing coverage. Please review.

Project coverage is 94.15%. Comparing base (238c074) to head (8bd88f1). Report is 3 commits behind head on main.

:exclamation: Current head 8bd88f1 differs from pull request most recent head 8182826. Consider uploading reports for the commit 8182826 to get more accurate results

Files Patch % Lines
src/hipscat/pixel_tree/pixel_alignment.py 20.51% 31 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #259 +/- ## ========================================== - Coverage 95.74% 94.15% -1.60% ========================================== Files 56 56 Lines 1880 1915 +35 ========================================== + Hits 1800 1803 +3 - Misses 80 112 +32 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.