class_docstr: This class implements the RecMetricComputation for MSE, i.e. Mean Squared Error.
  
  The constructor arguments are defined in RecMetricComputation.
  See the docstring of RecMetricComputation for more detail.
class_docstr_tok: ["This","class","implements","the","RecMetricComputation","for","MSE",",","i.e",".","Mean","Squared","Error",".","The","constructor","arguments","are","defined","in","RecMetricComputation",".","See","the","docstring","of","RecMetricComputation","for","more","detail","."]
code: def _compute(self) -> List[MetricComputationReport]:
      return [
          MetricComputationReport(
              name=MetricName.MSE,
              metric_prefix=MetricPrefix.LIFETIME,
              value=compute_mse(
                  cast(torch.Tensor, self.error_sum),
                  cast(torch.Tensor, self.weighted_num_samples),
              ),
          ),
          MetricComputationReport(
              name=MetricName.RMSE,
              metric_prefix=MetricPrefix.LIFETIME,
              value=compute_rmse(
                  cast(torch.Tensor, self.error_sum),
                  cast(torch.Tensor, self.weighted_num_samples),
              ),
          ),
          MetricComputationReport(
              name=MetricName.MSE,
              metric_prefix=MetricPrefix.WINDOW,
              value=compute_mse(
                  self.get_window_state(ERROR_SUM),
                  self.get_window_state(WEIGHTED_NUM_SAMPES),
              ),
          ),
          MetricComputationReport(
              name=MetricName.RMSE,
              metric_prefix=MetricPrefix.WINDOW,
              value=compute_rmse(
                  self.get_window_state(ERROR_SUM),
                  self.get_window_state(WEIGHTED_NUM_SAMPES),
              ),
          ),
      ]
  
file_path: torchrec/torchrec/metrics/mse.py
imports: from typing import Any, cast, Dict, List, Optional, Type
  import torch
  from torchrec.metrics.metrics_namespace import MetricName, MetricNamespace, MetricPrefix
  from torchrec.metrics.rec_metric import MetricComputationReport, RecMetric, RecMetricComputation, RecMetricException
label_desc: Use image node_id 3 for calling the MSEMetricComputation obj's underlying member method code with example usage: obj._compute() and returns: list