-
Notifications
You must be signed in to change notification settings - Fork 8
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
Funlib persistence update #322
Conversation
fixing batch dim bugs (batch norm requires batch dimension even in predict mode) Seems to also fix the strange loss spike. I think it was due to setting model into eval mode and then not resetting to training at the end
Exceptions DVID and Resampled arrays
Added support for most of the remaining preprocessing operations.
|
i tried to run minimal example: dacapo/examples/starter_tutorial/minimal_tutorial.py Lines 111 to 118 in 108db88
because it doesn't fit to the new prepare_ds function https://github.com/funkelab/funlib.persistence/blob/3c0760e48edf1b287c4f75d7d11dc6b775332b2b/funlib/persistence/arrays/datasets.py#L121-L132 is there anyway to have a wrapper function (can have deprecated flag) that can support the old structure of the function. will be easier than looking for all the use of of prepare_ds and change them |
Oh sorry, I only fixed the version in I would recommend against a wrapper. I think it would be confusing to have two different versions of the same function that behave differently |
Upgrade to funlib.persistence
0.5
.This update makes a one big improvement:
Custom
Array
class no longer needed. We used this mostly just to apply preprocessing lazily to large arrays. Newfunlib
Array
class usesdask
internally which comes with much better support for lazy array operations than we built for ourselves. TheZarrArray
andNumpyArray
class which were used extensively throughoutDaCapo
have now been replaced with simplefunlib.persistence.Array
s.A minor incompatibility:
funlib.persistence.Array
has a convention (for now) that all axes have names, but non-spatial axes have a "^" in their name. This will be fixed in the near future. For now, DaCapo convention needed to change a little bit to adapt to this. We now have to use "c^" and "b^" for channel and batch dimensions instead of just "c" and "b".TODOs:
This pull request is not quire ready to merge. I pass the tests run with
pytest
, and theminimal_tutorial
notebook executes. But there is a lot of code that is not tested. Specifically many of theArrayConfig
subclasses are not yet tested and some are missing implementations.Here are the Preprocessing array configs, whether or not their implementation is complete, and their code coverage:
Best practice would be to add tests before merging, but I want to put this here so others can test it