class_docstr: Aggregate combine function.
  
  This function really does three things:
    1. Batching of FeaturesPredictionsLabels.
    3. "Partial reduction" of these batches by sending this through the
       "intro metrics" step.
    3. The "normal" combining of MetricVariables.
  
  What we really want to do is conceptually the following:
  Predictions | GroupByKey() | KeyAwareBatchElements()
              | ParDo(IntroMetrics()) | CombineValues(CombineMetricVariables()).
  
  but there's no way to KeyAwareBatchElements in Beam, and no way to do partial
  reductions either. Hence, this CombineFn has to do the work of batching,
  partial reduction (intro metrics), and actual combining, all in one.
  
  We do this by accumulating FeaturesPredictionsLabels in the combine state
  until we accumulate a large enough batch, at which point we send them
  through the "intro metrics" step. When merging, we merge the metric variables
  and accumulate FeaturesPredictionsLabels accordingly. We do one final
  "intro metrics" and merge step before producing the final output value.
  
  See also:
  BEAM-3737: Key-aware batching function
  (https://issues.apache.org/jira/browse/BEAM-3737).
docstr: Creates a bootstrap resample of the data in an accumulator.
  
  Given a set of data, it will be represented in the resample set a number of
  times, that number of times is drawn from Poisson(1).
  See
  http://www.unofficialgoogledatascience.com/2015/08/an-introduction-to-poisson-bootstrap26.html
  for a detailed explanation of the technique. This will work technically with
  small or empty batches but as the technique is an approximation, the
  approximation gets better as the number of examples gets larger. If the
  results themselves are empty TFMA will reject the sample. For any samples of
  a reasonable size, the chances of this are exponentially tiny. See "The
  mathematical fine print" section of the blog post linked above.
  
  Args:
    accumulator: Accumulator containing FPLs from a sample
  
  Returns:
    A list of FPLs representing a bootstrap resample of the accumulator items.
docstr_tok: ["Creates","a","bootstrap","resample","of","the","data","in","an","accumulator",".","Given","a","set","of","data",",","it","will","be","represented","in","the","resample","set","a","number","of","times",",","that","number","of","times","is","drawn","from","Poisson","(","1",")",".","See","http",":","\/\/www.unofficialgoogledatascience.com\/2015\/08\/an-introduction-to-poisson-bootstrap26.html","for","a","detailed","explanation","of","the","technique",".","This","will","work","technically","with","small","or","empty","batches","but","as","the","technique","is","an","approximation",",","the","approximation","gets","better","as","the","number","of","examples","gets","larger",".","If","the","results","themselves","are","empty","TFMA","will","reject","the","sample",".","For","any","samples","of","a","reasonable","size",",","the","chances","of","this","are","exponentially","tiny",".","See","``","The","mathematical","fine","print","''","section","of","the","blog","post","linked","above",".","Args",":","accumulator",":","Accumulator","containing","FPLs","from","a","sample","Returns",":","A","list","of","FPLs","representing","a","bootstrap","resample","of","the","accumulator","items","."]
code: def _poissonify(self, accumulator: _AggState) -> List[bytes]:
      # pylint: disable=line-too-long
      """Creates a bootstrap resample of the data in an accumulator.
  
      Given a set of data, it will be represented in the resample set a number of
      times, that number of times is drawn from Poisson(1).
      See
      http://www.unofficialgoogledatascience.com/2015/08/an-introduction-to-poisson-bootstrap26.html
      for a detailed explanation of the technique. This will work technically with
      small or empty batches but as the technique is an approximation, the
      approximation gets better as the number of examples gets larger. If the
      results themselves are empty TFMA will reject the sample. For any samples of
      a reasonable size, the chances of this are exponentially tiny. See "The
      mathematical fine print" section of the blog post linked above.
  
      Args:
        accumulator: Accumulator containing FPLs from a sample
  
      Returns:
        A list of FPLs representing a bootstrap resample of the accumulator items.
      """
      result = []
      if accumulator.inputs:
          poisson_counts = self._random_state.poisson(
              1, len(accumulator.inputs)
          )
          for i, input_item in enumerate(accumulator.inputs):
              result.extend([input_item] * poisson_counts[i])
      return result
  
imports: from typing import Any, Dict, Generator, Iterable, List, Optional, Tuple
  import apache_beam
  import numpy
  from tensorflow_model_analysis import constants
  from tensorflow_model_analysis.api import types
  from tensorflow_model_analysis.eval_metrics_graph import eval_metrics_graph
  from tensorflow_model_analysis.slicer import slicer_lib
  from tensorflow_model_analysis.utils import model_util
  from tensorflow_model_analysis.utils import size_estimator
label_desc: Use image node_id 2 for calling the _AggregateCombineFn obj's underlying member method code with example usage: obj._poissonify(accumulator) and returns: result