code: def test_end_to_end(self):
      import numpy as np
      from torchbearer.callbacks.init import ZeroBias
  
      np.random.seed(7)
      torch.manual_seed(7)
  
      class Flatten(torch.nn.Module):
          def forward(self, x):
              return x.view(x.shape[0], -1)
  
      model = torch.nn.Sequential(
          torch.nn.Conv2d(1, 1, 1),
          Flatten(),
          torch.nn.Linear(4, 2),
      )
  
      state = {torchbearer.MODEL: model}
      data = torch.rand(2, 1, 2, 2)
      ZeroBias(model.modules()).on_init(
          state
      )  # LSUV expects biases to be zero
      init.LsuvInit(data).on_init(state)
  
      correct_conv_weight = torch.FloatTensor([[[[3.2236]]]])
      correct_linear_weight = torch.FloatTensor(
          [
              [-0.3414, -0.5503, -0.4402, -0.4367],
              [0.3425, -0.0697, -0.6646, 0.4900],
          ]
      )
  
      conv_weight = list(model.modules())[1].weight
      linear_weight = list(model.modules())[3].weight
      diff_conv = (conv_weight - correct_conv_weight) < 0.0001
      diff_linear = (linear_weight - correct_linear_weight) < 0.0001
      self.assertTrue(diff_conv.all().item())
  
file_path: torchbearer/tests/callbacks/test_init.py
imports: import torch
  from unittest import TestCase
  from mock import MagicMock, patch
  import torchbearer
  import torchbearer.callbacks.init
label_desc: Use image node_id 1 for calling the TestLsuv obj's underlying member method code with example usage: obj.test_end_to_end() and returns: x