class_docstr: Test on the problem (with the simplying assumption on general position)
  from Table 1 in:
  https://www.sciencedirect.com/science/article/pii/S0305054816301538
class_docstr_tok: ["Test","on","the","problem","(","with","the","simplying","assumption","on","general","position",")","from","Table","1","in",":","https",":","\/\/www.sciencedirect.com\/science\/article\/pii\/S0305054816301538"]
code: def test_local_upper_bounds_utils(self):
      for dtype in (torch.float, torch.double):
          U = self.U.to(dtype=dtype)
          Z = self.Z.to(dtype=dtype)
          pareto_Y = self.pareto_Y.to(dtype=dtype)
          expected_U = self.expected_U_after_update.to(dtype=dtype)
          expected_Z = self.expected_Z_after_update.to(dtype=dtype)
  
          # test z dominates U
          U_new, Z_new = compute_local_upper_bounds(
              U=U, Z=Z, z=-self.ref_point + 1
          )
          self.assertTrue(torch.equal(U_new, U))
          self.assertTrue(torch.equal(Z_new, Z))
  
          # test compute_local_upper_bounds
          for i in range(pareto_Y.shape[0]):
              U, Z = compute_local_upper_bounds(
                  U=U, Z=Z, z=-pareto_Y[i]
              )
          self.assertTrue(torch.equal(U, expected_U))
          self.assertTrue(torch.equal(Z, expected_Z))
  
          # test update_local_upper_bounds_incremental
          # test that calling update_local_upper_bounds_incremental once with
          # the entire Pareto set yields the same result
          U2, Z2 = update_local_upper_bounds_incremental(
              new_pareto_Y=-pareto_Y,
              U=self.U.to(dtype=dtype),
              Z=self.Z.to(dtype=dtype),
          )
          self.assertTrue(torch.equal(U2, expected_U))
          self.assertTrue(torch.equal(Z2, expected_Z))
  
file_path: botorch/test/utils/multi_objective/box_decompositions/test_utils.py
imports: from __future__ import annotations
  import torch
  from botorch.exceptions.errors import BotorchTensorDimensionError, UnsupportedError
  from botorch.utils.multi_objective.box_decompositions.utils import _expand_ref_point, _pad_batch_pareto_frontier, compute_dominated_hypercell_bounds_2d, compute_local_upper_bounds, compute_non_dominated_hypercell_bounds_2d, get_partition_bounds, update_local_upper_bounds_incremental
  from botorch.utils.testing import BotorchTestCase
label_desc: Use image node_id 2 for calling the TestFastPartitioningUtils obj's underlying member method code with example usage: obj.test_local_upper_bounds_utils() without return types