Skip to content

Commit

Permalink
[DLMED] fix mode issue (#3715)
Browse files Browse the repository at this point in the history
Signed-off-by: Nic Ma <nma@nvidia.com>
  • Loading branch information
Nic-Ma authored and wyli committed Feb 9, 2022
1 parent abe24cf commit 647a100
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion monai/engines/evaluator.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def __init__(
event_to_attr=event_to_attr,
decollate=decollate,
)
self.mode = look_up_option(mode, ForwardMode)
mode = look_up_option(mode, ForwardMode)
if mode == ForwardMode.EVAL:
self.mode = eval_mode
elif mode == ForwardMode.TRAIN:
Expand Down
1 change: 1 addition & 0 deletions tests/test_prepare_batch_default.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ def test_content(self):
non_blocking=False,
prepare_batch=PrepareBatchDefault(),
decollate=False,
mode="eval",
)
evaluator.run()
output = evaluator.state.output
Expand Down

0 comments on commit 647a100

Please sign in to comment.