Skip to content

Commit 37a558a

Browse files
committed
add dependencies field to tensorflow_saved_model_bundle weights
1 parent 2d5768e commit 37a558a

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

bioimageio/spec/_internal/validation_context.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
from pathlib import Path
2-
from typing import Any, Dict, Literal, Optional, Tuple, Union
2+
from typing import Any, Dict, Literal, Optional, Union
33

44
from pydantic import AnyUrl, BaseModel, DirectoryPath
55
from typing_extensions import NotRequired, TypedDict

bioimageio/spec/model/v0_5.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -880,13 +880,14 @@ class PytorchStateDictWeights(WeightsEntryBase, frozen=True):
880880
type = "pytorch_state_dict"
881881
weights_format_name: ClassVar[str] = "Pytorch State Dict"
882882
architecture: Architecture
883-
dependencies: Optional[Dependencies] = None
884-
"""Custom dependencies beyond pytorch.
885-
Should include pytorch and any version pinning has to be compatible with `pytorch_version`."""
886883
pytorch_version: Version
887884
"""Version of the PyTorch library used.
888885
If `depencencies` is specified it has to include pytorch and any version pinning has to be compatible."""
889886

887+
dependencies: Optional[Dependencies] = None
888+
"""Custom dependencies beyond pytorch.
889+
Should include pytorch and any version pinning has to be compatible with `pytorch_version`."""
890+
890891

891892
class TensorflowJsWeights(WeightsEntryBase, frozen=True):
892893
type = "tensorflow_js"
@@ -905,6 +906,10 @@ class TensorflowSavedModelBundleWeights(WeightsEntryBase, frozen=True):
905906
tensorflow_version: Version
906907
"""Version of the TensorFlow library used."""
907908

909+
dependencies: Optional[Dependencies] = None
910+
"""Custom dependencies beyond tensorflow.
911+
Should include tensorflow and any version pinning has to be compatible with `tensorflow_version`."""
912+
908913
source: Union[HttpUrl, RelativeFilePath]
909914
"""∈📦 The multi-file weights.
910915
All required files/folders should be a zip archive."""

0 commit comments

Comments
 (0)