# 3. Create the optimizer
params = [
{
"params": [
val
for key, val in parametrization.parameters.items()
if "logZ" not in key
],
"lr": args.lr,
}
]
if "logZ.logZ" in parametrization.parameters:
params.append(
{
"params": [parametrization.parameters["logZ.logZ"]],
"lr": args.lr_Z,
}
)
should ideally be a one liner, using a utility function.
In
train_hypergrid.py
, for exampleshould ideally be a one liner, using a utility function.