class_docstr: This class takes `Pytorch's test_optim function:
  https://github.com/pytorch/pytorch/blob/v1.9.0/test/test_optim.py for reference.
class_docstr_tok: ["This","class","takes","`","Pytorch","'s","test_optim","function",":","https",":","\/\/github.com\/pytorch\/pytorch\/blob\/v1.9.0\/test\/test_optim.py","for","reference","."]
code: def test_ill_arg(self):
      param = {
          "params": [Variable(torch.randn(10), requires_grad=True)]
      }
      with self.assertRaisesRegex(
          ValueError, "Invalid learning rate: -1"
      ):
          Novograd(param, lr=-1)
      with self.assertRaisesRegex(
          ValueError, "Invalid epsilon value: -1"
      ):
          Novograd(param, eps=-1)
      with self.assertRaisesRegex(
          ValueError, "Invalid beta parameter at index 0: 1.0"
      ):
          Novograd(param, betas=(1.0, 0.98))
      with self.assertRaisesRegex(
          ValueError, "Invalid beta parameter at index 1: -1"
      ):
          Novograd(param, betas=(0.9, -1))
      with self.assertRaisesRegex(
          ValueError, "Invalid weight_decay value: -1"
      ):
          Novograd(param, weight_decay=-1)
  
file_path: MONAI/tests/test_optim_novograd.py
imports: from __future__ import annotations
  import unittest
  import torch
  from parameterized import parameterized
  from torch.autograd import Variable
  from monai.optimizers import Novograd
label_desc: Use image node_id 2 for calling the TestNovograd obj's underlying member method code with example usage: obj.test_ill_arg() without return types