class_docstr: Negative binomial loss, e.g. for count data.
  
  Requirements for original target normalizer:
      * not centered normalization (only rescaled)
class_docstr_tok: ["Negative","binomial","loss",",","e.g",".","for","count","data",".","Requirements","for","original","target","normalizer",":","*","not","centered","normalization","(","only","rescaled",")"]
docstr: Convert network prediction into a point prediction. In the case of this distribution prediction we
  need to derive the mean (as a point prediction) from the distribution parameters
  
  Args:
      y_pred: prediction output of network
      in this case the two parameters for the negative binomial
  
  Returns:
      torch.Tensor: mean prediction
docstr_tok: ["Convert","network","prediction","into","a","point","prediction",".","In","the","case","of","this","distribution","prediction","we","need","to","derive","the","mean","(","as","a","point","prediction",")","from","the","distribution","parameters","Args",":","y_pred",":","prediction","output","of","network","in","this","case","the","two","parameters","for","the","negative","binomial","Returns",":","torch.Tensor",":","mean","prediction"]
code: def to_prediction(self, y_pred: torch.Tensor) -> torch.Tensor:
      """
      Convert network prediction into a point prediction. In the case of this distribution prediction we
      need to derive the mean (as a point prediction) from the distribution parameters
  
      Args:
          y_pred: prediction output of network
          in this case the two parameters for the negative binomial
  
      Returns:
          torch.Tensor: mean prediction
      """
      return y_pred[..., 0]
  
imports: from typing import Any, Callable, Dict, List, Optional, Tuple, Union
  import numpy
  from sklearn.base import BaseEstimator
  import torch
  from torch import distributions, nn
  import torch.nn.functional
  from pytorch_forecasting.data.encoders import TorchNormalizer, softplus_inv
  from pytorch_forecasting.metrics.base_metrics import DistributionLoss, MultivariateDistributionLoss
label_desc: Use image node_id 3 for calling the NegativeBinomialDistributionLoss obj's underlying member method code with example usage: obj.to_prediction(y_pred) and returns: y_pred