class_docstr: Statistic tracking the count and mean of a single :class:`torch.Tensor`.
docstr: :returns: A dictionary with keys ``count: int`` and (if any samples
      have been collected) ``mean: torch.Tensor``.
  :rtype: dict
docstr_tok: [":","returns",":","A","dictionary","with","keys","``","count",":","int","``","and","(","if","any","samples","have","been","collected",")","``","mean",":","torch.Tensor","``",".",":","rtype",":","dict"]
code: def get(self) -> Dict[str, Union[int, torch.Tensor]]:
      """
      :returns: A dictionary with keys ``count: int`` and (if any samples
          have been collected) ``mean: torch.Tensor``.
      :rtype: dict
      """
      if self.count == 0:
          return {"count": 0}
      return {"count": self.count, "mean": self.mean}
  
imports: import copy
  from abc import ABC, abstractmethod
  from collections import defaultdict
  from typing import Any, Callable, Dict, Hashable, Union
  import torch
  from pyro.ops.welford import WelfordCovariance
label_desc: Use image node_id 4 for calling the CountMeanStats obj's underlying member method code with example usage: obj.get() and returns: dict, dict