Skip to content

Commit 7af0e0f

Browse files
Merge pull request #261 from bioimage-io/oeway-patch-2
Expose model_adapter for the BioEngine
2 parents ad6daf8 + a664c2a commit 7af0e0f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

bioimageio/core/prediction_pipeline/_prediction_pipeline.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,7 @@ def create_prediction_pipeline(
183183
dataset_for_initial_statistics: Iterable[Sequence[xr.DataArray]] = tuple(),
184184
update_dataset_stats_after_n_samples: Optional[int] = None,
185185
update_dataset_stats_for_n_samples: int = float("inf"),
186+
model_adapter: Optional[ModelAdapter] = None,
186187
) -> PredictionPipeline:
187188
"""
188189
Creates prediction pipeline which includes:
@@ -192,7 +193,7 @@ def create_prediction_pipeline(
192193
* computation of output statistics
193194
* postprocessing
194195
"""
195-
model_adapter: ModelAdapter = create_model_adapter(
196+
model_adapter: ModelAdapter = model_adapter or create_model_adapter(
196197
bioimageio_model=bioimageio_model, devices=devices, weight_format=weight_format
197198
)
198199

0 commit comments

Comments
 (0)