class_docstr: Distribution object used to store distribution objects in Aim repository.
  
  Args:
      samples (:obj:): Array-like object of data sampled from a distribution.
      bin_count (:obj:`int`, optional): Optional distribution bin count for
          binning `samples`. 64 by default, max 512.
      hist (:obj:, optional): Array-like object representing bin frequency counts.
          Max 512 bins allowed. `samples` must not be specified.
      bin_range (:obj:`tuple`, optional): Tuple of (start, end) bin range.
class_docstr_tok: ["Distribution","object","used","to","store","distribution","objects","in","Aim","repository",".","Args",":","samples","(",":","obj",":",")",":","Array-like","object","of","data","sampled","from","a","distribution",".","bin_count","(",":","obj",":","`","int","`",",","optional",")",":","Optional","distribution","bin","count","for","binning","`","samples","`",".","64","by","default",",","max","512.","hist","(",":","obj",":",",","optional",")",":","Array-like","object","representing","bin","frequency","counts",".","Max","512","bins","allowed",".","`","samples","`","must","not","be","specified",".","bin_range","(",":","obj",":","`","tuple","`",",","optional",")",":","Tuple","of","(","start",",","end",")","bin","range","."]
code: def __init__(
      self, samples=None, bin_count=64, *, hist=None, bin_range=None
  ):
      super().__init__()
  
      if samples is not None:
          if hist is not None:
              raise ValueError(
                  "hist should not be specified if samples is specified."
              )
          hist, bin_edges = np.histogram(samples, bins=bin_count)
      elif hist is not None:
          if bin_range is None:
              raise ValueError(
                  "Please specify bin_range of (start, end) bins."
              )
          bin_count = len(hist)
          bin_edges = np.linspace(
              bin_range[0], bin_range[-1], num=bin_count + 1
          )
      else:
          raise ValueError("Please specify either samples or hist.")
  
      hist = np.asanyarray(hist)
      bin_edges = np.asanyarray(bin_edges)
      self._from_np_histogram(hist, bin_edges)
  
file_path: aim/aim/sdk/objects/distribution.py
imports: import numpy
  from aim.storage.object import CustomObject
  from aim.storage.types import BLOB
label_desc: Use image node_id 1 to create a new Distribution object from inherited base classes: CustomObject with example: obj = Distribution(samples, bin_count)