Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the checkpoint loader logic for inference #521

Merged
merged 3 commits into from
Oct 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions models/spleen_deepedit_annotation/configs/inference.json
Original file line number Diff line number Diff line change
Expand Up @@ -183,13 +183,6 @@
]
},
"handlers": [
{
"_target_": "CheckpointLoader",
"load_path": "$@bundle_root + '/models/model.pt'",
"load_dict": {
"model": "@network"
}
},
{
"_target_": "StatsHandler",
"iteration_log": false
Expand All @@ -205,8 +198,16 @@
"val_handlers": "@handlers",
"amp": true
},
"checkpointloader": {
"_target_": "CheckpointLoader",
"load_path": "$@bundle_root + '/models/model.pt'",
"load_dict": {
"model": "@network"
}
},
"initialize": [
"$monai.utils.set_determinism(seed=123)"
"$monai.utils.set_determinism(seed=123)",
"$@checkpointloader(@evaluator)"
yiheng-wang-nv marked this conversation as resolved.
Show resolved Hide resolved
],
"run": [
"[email protected]()"
Expand Down
6 changes: 4 additions & 2 deletions models/spleen_deepedit_annotation/configs/inference_trt.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
"$import ignite",
"$import torch_tensorrt"
],
"handlers#0#_disabled_": true,
yiheng-wang-nv marked this conversation as resolved.
Show resolved Hide resolved
"network_def": "$torch.jit.load(@bundle_root + '/models/model_trt.ts')",
"evaluator#amp": false
"evaluator#amp": false,
"initialize": [
"$monai.utils.set_determinism(seed=123)"
]
}
3 changes: 2 additions & 1 deletion models/spleen_deepedit_annotation/configs/metadata.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"schema": "https://github.com/Project-MONAI/MONAI-extra-test-data/releases/download/0.8.1/meta_schema_20220324.json",
"version": "0.5.1",
"version": "0.5.2",
"changelog": {
"0.5.2": "update the checkpoint loader logic for inference",
"0.5.1": "add option to validate at training start, and I/O param entries",
"0.5.0": "enable finetune and early stop",
"0.4.9": "fix orientation issue on clicks",
Expand Down
Loading