code: def _multiscale_ssim_compute(
      mcs_per_image: Tensor,
      reduction: Literal[
          "elementwise_mean", "sum", "none", None
      ] = "elementwise_mean",
  ) -> Tensor:
      """Apply the specified reduction to pre-computed multi-scale structural similarity.
  
      Args:
          mcs_per_image: per image similarities for a batch of images.
          reduction: a method to reduce metric score over individual batch scores
  
                  - ``'elementwise_mean'``: takes the mean
                  - ``'sum'``: takes the sum
                  - ``'none'`` or ``None``: no reduction will be applied
  
      Returns:
          The reduced multi-scale structural similarity
  
      """
      return reduce(mcs_per_image, reduction)
  
file_path: torchmetrics/src/torchmetrics/functional/image/ssim.py
imports: from typing import List, Optional, Sequence, Tuple, Union
  import torch
  from torch import Tensor
  from torch.nn import functional
  from typing_extensions import Literal
  from torchmetrics.functional.image.helper import _gaussian_kernel_2d, _gaussian_kernel_3d, _reflection_pad_3d
  from torchmetrics.utilities.checks import _check_same_shape
  from torchmetrics.utilities.distributed import reduce
label_desc: Use image node_id 7 for calling a global function with example usage: _multiscale_ssim_compute(mcs_per_image, reduction) and returns: reduce