Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Catalog Alignment class and functions #110

Merged
merged 18 commits into from
Jul 14, 2023
Merged

Conversation

smcguire-cmu
Copy link
Contributor

Change Description

Creates the CatalogAlignment class to represent the alignment between catalogs. This includes a table with the pixel-to-pixel mapping between the files in each catalog, and the resulting tree from selecting the highest level of partitioning in each branch.

Adds functions to compute the alignment between catalogs. This includes adding functionality to the PixelTreeBuilder class.

resolves #9

  • My PR includes a link to the issue that I am addressing

Solution Description

The algorithm to perform the catalog alignment is described in detail in this design document

Code Quality

  • I have read the Contribution Guide
  • My code follows the code style of this project
  • My code builds (or compiles) cleanly without any errors or warnings
  • My code contains relevant comments and necessary documentation

New Feature Checklist

  • I have added or updated the docstrings associated with my feature using the NumPy docstring format
  • I have updated the tutorial to highlight my new feature (if appropriate)
  • I have added unit/End-to-End (E2E) test cases to cover my new feature
  • My change includes a breaking change
    • My change includes backwards compatibility and deprecation warnings (if possible)

# Conflicts:
#	src/hipscat/catalog/__init__.py
#	src/hipscat/catalog/association_catalog/__init__.py
#	src/hipscat/catalog/association_catalog/association_catalog.py
#	src/hipscat/pixel_tree/pixel_tree.py
#	src/hipscat/pixel_tree/pixel_tree_builder.py
src/hipscat/pixel_math/healpix_pixel.py Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_node.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_tree_builder.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_tree_builder.py Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_tree.py Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Outdated Show resolved Hide resolved
Copy link
Contributor

@jeremykubica jeremykubica left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I went through the design document and it clarified some of my questions. Thanks!

src/hipscat/pixel_math/healpix_pixel.py Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_node.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Outdated Show resolved Hide resolved
src/hipscat/pixel_tree/pixel_alignment.py Outdated Show resolved Hide resolved
smcguire-cmu and others added 2 commits July 11, 2023 18:11
Co-authored-by: Melissa DeLucchi <[email protected]>
Co-authored-by: Melissa DeLucchi <[email protected]>
@codecov
Copy link

codecov bot commented Jul 11, 2023

Codecov Report

Merging #110 (2a6688c) into main (6c11c4b) will increase coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #110      +/-   ##
==========================================
+ Coverage   99.83%   99.85%   +0.02%     
==========================================
  Files          41       44       +3     
  Lines        1181     1382     +201     
==========================================
+ Hits         1179     1380     +201     
  Misses          2        2              
Impacted Files Coverage Δ
src/hipscat/catalog/__init__.py 100.00% <100.00%> (ø)
...catalog/association_catalog/association_catalog.py 100.00% <100.00%> (ø)
src/hipscat/catalog/catalog.py 100.00% <100.00%> (ø)
src/hipscat/pixel_math/healpix_pixel.py 100.00% <100.00%> (ø)
src/hipscat/pixel_tree/__init__.py 100.00% <100.00%> (ø)
src/hipscat/pixel_tree/pixel_alignment.py 100.00% <100.00%> (ø)
src/hipscat/pixel_tree/pixel_alignment_types.py 100.00% <100.00%> (ø)
src/hipscat/pixel_tree/pixel_node.py 96.42% <100.00%> (+0.27%) ⬆️
src/hipscat/pixel_tree/pixel_tree.py 100.00% <100.00%> (ø)
src/hipscat/pixel_tree/pixel_tree_builder.py 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Contributor

@jeremykubica jeremykubica left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks really good. The new comments make it easier to follow and the tests have good cases.

I added one suggestion to the tests.

@smcguire-cmu smcguire-cmu merged commit 550021f into main Jul 14, 2023
10 checks passed
@smcguire-cmu smcguire-cmu deleted the sean/catalog-alignment branch January 3, 2024 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Compute catalog-to-catalog alignment
3 participants