class_docstr: Behavior descriptor extractor.
docstr: Initialization of a behavior descriptor extractor.
  
  Args:
      bd_spec - A list of behavior descriptors, each of which gives the
                name and the number of bins. E.g. [('bd1', 10), ...]
      bd_state_spec - A list of states that record rollout statistics to
                      help calculate the behavior descriptors.
                      E.g. [('bd1_stat1', jnp.int32), ...]
      task_state_def - The original task definition. BDExtractor extends
                       that definition to record data in rollouts.
docstr_tok: ["Initialization","of","a","behavior","descriptor","extractor",".","Args",":","bd_spec","-","A","list","of","behavior","descriptors",",","each","of","which","gives","the","name","and","the","number","of","bins",".","E.g",".","[","(","'bd1","'",",","10",")",",","...","]","bd_state_spec","-","A","list","of","states","that","record","rollout","statistics","to","help","calculate","the","behavior","descriptors",".","E.g",".","[","(","'bd1_stat1","'",",","jnp.int32",")",",","...","]","task_state_def","-","The","original","task","definition",".","BDExtractor","extends","that","definition","to","record","data","in","rollouts","."]
code: def __init__(
      self,
      bd_spec: List[Tuple[str, int]],
      bd_state_spec: List[Tuple[str, T]],
      task_state_def: T,
  ):
      """Initialization of a behavior descriptor extractor.
  
      Args:
          bd_spec - A list of behavior descriptors, each of which gives the
                    name and the number of bins. E.g. [('bd1', 10), ...]
          bd_state_spec - A list of states that record rollout statistics to
                          help calculate the behavior descriptors.
                          E.g. [('bd1_stat1', jnp.int32), ...]
          task_state_def - The original task definition. BDExtractor extends
                           that definition to record data in rollouts.
      """
      self.bd_spec = bd_spec
      if bd_state_spec is None:
          self.bd_state_spec = []
      else:
          self.bd_state_spec = bd_state_spec
      self.extended_task_state = self.get_extended_task_state_def(
          task_state_def
      )
  
imports: from abc import ABC
  from abc import abstractmethod
  from typing import Dict
  from typing import List
  from typing import Tuple
  from typing import TypeVar
  import dataclasses
  import jax.numpy
  from flax.struct import dataclass
label_desc: Use image node_id 1 to create a new BDExtractor object from inherited base classes: object with example: obj = BDExtractor(bd_spec, bd_state_spec, task_state_def)