code: def test_lambda_lr(self):
      if _pytorch_version_gt("1.0.0"):  # CyclicLR is implemented
          with patch("torch.optim.lr_scheduler.CyclicLR") as lr_mock:
              state = {
                  torchbearer.OPTIMIZER: "optimizer",
                  torchbearer.EPOCH: 0,
                  torchbearer.MODEL: Mock(),
              }
  
              scheduler = CyclicLR(
                  base_lr=0.01,
                  max_lr=0.1,
                  monitor="test",
                  step_size_up=200,
                  step_size_down=None,
                  mode="triangular",
                  gamma=2.0,
                  scale_fn=None,
                  scale_mode="cycle",
                  cycle_momentum=False,
                  base_momentum=0.7,
                  max_momentum=0.9,
                  step_on_batch=True,
              )
              scheduler.on_start(state)
  
              lr_mock.assert_called_once_with(
                  "optimizer",
                  base_lr=0.01,
                  max_lr=0.1,
                  step_size_up=200,
                  step_size_down=None,
                  mode="triangular",
                  gamma=2.0,
                  scale_fn=None,
                  scale_mode="cycle",
                  cycle_momentum=False,
                  base_momentum=0.7,
                  max_momentum=0.9,
                  last_epoch=-1,
              )
              self.assertTrue(scheduler._step_on_batch)
              self.assertTrue(scheduler._monitor == "test")
      else:
          self.assertRaises(
              NotImplementedError,
              lambda: CyclicLR(
                  base_lr=0.01,
                  max_lr=0.1,
                  monitor="test",
                  step_size_up=200,
                  step_size_down=None,
                  mode="triangular",
                  gamma=2.0,
                  scale_fn=None,
                  scale_mode="cycle",
                  cycle_momentum=False,
                  base_momentum=0.7,
                  max_momentum=0.9,
                  step_on_batch=True,
              ),
          )
  
imports: from unittest import TestCase
  from mock import patch, Mock
  import warnings
  import torchbearer
  from torchbearer.bases import _pytorch_version_gt
  from torchbearer.callbacks import TorchScheduler, LambdaLR, StepLR, MultiStepLR, ExponentialLR, CosineAnnealingLR, ReduceLROnPlateau, CyclicLR
label_desc: Use image node_id 1 for calling the TestCyclicLR obj's underlying member method code with example usage: obj.test_lambda_lr() without return types