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

Add weights format 'python' #291

Open
FynnBe opened this issue Nov 26, 2021 · 1 comment
Open

Add weights format 'python' #291

FynnBe opened this issue Nov 26, 2021 · 1 comment

Comments

@FynnBe
Copy link
Member

FynnBe commented Nov 26, 2021

in today's later part of the meeting the idea of formulating specialized transformations as bioimage.io models came up.
Our old ideas about a dedicated transformation spec could be revived by just slightly adapting the model spec, but even more promising and much easier would be to add a "python" weight format (or "pickle") to run a special python model/transformation (e.g. stardist postprocessing).

All fields of the current model spec are valid, only for the "weights" field the wording is slightly off, but some pure python models/transformations might make use of pickled weights. Other than that the model would behave just like a pytorch_state_dict model with source and kwargs.

cc @oeway @constantinpape

@oeway
Copy link
Contributor

oeway commented Nov 27, 2021

Related to this, one could then use libraries such as scikit-image (e.g. watershed) or albumentations or cellpose for providing generic "python models" that can be used as a custom pre-/post-processing. The only change we need is to support a special type of pre and post processing named model, then in the kwrags we provide an url/doi to the python model.

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

No branches or pull requests

2 participants