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

Extend si.load capabilities #3651

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

alejoe91
Copy link
Member

This PR extends the si.load magic function to load also SortingAnalyzers.

In addition, a better logic is implemented to load zarr files, both locally and remotely, including trying to open the folder with different options: zarr.open/zarr.open_consolidated and anon False/True for remote assets. This simplifies handling of zarr opening everywhere

@alejoe91 alejoe91 added this to the 0.102.0 milestone Jan 29, 2025
@alejoe91 alejoe91 requested a review from samuelgarcia January 29, 2025 14:13
@alejoe91 alejoe91 added the core Changes to core module label Jan 29, 2025
@@ -123,6 +123,7 @@ test_core = [
"pytest",
"pytest-dependency",
"psutil",
"s3fs", # for streaming tests
Copy link
Member

Choose a reason for hiding this comment

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

This is a big one for core tests no ?

@samuelgarcia
Copy link
Member

Good idea but I am not sure to like the design with try except.
We need to do clear check on json files or zarr attribute (also) json for information on chich object it is.

@samuelgarcia
Copy link
Member

We could also add the Motion object.

@samuelgarcia
Copy link
Member

And also Template

@samuelgarcia
Copy link
Member

@alejoe91 : I refactor everything to have more general case.
This looks big but this is an easier design which avoid nested if else evrywhere.
You will see that there are 2 steps guess the object and then loading.
This is more easy to maintains.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Changes to core module
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants