File tree Expand file tree Collapse file tree 1 file changed +21
-3
lines changed Expand file tree Collapse file tree 1 file changed +21
-3
lines changed Original file line number Diff line number Diff line change 66
77from typing_extensions import Literal
88
9- from bioimageio .core .common import SupportedWeightsFormat
109from bioimageio .spec import (
1110 InvalidDescr ,
1211 ResourceDescr ,
1716
1817from ._resource_tests import test_description
1918
20- WeightFormatArgAll = Literal [SupportedWeightsFormat , "all" ]
21- WeightFormatArgAny = Literal [SupportedWeightsFormat , "any" ]
19+ # unfortunately this does not work with py3.9 and pydantic 2.11
20+ # from bioimageio.core.common import SupportedWeightsFormat
21+ # WeightFormatArgAll = Literal[SupportedWeightsFormat, "all"]
22+ # WeightFormatArgAny = Literal[SupportedWeightsFormat, "any"]
23+ # so we write out the literal explicitly
24+ WeightFormatArgAll = Literal [
25+ "keras_hdf5" ,
26+ "onnx" ,
27+ "pytorch_state_dict" ,
28+ "tensorflow_saved_model_bundle" ,
29+ "torchscript" ,
30+ "all" ,
31+ ]
32+ WeightFormatArgAny = Literal [
33+ "keras_hdf5" ,
34+ "onnx" ,
35+ "pytorch_state_dict" ,
36+ "tensorflow_saved_model_bundle" ,
37+ "torchscript" ,
38+ "any" ,
39+ ]
2240
2341
2442def test (
You can’t perform that action at this time.
0 commit comments