def METHOD_NAME(self):
    class Toy(nn.Module):
        def __init__(self):
            super().__init__()
            self.conv1 = nn.Conv2d(3, 3, 3)
            self.bn1 = nn.BatchNorm2d(3)
            self.conv2 = nn.Conv2d(3, 3, 3)
            self.bn2 = nn.BatchNorm2d(3)
        def forward(self, x):
            x = self.conv1(x)
            x = self.bn1(x)
            x = self.conv2(x)
            x = self.bn2(x)
            return x
    # assert the bn module was replaced with Identity
    model = Toy()
    model.eval()
    fuse_conv_bn(model, replace_bn_with_identity=True)
    self.assertIsNotNone(model.bn1)
    self.assertIsInstance(model.conv1, nn.Conv2d)
    self.assertIsInstance(model.bn1, nn.Identity)
    # assert the bn module was removed
    model = Toy()
    model.eval()
    fuse_conv_bn(model, replace_bn_with_identity=False)
    self.assertFalse(hasattr(model, "bn1"))
    self.assertIsInstance(model.conv1, nn.Conv2d)
    # assert all bn module were removed
    model = Toy()
    model.eval()
    fuse_conv_bn(model, replace_bn_with_identity=False)
    self.assertFalse(hasattr(model, "bn1"))
    self.assertIsInstance(model.conv1, nn.Conv2d)
    self.assertFalse(hasattr(model, "bn2"))
    self.assertIsInstance(model.conv2, nn.Conv2d)
    # assert correct number of parameters removed
    model = Toy()
    model.eval()
    before = count_parameters(model)
    fuse_conv_bn(model, replace_bn_with_identity=False)
    after = count_parameters(model)
    self.assertEqual(before - after, 12)  # each bn of 3 channels has 6 parameters (12 together)