Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

Specify formatter_class=argparse.ArgumentDefaultsHelpFormatter in generic_parsing.py to show default values for arguments in help message #689

Merged
merged 8 commits into from
Mar 15, 2022
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ created.

### Added

- ([#689](https://github.com/microsoft/InnerEye-DeepLearning/pull/689)) Show default argument values in help message.
- ([#678](https://github.com/microsoft/InnerEye-DeepLearning/pull/678)) Add function to get log level name and use it for logging.
- ([#666](https://github.com/microsoft/InnerEye-DeepLearning/pull/666)) Replace RadIO with TorchIO for patch-based inference.
- ([#643](https://github.com/microsoft/InnerEye-DeepLearning/pull/643)) Test for recovery of SSL job. Tracks learning rate and train
Expand Down
2 changes: 1 addition & 1 deletion InnerEye/Common/generic_parsing.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ def create_argparser(cls: Type[GenericConfig]) -> argparse.ArgumentParser:
Creates an ArgumentParser with all fields of the given argparser that are overridable.
:return: ArgumentParser
"""
parser = argparse.ArgumentParser()
parser = argparse.ArgumentParser(formatter_class=argparse.ArgumentDefaultsHelpFormatter)
cls.add_args(parser)

return parser
Expand Down