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","."]
code: def __init__(
      self,
      light_scenario_key: LightScenarioKey,
      num_instances: int,
      stats_tags: Optional[Dict[str, Any]] = None,
  ):
      self.stats_key = ContaminationStatsKey(
          metadata={"light_scenario_key": light_scenario_key}
      )
      self.num_instances = num_instances
      if stats_tags is not None:
          self.stats_key.metadata.update(stats_tags)
  
      self._input_bits = bitarray(num_instances)
      self._reference_bits = bitarray(num_instances)
      self._input_bits.setall(0)
      self._reference_bits.setall(0)
  
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 1 to create a new ContaminationStats object  with example: obj = ContaminationStats(light_scenario_key, num_instances, stats_tags)