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

Make catalog tables interactive #3099

Merged
merged 12 commits into from
Sep 13, 2024

Conversation

kcarver1
Copy link
Contributor

Description

This pull request is to address making the table interactive, mainly adding a zoom feature and additional markers for selected points.

Change log entry

  • Is a change log needed? If yes, is it added to CHANGES.rst? If you want to avoid merge conflicts,
    list the proposed change log here for review and add to CHANGES.rst before merge. If no, maintainer
    should add a no-changelog-entry-needed label.

Checklist for package maintainer(s)

This checklist is meant to remind the package maintainer(s) who will review this pull request of some common things to look for. This list is not exhaustive.

  • Are two approvals required? Branch protection rule does not check for the second approval. If a second approval is not necessary, please apply the trivial label.
  • Do the proposed changes actually accomplish desired goals? Also manually run the affected example notebooks, if necessary.
  • Do the proposed changes follow the STScI Style Guides?
  • Are tests added/updated as required? If so, do they follow the STScI Style Guides?
  • Are docs added/updated as required? If so, do they follow the STScI Style Guides?
  • Did the CI pass? If not, are the failures related?
  • Is a milestone set? Set this to bugfix milestone if this is a bug fix and needs to be released ASAP; otherwise, set this to the next major release milestone. Bugfix milestone also needs an accompanying backport label.
  • After merge, any internal documentations need updating (e.g., JIRA, Innerspace)?

@github-actions github-actions bot added imviz plugin Label for plugins common to multiple configurations labels Jul 18, 2024
@bmorris3 bmorris3 changed the title Making table interactive Make catalog tables interactive Jul 18, 2024
@kcarver1
Copy link
Contributor Author

Right now, I have the x and y pixel coordinates to be used to create markers. Additionally, I have created a class for a catalog specific marker. The markers are still not being added as expected however, so I pushed what I had to get some fresh eyes on the new code.

@javerbukh javerbukh added this to the 4.0 milestone Jul 29, 2024
Copy link

codecov bot commented Jul 29, 2024

Codecov Report

Attention: Patch coverage is 94.11765% with 4 lines in your changes missing coverage. Please review.

Project coverage is 88.48%. Comparing base (f4a6889) to head (9842c5a).
Report is 80 commits behind head on main.

Files with missing lines Patch % Lines
jdaviz/configs/imviz/plugins/catalogs/catalogs.py 94.73% 3 Missing ⚠️
jdaviz/core/template_mixin.py 85.71% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3099      +/-   ##
==========================================
- Coverage   88.82%   88.48%   -0.34%     
==========================================
  Files         112      124      +12     
  Lines       17430    18443    +1013     
==========================================
+ Hits        15482    16320     +838     
- Misses       1948     2123     +175     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Katherine Carver and others added 4 commits August 5, 2024 11:57
Resolved merge conflict in catalogs.py and catalogs.vue#

Resolved merge conflict in catalogs.py and catalogs.vue

adding new markers

added x,y pixel coords to table; will be used for markers later

small changes

orginal markers are not being plotted

Added user marks

prep for rebase
@gibsongreen
Copy link
Contributor

gibsongreen commented Sep 6, 2024

I wasn't involved in the review process much so I have a few questions about the expected functionality:

  1. From the UI, is it expected that when a selection of a particular source is made, that all are selected?
  2. There is the Max sources input parameter, I would imagine the main use case being to prevent < 1000 sources. I was expecting inputing 1 to and expected the table to show only 1 result, using the Gaia catalog and the Example notebook data, I get 17 sources irregardless of changing this value (would we also want to expose this?)
  3. Is it in scope for this ticket/do we want API expose functionality for Zoom to Selected & selecting a particular source from the table?
  4. get_catalog_source_results() is accessible from the config, but I was expecting to see it in the directory for the plugin, is it desired/in scope to move this to the plugin instead?

Update:
5. I'm struggling a bit with importing a custom table. There must be a sky_centroid column in the table in order to load into the plugin, however, with this included, it does not load in the viewer nor the UI, but get_catalog_source_results() will show the table, with the additional column included. I'm assuming it's because of the additional column that it doesn't parse the table correctly. The parsing could probably use some generalization too to allow variable order of the required columns (these both can be in a follow up)

@javerbukh
Copy link
Contributor

  1. I see what you mean but it looks like it's an issue with line
    with conf.set_temp("ROW_LIMIT", self.max_gaia_sources):
    so I think that would be outside the scope of this ticket and may need a follow-up.
  2. Same as above, I hesitate for this ticket to become a catch all for Catalog's bug fixes + improvements when it was just meant to fix the functionality originally added by our intern.
  3. Same as above.
  4. I'm not sure why the table with sky_centroid would not load into the viewer, so another follow-up may be necessary.

To summarize, I think we need follow-up tickets for the following:

  1. Bug: Gaia max sources are not being limited by the traitlet.
  2. Expose API functionality for the Catalog Plugin and move get_catalog_source_results() to an appropriate location.
  3. Enable Zoom and row select functionality for custom files.

Copy link
Contributor

@gibsongreen gibsongreen left a comment

Choose a reason for hiding this comment

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

To summarize, I think we need follow-up tickets for the following:

  1. Bug: Gaia max sources are not being limited by the traitlet.
  2. Expose API functionality for the Catalog Plugin and move get_catalog_source_results() to an appropriate location.
  3. Enable Zoom and row select functionality for custom files.

The issues with sky_centroid/From File... and Max sources both currently exist on main and can be addressed later in follow up efforts. We seem to have this well scoped out now, great work!

@javerbukh
Copy link
Contributor

Follow-up tickets have been created.

jdaviz/configs/imviz/plugins/catalogs/catalogs.py Outdated Show resolved Hide resolved
jdaviz/configs/imviz/plugins/catalogs/catalogs.py Outdated Show resolved Hide resolved
jdaviz/configs/imviz/plugins/catalogs/catalogs.py Outdated Show resolved Hide resolved
jdaviz/configs/imviz/plugins/catalogs/catalogs.py Outdated Show resolved Hide resolved
jdaviz/configs/imviz/plugins/catalogs/catalogs.py Outdated Show resolved Hide resolved
jdaviz/configs/imviz/plugins/catalogs/catalogs.vue Outdated Show resolved Hide resolved
@javerbukh javerbukh merged commit 6b83d77 into spacetelescope:main Sep 13, 2024
18 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
imviz plugin Label for plugins common to multiple configurations Ready for final review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants