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

warn many shapes as points #224

Merged
merged 5 commits into from
Mar 28, 2024
Merged

Conversation

melonora
Copy link
Collaborator

@melonora melonora commented Mar 26, 2024

closes #213

This PR checks whether there is a point geometry in a shapes element and if the length of the element exceeds 1m adds an icon to the list widget item. When a user then hovers over the item they get to see a warning regarding visualization.

@melonora
Copy link
Collaborator Author

This could also potentially be extended to put warning signs and tooltips for the subsampling of points.

@codecov-commenter
Copy link

Codecov Report

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

❗ No coverage uploaded for pull request base (main@83ef3d8). Click here to learn what that means.

Files Patch % Lines
src/napari_spatialdata/_sdata_widgets.py 86.66% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #224   +/-   ##
=======================================
  Coverage        ?   75.88%           
=======================================
  Files           ?       18           
  Lines           ?     2015           
  Branches        ?        0           
=======================================
  Hits            ?     1529           
  Misses          ?      486           
  Partials        ?        0           

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

@LucaMarconato
Copy link
Member

Thanks, this looks great! As discussed I have reduced the threshold, extended this to polygons/multipolygons (with a lower threshold) and moved the constants to the config.py file.

@LucaMarconato LucaMarconato merged commit 58c95f2 into scverse:main Mar 28, 2024
5 of 6 checks passed
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.

Warn users that layers with many shapes are slow to render
3 participants