-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #781 from Ainesh06102004/add_optimizers_monai
Add optimizers monai
- Loading branch information
Showing
3 changed files
with
17 additions
and
0 deletions.
There are no files selected for viewing
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
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
from monai.optimizers import ( | ||
Novograd | ||
) | ||
|
||
def novograd_wrapper(parameters): | ||
return Novograd( | ||
parameters["model_parameters"], | ||
lr=parameters.get("learning_rate"), | ||
betas=parameters["optimizer"].get("betas", (0.9, 0.999)), | ||
eps=parameters["optimizer"].get("eps", 1e-8), | ||
weight_decay=parameters["optimizer"].get("weight_decay", 3e-05), | ||
amsgrad=parameters["optimizer"].get("amsgrad", False), | ||
) |
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 |
---|---|---|
|
@@ -117,6 +117,7 @@ def run(self): | |
"twine", | ||
"zarr", | ||
"keyring", | ||
"monai==1.3.0", | ||
] | ||
|
||
if __name__ == "__main__": | ||
|