code: def do_check_with_table(
      lines: List[str], transitions: Dict[str, Set[Optional[str]]]
  ) -> None:
      state = None
      i_prev = None
      for i, line in enumerate(lines):
          cb = line.split(":")[0]
          if cb in transitions:
              assert (
                  state in transitions[cb]
              ), f"illegal callback {cb} on line {i} after {state} on line {i_prev}"
              state = cb
              i_prev = i
  
imports: import io
  from typing import Any, Callable, Dict, List, Optional, Set
  import determined
  import determined.keras
label_desc: Use image node_id 2 for calling a global function with example usage: do_check_with_table(lines, transitions) without return types