Comments (5)
Is this already done?
I just check the schema, and noticed there are wired keys appeared in the root: optional_kwargs
required_kwargs
, why is that? @FynnBe
I am thinking maybe we should write the schema manually, in that case, will you be able to read a json schema file and use it in the python package?
from core-bioimage-io-python.
Is this already done?
yes, I forgot about this issue...
I just check the schema, and noticed there are wired keys appeared in the root: optional_kwargs required_kwargs, why is that? @FynnBe
The optional_kwargs
and required_kwargs
keys are there to specify any kwargs optional/required for model instantiation, as source points to a callable...
I am thinking maybe we should write the schema manually, in that case, will you be able to read a json schema file and use it in the python package?
we use marshmallow to specify the schema, which allows for more validation and exporting of the json schema (with a subset of the 'rules'). As marshmallow is more powerful, I would like to keep it this way.
What would you want to change manually? Maybe we can just adapt the schema in marshmallow accordingly?
from core-bioimage-io-python.
Thanks @FynnBe for the explanation.
The
optional_kwargs
andrequired_kwargs
keys are there to specify any kwargs optional/required for model instantiation, as source points to a callable...
But this is not in our configuration specification right, is there a way to clean up the exported json schema?
What would you want to change manually? Maybe we can just adapt the schema in marshmallow accordingly?
I would like to make a model config generator/validator plugin in javascript, so users can build model config from an UI and we can add a badge for validated model cards. Even more, for those not validated ones we show an info button where the developer can click and we can show a list of errors, warnings and suggestions.
I can either redo it in javascript and make an bioengine app for that, or we can run the marshmallow validation when we compile the yaml file to the manifest json (in a CI), then add the validation report to the generated json file.
The JSON schema is also important, even though it's a subset of the rules, we can share it between different language (e.g. Java/JS).
Related to these, I have two additional questions:
-
when I pass the yaml config to marshmallow to validate, can you generate a detailed report? Not just passed or failed, but ideally also more detailed information for different levels: error, warning, recommendation etc.
-
For the generated JSON schema, can we clean it up to remove for example keys like
required_kwargs
, it's a bit confusing when we generate an HTML form with it and it has these keys.
from core-bioimage-io-python.
But this is not in our configuration specification right, is there a way to clean up the exported json schema?
For the generated JSON schema, can we clean it up to remove for example keys like required_kwargs, it's a bit confusing when we generate an HTML form with it and it has these keys.
sure thing, we can just drop them to have the models self-contained
Maybe we should add them to the specification, though? Let's discuss that in #31, and I'll remove them from the json schema for now.
- remove kwargs from model json schema
I can either redo it in javascript and make an bioengine app for that, or we can run the marshmallow validation when we compile the yaml file to the manifest json (in a CI), then add the validation report to the generated json file.
Running a CI was the plan afaik... With the marshmallow schema we implemented a fast validation (format + easy to check cross field checks) and one that would require some more computation (running source code, etc..)
when I pass the yaml config to marshmallow to validate, can you generate a detailed report? Not just passed or failed, but ideally also more detailed information for different levels: error, warning, recommendation etc.
yes, exactly which field fails why and which fields collide
from core-bioimage-io-python.
- improve exported json: bioimage-io/bioimage-io-resources#22 (comment)
from core-bioimage-io-python.
Related Issues (20)
- MONAI translation to BioImage format HOT 1
- Image normalization causing test_model test failure HOT 3
- Provide our CI testing environment as docker containers
- Reproducibility test for model creation fails HOT 3
- Hackathon 2023/10 notes HOT 2
- programmatic access for datasets
- Add support for release candidates and automatic mail updates
- developer documentation
- Investigate integration of aicsimageio
- Add/improve weight converters
- Loading model resource gives assertion error HOT 2
- Link in example broken HOT 1
- Running `test_model` raises TypeError: list indices must be integers or slices, not str HOT 1
- Improve weights conversion to ONNX HOT 1
- bug when `add_deepimagej_config=True` in `build_model` HOT 5
- Error when importing HOT 2
- add block overlap and block stitching of overlapping blocks with masks/averaging
- Previously working code has stopped to work with import error HOT 8
- Running a model doesn't work when zenodo is down or without internet connection HOT 3
- Pytorch Lightning model adaptor
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from core-bioimage-io-python.