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

[python] Fix output type when exporting PointCloudDataFrame to SpatialData points #3408

Merged
merged 2 commits into from
Dec 9, 2024

Conversation

jp-dark
Copy link
Collaborator

@jp-dark jp-dark commented Dec 9, 2024

The previous implementation of to_spatial_data_points was exporting data to a pandas DataFrame, but SpatialData expected a dask DataFrame. This type error was not caught in the tests using spatialdata.models.PointsModel.validate. This fixes the tests to check the type along with additional validataion by using spatialdata.models.get_model instead of the validate methods, and updates the exporter to return the correct type.

@jp-dark jp-dark requested review from ktsitsi and johnkerl December 9, 2024 17:52
Copy link
Member

@johnkerl johnkerl left a comment

Choose a reason for hiding this comment

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

🚢

Copy link

codecov bot commented Dec 9, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 85.89%. Comparing base (c4fe227) to head (37d4702).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3408      +/-   ##
==========================================
+ Coverage   85.83%   85.89%   +0.05%     
==========================================
  Files          55       55              
  Lines        6191     6195       +4     
==========================================
+ Hits         5314     5321       +7     
+ Misses        877      874       -3     
Flag Coverage Δ
python 85.89% <50.00%> (+0.05%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
python_api 85.89% <50.00%> (+0.05%) ⬆️
libtiledbsoma ∅ <ø> (∅)

@jp-dark jp-dark merged commit 504df5f into main Dec 9, 2024
11 checks passed
@jp-dark jp-dark deleted the dark/spatial-data-points-fix branch December 9, 2024 18:52
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.

2 participants