code: def test_ALEBOStrategy(self) -> None:
      D = 20
      d = 3
      init_size = 5
      s = ALEBOStrategy(D=D, d=d, init_size=init_size)
      self.assertEqual(s._steps[0].num_trials, init_size)
      # pyre-fixme[16]: Optional type has no attribute `__getitem__`.
      random_B = s._steps[0].model_kwargs["B"]
      gp_B = s._steps[1].model_kwargs["B"]
      # Check that random and GP have the same projection
      self.assertTrue(np.allclose(random_B, gp_B.numpy()))
      # And that the projection has correct properties
      self.assertEqual(random_B.shape, (d, D))
      self.assertTrue(
          torch.allclose(
              torch.sqrt((gp_B**2).sum(dim=0)),
              torch.ones(D, dtype=torch.double),
          )
      )
  
      s2 = s.clone_reset()
      # Check that attributes copied, but not B
      self.assertEqual(s2.d, d)
      self.assertEqual(s2.D, D)
      self.assertEqual(s2._steps[0].num_trials, init_size)
      random_B2 = s2._steps[0].model_kwargs["B"]
      self.assertEqual(random_B2.shape, (d, D))
      self.assertFalse(np.allclose(random_B, random_B2))
  
file_path: Ax/ax/modelbridge/tests/test_alebo_strategy.py
imports: from unittest import mock
  import numpy
  import pandas
  import torch
  from ax.core.data import Data
  from ax.modelbridge.strategies.alebo import ALEBOStrategy, get_ALEBO, get_ALEBOInitializer
  from ax.utils.common.testutils import TestCase
  from ax.utils.testing.core_stubs import get_branin_experiment
label_desc: Use image node_id 2 for calling the ALEBOStrategyTest obj's underlying member method code with example usage: obj.test_ALEBOStrategy() without return types