code: def test_init(self):
      # Init w/ defaults.
      mars = MARS(
          alpha=0.5,
          n_w=3,
          chebyshev_weights=[0.5, 0.5],
      )
      self.assertEqual(mars.alpha, 0.5)
      self.assertEqual(mars.n_w, 3)
      self.assertTrue(
          torch.equal(mars.chebyshev_weights, torch.tensor([0.5, 0.5]))
      )
      self.assertIsNone(mars.baseline_Y)
      self.assertIsNone(mars.ref_point)
      self.assertIsInstance(
          mars.preprocessing_function, IdentityMCMultiOutputObjective
      )
      self.assertIsInstance(mars.mvar, MVaR)
      self.assertEqual(mars.mvar.alpha, 0.5)
      self.assertEqual(mars.mvar.n_w, 3)
      # Errors with Chebyshev weights.
      with self.assertRaisesRegex(UnsupportedError, "Negative"):
          MARS(
              alpha=0.5,
              n_w=3,
              chebyshev_weights=[-0.5, 0.5],
          )
      with self.assertRaisesRegex(UnsupportedError, "Batched"):
          MARS(
              alpha=0.5,
              n_w=3,
              chebyshev_weights=[[0.5], [0.5]],
          )
      # With optional arguments.
      baseline_Y = torch.rand(3, 2)
      ref_point = [3.0, 5.0]
  
      def dummy_func(Y):
          return Y
  
      mars = MARS(
          alpha=0.5,
          n_w=3,
          chebyshev_weights=[0.5, 0.5],
          baseline_Y=baseline_Y,
          ref_point=ref_point,
          preprocessing_function=dummy_func,
      )
      self.assertTrue(torch.equal(mars.baseline_Y, baseline_Y))
      self.assertTrue(
          torch.equal(mars.ref_point, torch.tensor(ref_point))
      )
      self.assertIs(mars.preprocessing_function, dummy_func)
  
imports: import warnings
  from typing import Optional
  import torch
  from botorch import settings
  from botorch.acquisition.multi_objective.multi_output_risk_measures import IndependentCVaR, IndependentVaR, MARS, MultiOutputExpectation, MultiOutputRiskMeasureMCObjective, MultiOutputWorstCase, MVaR
  from botorch.acquisition.multi_objective.objective import IdentityMCMultiOutputObjective, WeightedMCMultiOutputObjective
  from botorch.exceptions.errors import UnsupportedError
  from botorch.exceptions.warnings import BotorchWarning
  from botorch.models.deterministic import GenericDeterministicModel
  from botorch.models.transforms.input import InputPerturbation
  from botorch.utils.multi_objective.pareto import is_non_dominated
  from botorch.utils.testing import BotorchTestCase
  from torch import Tensor
label_desc: Use image node_id 1 for calling the TestMARS obj's underlying member method code with example usage: obj.test_init() and returns: Y