Skip to content

Commit a8c7b4c

Browse files
author
Rob Cornish
committed
Renamed --print-density argument to --print-model
1 parent e57d987 commit a8c7b4c

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

lgf/experiment.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def train(config):
3131
trainer.train()
3232

3333

34-
def print_density(config):
34+
def print_model(config):
3535
_, density, _, _ = setup_experiment({**config, "enable_logging": False})
3636
print(density)
3737
print(f"Number of parameters: {num_params(density):,}")

main.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
], required=True)
1919
parser.add_argument("--baseline", action="store_true", help="Run baseline flow instead of LGF")
2020
parser.add_argument("--seed", type=int, help="Random seed to use. Defaults to using current time.")
21-
parser.add_argument("--print-density", action="store_true", help="Print the Pytorch Density and exit")
21+
parser.add_argument("--print-model", action="store_true", help="Print the model and exit")
2222
parser.add_argument("--print-schema", action="store_true", help="Print the model schema and exit")
2323
parser.add_argument("--print-config", action="store_true", help="Print the full config and exit")
2424
parser.add_argument("--nochkpt", action="store_true", help="Disable checkpointing")
@@ -77,9 +77,9 @@ def parse_config_arg(key_value):
7777
print(json.dumps(config, indent=4))
7878
should_train = False
7979

80-
if args.print_density:
81-
from lgf.experiment import print_density
82-
print_density({**config, "write_to_disk": False})
80+
if args.print_model:
81+
from lgf.experiment import print_model
82+
print_model({**config, "write_to_disk": False})
8383
should_train = False
8484

8585
if args.print_schema:

0 commit comments

Comments
 (0)