| ๐ก |
bioimageio format validation |
| status |
valid-format |
| source |
https://hypha.aicell.io/bioimage-io/artifacts/kind-badger/files/rdf.yaml?version=v0 |
| id |
kind-badger |
| version |
1.0.0 |
| applied format |
model 0.5.10 |
| bioimageio.spec |
0.5.10.2 |
|
Location |
Details |
| โ๏ธ |
|
Successfully created `ModelDescr` instance. |
| โ๏ธ |
|
bioimageio.spec format validation model 0.5.10 |
| โ |
inputs.0.sample_tensor |
Needs to be filled for FAIR compliance |
| โ |
outputs.0.sample_tensor |
Needs to be filled for FAIR compliance |
| โ๏ธ |
weights.pytorch_state_dict |
Found existing conda environment 'f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225' |
| โ |
weights.pytorch_state_dict |
Reproduce test outputs from test inputs (pytorch_state_dict) |
| โ |
weights.pytorch_state_dict |
Failed to import bmz_model.py |
|
|
See Traceback 1. |
|
weights.pytorch_state_dict |
recommended conda environment (Reproduce test outputs from test inputs (pytorch_state_dict)) |
|
|
%YAML 1.2
---
channels:
- conda-forge
- nodefaults
dependencies:
- conda-forge::bioimageio.core>=0.9.4
- pip
- pytorch==2.9.1
- torchvision==0.24.1
|
|
weights.pytorch_state_dict |
conda compare (Reproduce test outputs from test inputs (pytorch_state_dict)) |
|
|
/usr/share/miniconda/lib/python3.13/site-packages/conda/env/env.py:288: FutureWarning: The
environment file is not fully CEP 24 compliant is deprecated and will be removed in 26.9. In the
future, this configuration will be rejected. Please fix the following errors in order to make
the configuration valid: - Invalid type for 'name', expected a str deprecated.topic(
Success. All the packages in the specification file are present in the environment with matching
version and build string. |
| โ |
weights.pytorch_state_dict |
Run pytorch_state_dict inference for parametrized inputs |
| โ |
weights.pytorch_state_dict |
Failed to import bmz_model.py |
|
|
See Traceback 2. |
Traceback 1
โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Traceback (most recent call last) โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 144 โ โ โ sys.modules[module_name] = module # cache this module โ
โ 145 โ โ โ โ
โ 146 โ โ โ assert importlib_spec.loader is not None โ
โ โฑ 147 โ โ โ importlib_spec.loader.exec_module(module) โ
โ 148 โ โ โ
โ 149 โ โ except Exception as e: โ
โ 150 โ โ โ if module_name in sys.modules: โ
โ in exec_module:1023 โ
โ in _call_with_frames_removed:488 โ
โ โ
โ /tmp/tmphpxaozor/bmz_model_a0a0eda4a48303c0893ef3841a26f825d07f8d452529015373ea3282af2357dc.py:6 โ
โ โ
โ 3 from functools import partial โ
โ 4 from inspect import isfunction โ
โ 5 โ
โ โฑ 6 import yaml โ
โ 7 import torch โ
โ 8 import torch.nn as nn โ
โ 9 import numpy as np โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
ModuleNotFoundError: No module named 'yaml'
The above exception was the direct cause of the following exception:
โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Traceback (most recent call last) โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 877 โ โ test_input = get_test_input_sample(model) โ
โ 878 โ โ expected = get_test_output_sample(model) โ
โ 879 โ โ โ
โ โฑ 880 โ โ with create_prediction_pipeline( โ
โ 881 โ โ โ bioimageio_model=model, devices=devices, weight_format=weight_format โ
โ 882 โ โ ) as prediction_pipeline: โ
โ 883 โ โ โ prediction_pipeline.apply_preprocessing(test_input) โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 468 โ โ โ f"deprecated create_prediction_pipeline kwargs: {set(deprecated_kwargs)}" โ
โ 469 โ โ ) โ
โ 470 โ โ
โ โฑ 471 โ model_adapter = model_adapter or create_model_adapter( โ
โ 472 โ โ model_description=bioimageio_model, โ
โ 473 โ โ devices=devices, โ
โ 474 โ โ weight_format_priority_order=weights_format and (weights_format,), โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 183 โ โ assert errors โ
โ 184 โ โ if len(weight_format_priority_order) == 1: โ
โ 185 โ โ โ assert len(errors) == 1 โ
โ โฑ 186 โ โ โ raise errors[0] โ
โ 187 โ โ โ
โ 188 โ โ else: โ
โ 189 โ โ โ msg = ( โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 113 โ โ โ โ try: โ
โ 114 โ โ โ โ โ from .pytorch_backend import PytorchModelAdapter โ
โ 115 โ โ โ โ โ โ
โ โฑ 116 โ โ โ โ โ return PytorchModelAdapter( โ
โ 117 โ โ โ โ โ โ model_description=model_description, devices=devices โ
โ 118 โ โ โ โ โ ) โ
โ 119 โ โ โ โ except Exception as e: โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 62 โ โ โ raise ValueError("No `pytorch_state_dict` weights found") โ
โ 63 โ โ โ
โ 64 โ โ devices = get_devices(devices) โ
โ โฑ 65 โ โ self._model = load_torch_model(weights, load_state=True, devices=devices) โ
โ 66 โ โ if mode == "eval": โ
โ 67 โ โ โ self._model = self._model.eval() โ
โ 68 โ โ elif mode == "train": โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 127 โ load_state: bool = True, โ
โ 128 โ devices: Optional[Sequence[Union[str, torch.device]]] = None, โ
โ 129 ) -> nn.Module: โ
โ โฑ 130 โ custom_callable = import_callable( โ
โ 131 โ โ weight_spec.architecture, โ
โ 132 โ โ sha256=( โ
โ 133 โ โ โ weight_spec.architecture_sha256 โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 75 โ elif isinstance(node, CallableFromFile): โ
โ 76 โ โ c = _import_from_file_impl(node.source_file, str(node.callable_name), **kwargs) โ
โ 77 โ elif isinstance(node, (ArchitectureFromFileDescr, v0_5.CustomProcessingDescr)): โ
โ โฑ 78 โ โ c = _import_from_file_impl(node.source, str(node.callable), sha256=node.sha256) โ
โ 79 โ else: โ
โ 80 โ โ assert_never(node) โ
โ 81 โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 150 โ โ โ if module_name in sys.modules: โ
โ 151 โ โ โ โ del sys.modules[module_name] โ
โ 152 โ โ โ โ
โ โฑ 153 โ โ โ raise ImportError(f"Failed to import {source}") from e โ
โ 154 โ โ
โ 155 โ try: โ
โ 156 โ โ callable_attr = getattr(module, callable_name) โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
ImportError: Failed to import bmz_model.py
Traceback 2
โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Traceback (most recent call last) โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 144 โ โ โ sys.modules[module_name] = module # cache this module โ
โ 145 โ โ โ โ
โ 146 โ โ โ assert importlib_spec.loader is not None โ
โ โฑ 147 โ โ โ importlib_spec.loader.exec_module(module) โ
โ 148 โ โ โ
โ 149 โ โ except Exception as e: โ
โ 150 โ โ โ if module_name in sys.modules: โ
โ in exec_module:1023 โ
โ in _call_with_frames_removed:488 โ
โ โ
โ /tmp/tmpmm32ov8t/bmz_model_a0a0eda4a48303c0893ef3841a26f825d07f8d452529015373ea3282af2357dc.py:6 โ
โ โ
โ 3 from functools import partial โ
โ 4 from inspect import isfunction โ
โ 5 โ
โ โฑ 6 import yaml โ
โ 7 import torch โ
โ 8 import torch.nn as nn โ
โ 9 import numpy as np โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
ModuleNotFoundError: No module named 'yaml'
The above exception was the direct cause of the following exception:
โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Traceback (most recent call last) โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 1124 โ try: โ
โ 1125 โ โ test_input = get_test_input_sample(model) โ
โ 1126 โ โ โ
โ โฑ 1127 โ โ with create_prediction_pipeline( โ
โ 1128 โ โ โ bioimageio_model=model, devices=devices, weight_format=weight_format โ
โ 1129 โ โ ) as prediction_pipeline: โ
โ 1130 โ โ โ for n, batch_size, inputs, exptected_output_shape in generate_test_cases(): โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 468 โ โ โ f"deprecated create_prediction_pipeline kwargs: {set(deprecated_kwargs)}" โ
โ 469 โ โ ) โ
โ 470 โ โ
โ โฑ 471 โ model_adapter = model_adapter or create_model_adapter( โ
โ 472 โ โ model_description=bioimageio_model, โ
โ 473 โ โ devices=devices, โ
โ 474 โ โ weight_format_priority_order=weights_format and (weights_format,), โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 183 โ โ assert errors โ
โ 184 โ โ if len(weight_format_priority_order) == 1: โ
โ 185 โ โ โ assert len(errors) == 1 โ
โ โฑ 186 โ โ โ raise errors[0] โ
โ 187 โ โ โ
โ 188 โ โ else: โ
โ 189 โ โ โ msg = ( โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 113 โ โ โ โ try: โ
โ 114 โ โ โ โ โ from .pytorch_backend import PytorchModelAdapter โ
โ 115 โ โ โ โ โ โ
โ โฑ 116 โ โ โ โ โ return PytorchModelAdapter( โ
โ 117 โ โ โ โ โ โ model_description=model_description, devices=devices โ
โ 118 โ โ โ โ โ ) โ
โ 119 โ โ โ โ except Exception as e: โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 62 โ โ โ raise ValueError("No `pytorch_state_dict` weights found") โ
โ 63 โ โ โ
โ 64 โ โ devices = get_devices(devices) โ
โ โฑ 65 โ โ self._model = load_torch_model(weights, load_state=True, devices=devices) โ
โ 66 โ โ if mode == "eval": โ
โ 67 โ โ โ self._model = self._model.eval() โ
โ 68 โ โ elif mode == "train": โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 127 โ load_state: bool = True, โ
โ 128 โ devices: Optional[Sequence[Union[str, torch.device]]] = None, โ
โ 129 ) -> nn.Module: โ
โ โฑ 130 โ custom_callable = import_callable( โ
โ 131 โ โ weight_spec.architecture, โ
โ 132 โ โ sha256=( โ
โ 133 โ โ โ weight_spec.architecture_sha256 โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 75 โ elif isinstance(node, CallableFromFile): โ
โ 76 โ โ c = _import_from_file_impl(node.source_file, str(node.callable_name), **kwargs) โ
โ 77 โ elif isinstance(node, (ArchitectureFromFileDescr, v0_5.CustomProcessingDescr)): โ
โ โฑ 78 โ โ c = _import_from_file_impl(node.source, str(node.callable), sha256=node.sha256) โ
โ 79 โ else: โ
โ 80 โ โ assert_never(node) โ
โ 81 โ
โ โ
โ /usr/share/miniconda/envs/f923abbcd927e1b70f314f29827668de2b128bac170663b23d97aaff14a5c225/lib/p โ
โ โ
โ 150 โ โ โ if module_name in sys.modules: โ
โ 151 โ โ โ โ del sys.modules[module_name] โ
โ 152 โ โ โ โ
โ โฑ 153 โ โ โ raise ImportError(f"Failed to import {source}") from e โ
โ 154 โ โ
โ 155 โ try: โ
โ 156 โ โ callable_attr = getattr(module, callable_name) โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
ImportError: Failed to import bmz_model.py