code: def test_standardize_raises_when_mean_not_set(self) -> None:
      posterior = _get_test_posterior(
          shape=torch.Size([1, 1]),
          device=self.device,
          dtype=torch.float64,
      )
      for transform in [
          Standardize(m=1),
          ChainedOutcomeTransform(
              chained=ChainedOutcomeTransform(stand=Standardize(m=1))
          ),
      ]:
          with self.assertRaises(
              RuntimeError,
              msg="`Standardize` transforms must be called on outcome data "
              "(e.g. `transform(Y)`) before calling `untransform_posterior`, since "
              "means and standard deviations need to be computed.",
          ):
              transform.untransform_posterior(posterior)
  
          new_tf = transform.subset_output([0])
          assert isinstance(new_tf, type(transform))
  
          y = torch.arange(3, device=self.device, dtype=torch.float64)
          with self.assertRaises(
              RuntimeError,
              msg="`Standardize` transforms must be called on outcome data "
              "(e.g. `transform(Y)`) before calling `untransform`, since "
              "means and standard deviations need to be computed.",
          ):
              transform.untransform(y)
  
imports: import itertools
  from copy import deepcopy
  import torch
  from botorch.models.transforms.outcome import Bilog, ChainedOutcomeTransform, Log, OutcomeTransform, Power, Standardize
  from botorch.models.transforms.utils import norm_to_lognorm_mean, norm_to_lognorm_variance
  from botorch.posteriors import GPyTorchPosterior, TransformedPosterior
  from botorch.utils.testing import BotorchTestCase
  from gpytorch.distributions import MultitaskMultivariateNormal, MultivariateNormal
  from linear_operator.operators import BlockDiagLinearOperator, DenseLinearOperator, DiagLinearOperator
label_desc: Use image node_id 2 for calling the TestOutcomeTransforms obj's underlying member method code with example usage: obj.test_standardize_raises_when_mean_not_set() without return types