class_docstr: Single Event containing a filter, specifying whether the event should
  be run at the current event (if the event type is correct)
  
  Args:
      value: The actual enum value. Only needed for internal use. Do not touch!
      event_filter: A function taking the engine and the current event value as input and returning a
          boolean to indicate whether this event should be executed. Defaults to None, which will result to a
          function that always returns `True`
      name: The enum-name of the current object. Only needed for internal use. Do not touch!
class_docstr_tok: ["Single","Event","containing","a","filter",",","specifying","whether","the","event","should","be","run","at","the","current","event","(","if","the","event","type","is","correct",")","Args",":","value",":","The","actual","enum","value",".","Only","needed","for","internal","use",".","Do","not","touch","!","event_filter",":","A","function","taking","the","engine","and","the","current","event","value","as","input","and","returning","a","boolean","to","indicate","whether","this","event","should","be","executed",".","Defaults","to","None",",","which","will","result","to","a","function","that","always","returns","`","True","`","name",":","The","enum-name","of","the","current","object",".","Only","needed","for","internal","use",".","Do","not","touch","!"]
docstr: A wrapper which triggers for every `every` iterations after `after` and before `before`.
docstr_tok: ["A","wrapper","which","triggers","for","every","`","every","`","iterations","after","`","after","`","and","before","`","before","`","."]
code: def every_before_and_after_event_filter(
      every: int,
      before: Optional[int] = None,
      after: Optional[int] = None,
  ) -> Callable:
      """A wrapper which triggers for every `every` iterations after `after` and before `before`."""
      before_: Union[int, float] = (
          float("inf") if before is None else before
      )
      after_: int = 0 if after is None else after
  
      def wrapper(engine: "Engine", event: int) -> bool:
          if (
              after_ < event < before_
              and (event - after_ - 1) % every == 0
          ):
              return True
          return False
  
      return wrapper
  
imports: import numbers
  import warnings
  import weakref
  from collections.abc import Sequence
  from enum import Enum
  from types import DynamicClassAttribute
  from typing import Any, Callable, Dict, Iterable, Iterator, List, Optional, TYPE_CHECKING, Union
  from torch.utils.data import DataLoader
  from ignite.engine.utils import _check_signature
label_desc: Use image node_id 8 for calling the CallableEventWithFilter obj's underlying member method code with example usage: obj.every_before_and_after_event_filter(every, before, after) and returns: wrapper, False, True