class_docstr: A memory-efficient class for contamination stats. The core data structures are bit arrays where
  every bit records whether an instance is contaminated or not.
class_docstr_tok: ["A","memory-efficient","class","for","contamination","stats",".","The","core","data","structures","are","bit","arrays","where","every","bit","records","whether","an","instance","is","contaminated","or","not","."]
docstr: Output a summary of the stats
docstr_tok: ["Output","a","summary","of","the","stats"]
code: def generate_summary(
      self, summary_tags: Optional[Dict[str, Any]] = None
  ) -> Dict[str, Any]:
      """Output a summary of the stats"""
      if summary_tags is None:
          summary_tags = {}
      summary = {
          "setting": {
              "stats_key": asdict_without_nones(self.stats_key),
              **summary_tags,
          },
          "num_instances": self.num_instances,
          "num_instances_with_contaminated_input": self.num_instances_with_contaminated_input,
          "num_instances_with_contaminated_reference": self.num_instances_with_contaminated_reference,
          "contaminated_input_fraction": self.contaminated_input_fraction,
          "contaminated_reference_fraction": self.contaminated_reference_fraction,
      }
      return summary
  
file_path: H2O/h2o_hf/helm/src/helm/benchmark/contamination/contamination_stats.py
imports: from bitarray import bitarray
  from typing import Optional, Dict, Any, Hashable
  from dataclasses import dataclass
  from helm.benchmark.contamination.light_scenario import LightScenario, LightScenarioKey
  from helm.common.general import asdict_without_nones
label_desc: Use image node_id 10 for calling the ContaminationStats obj's underlying member method code with example usage: obj.generate_summary(summary_tags) and returns: summary