code: def test_apply_constraints_wrong_eta_dim(self):
      tkwargs = {"device": self.device}
      for dtype in (torch.float, torch.double):
          tkwargs["dtype"] = dtype
          samples = torch.rand(3, 2, **tkwargs)
          obj = samples.clone()
          with self.assertRaisesRegex(
              ValueError, "Number of provided constraints"
          ):
              obj = apply_constraints(
                  obj=obj,
                  constraints=[zeros_f, zeros_f],
                  samples=samples,
                  infeasible_cost=0.0,
                  eta=torch.tensor([0.1]).to(**tkwargs),
              )
          with self.assertRaisesRegex(
              ValueError, "Number of provided constraints"
          ):
              obj = apply_constraints(
                  obj=obj,
                  constraints=[zeros_f, zeros_f],
                  samples=samples,
                  infeasible_cost=0.0,
                  eta=torch.tensor([0.1, 0.1, 0.3]).to(**tkwargs),
              )
  
imports: import torch
  from botorch.utils import apply_constraints, get_objective_weights_transform
  from botorch.utils.objective import compute_feasibility_indicator, compute_smoothed_feasibility_indicator, soft_eval_constraint
  from botorch.utils.testing import BotorchTestCase
  from torch import Tensor
label_desc: Use image node_id 3 for calling the TestApplyConstraints obj's underlying member method code with example usage: obj.test_apply_constraints_wrong_eta_dim() without return types