When using argparse.parse_known_args() and merging CLI args with YAML config, boolean arguments like --water_entropy are ignored if their value matches the default (True). This causes YAML overrides (e.g. water_entropy: False) to be skipped unintentionally.
Cause:
- The logic assumes that if
args.water_entropy == default, then the CLI didn’t override it, but this fails when the CLI did pass --water_entropy True.
When using
argparse.parse_known_args()and mergingCLIargs withYAMLconfig, boolean arguments like--water_entropyare ignored if their value matches the default (True). This causesYAMLoverrides (e.g.water_entropy:False) to be skipped unintentionally.Cause:
args.water_entropy == default, then theCLIdidn’t override it, but this fails when theCLIdid pass--water_entropy True.