Skip to content

Commit

Permalink
Modify test file expected_optimizer
Browse files Browse the repository at this point in the history
  • Loading branch information
WisamAbbasi committed Oct 4, 2023
1 parent 997c07c commit 5f2c3a5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test_flask-parental-control.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ def test_get_optimizer():

if cfg.train.optimizer_name == "adam":
expected_optimizer = Adam(lr=cfg.train.lr)
expected_optimizer2 = load_optimizer(cfg)
else:
raise ValueError("optimizer name should be 'adam'")

Expand Down Expand Up @@ -183,7 +184,7 @@ def test_load_optimizer_sgd_none():
]
)

optimizer = load_optimizer(cfg)
expected_optimizer = load_optimizer(cfg)

optimizer_name = "Other"
cfg = OmegaConf.from_dotlist(
Expand All @@ -196,6 +197,7 @@ def test_load_optimizer_sgd_none():
f"train.batch_size={batch_size}",
]
)
expected_optimizer = load_optimizer(cfg)


def test_get_optimizer():
Expand Down

0 comments on commit 5f2c3a5

Please sign in to comment.