code: def __init__(
      self,
      model: torch.nn.Module,
      config_list: List[Dict],
      evaluator: Evaluator,
      training_steps: int,
      existed_wrappers: Dict[str, ModuleWrapper] | None = None,
  ):
      super().__init__(
          model=model,
          config_list=config_list,
          evaluator=evaluator,
          existed_wrappers=existed_wrappers,
      )
      self.evaluator: Evaluator
      self.training_steps = training_steps
  
      # trigger masks generation when self._current_step == self.training_steps
      self._current_step = 0
      # save all target hooks with format {module_name: {target_name: hook}}
      self.hooks: Dict[str, Dict[str, TensorHook]] = defaultdict(dict)
  
      # `interval_steps` and `total_times` are used by `register_trigger`.
      # `interval_steps` is the optimize step interval for generating masks.
      # `total_times` is the total generation times of masks.
      self.interval_steps = training_steps
      self.total_times: int | Literal["unlimited"] = 1
  
imports: from __future__ import annotations
  from collections import defaultdict
  import functools
  import logging
  from typing import Callable, Dict, List, Literal, Tuple, overload
  import torch
  from .tools import _METRICS, _MASKS, norm_metrics, generate_sparsity, is_active_target
  from ..base.compressor import Compressor, Pruner
  from ..base.target_space import TargetType
  from ..base.wrapper import ModuleWrapper
  from ..utils.docstring import _EVALUATOR_DOCSTRING
  from ..utils.evaluator import Evaluator, TensorHook
label_desc: Use image node_id 3 to create a new TaylorPruner object from inherited base classes: Pruner with example: obj = TaylorPruner(model, config_list, evaluator, training_steps, existed_wrappers)