We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4b9c80f commit ab23716Copy full SHA for ab23716
bioimageio/core/build_spec/build_model.py
@@ -895,7 +895,15 @@ def build_model(
895
kwargs["parent"] = {"uri": parent[0], "sha256": parent[1]}
896
897
if training_data is not None:
898
- kwargs["training_data"] = training_data
+ if "id" in training_data:
899
+ msg = f"If training data is specified via 'id' no other keys are allowed, got {training_data}"
900
+ assert len(training_data) == 1, msg
901
+ kwargs["training_data"] = training_data
902
+ else:
903
+ if "type" not in training_data:
904
+ training_data["type"] = "dataset"
905
+ if "format_version" not in training_data:
906
+ training_data["format_version"] = spec.dataset.format_version
907
908
try:
909
model = model_spec.raw_nodes.Model(
0 commit comments