-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix init call of NoDeepSupervision trainer
- Loading branch information
Showing
1 changed file
with
11 additions
and
2 deletions.
There are no files selected for viewing
13 changes: 11 additions & 2 deletions
13
...v2/training/nnUNetTrainer/variants/network_architecture/nnUNetTrainerNoDeepSupervision.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,16 @@ | ||
from nnunetv2.training.nnUNetTrainer.nnUNetTrainer import nnUNetTrainer | ||
import torch | ||
|
||
|
||
class nnUNetTrainerNoDeepSupervision(nnUNetTrainer): | ||
def __init__(self, *args, **kwargs): | ||
super().__init__(*args, **kwargs) | ||
def __init__( | ||
self, | ||
plans: dict, | ||
configuration: str, | ||
fold: int, | ||
dataset_json: dict, | ||
unpack_dataset: bool = True, | ||
device: torch.device = torch.device("cuda"), | ||
): | ||
super().__init__(plans, configuration, fold, dataset_json, unpack_dataset, device) | ||
self.enable_deep_supervision = False |