Skip to content

Commit bc98d65

Browse files
committed
do not convert axis id
from axis like strings as if they are default values from model 0.4 to model 0.5
1 parent 14f599e commit bc98d65

File tree

2 files changed

+2
-15
lines changed

2 files changed

+2
-15
lines changed

bioimageio/core/axis.py

+1-14
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,6 @@ def _get_axis_type(a: Literal["b", "t", "i", "c", "x", "y", "z"]):
2626
S = TypeVar("S", bound=str)
2727

2828

29-
def _get_axis_id(a: Union[Literal["b", "t", "i", "c"], S]):
30-
if a == "b":
31-
return AxisId("batch")
32-
elif a == "t":
33-
return AxisId("time")
34-
elif a == "i":
35-
return AxisId("index")
36-
elif a == "c":
37-
return AxisId("channel")
38-
else:
39-
return AxisId(a)
40-
41-
4229
AxisId = v0_5.AxisId
4330

4431
T = TypeVar("T")
@@ -62,7 +49,7 @@ def create(cls, axis: AxisLike) -> Axis:
6249
elif isinstance(axis, Axis):
6350
return Axis(id=axis.id, type=axis.type)
6451
elif isinstance(axis, str):
65-
return Axis(id=_get_axis_id(axis), type=_get_axis_type(axis))
52+
return Axis(id=AxisId(axis), type=_get_axis_type(axis))
6653
elif isinstance(axis, v0_5.AxisBase):
6754
return Axis(id=AxisId(axis.id), type=axis.type)
6855
else:

bioimageio/core/prediction.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def predict(
5959
Note: For a predetermined, fixed block shape use `input_block_shape`
6060
input_block_shape: (optional) tile the input sample tensors into blocks.
6161
Note: For a parameterized block shape, not dealing with the exact block shape,
62-
use `blocksie_parameter`.
62+
use `blocksize_parameter`.
6363
skip_preprocessing: flag to skip the model's preprocessing
6464
skip_postprocessing: flag to skip the model's postprocessing
6565
save_output_path: A path with `{member_id}` `{sample_id}` in it

0 commit comments

Comments
 (0)