class_docstr: Runs type inference on a single AST statement.
  
  This visitor annotates most nodes with type information. It also sets types
  for the symbols modified by this statement in its types_out property.
  
  Note: this inferrer is able to capture side effects of functions, however,
  these side effects will not be applied to the current expression. Doing so
  would create too much of a dependence on the runtime's internal rules about
  execution order.
  Example:
  
    def f():
      nonlocal a
      a = 1
      return a
  
    a = 0.0
    b = f() + a  # a = float; side effect of f() ignored
    print(a)  # a = int; side effect of f() accounted for
class_docstr_tok: ["Runs","type","inference","on","a","single","AST","statement",".","This","visitor","annotates","most","nodes","with","type","information",".","It","also","sets","types","for","the","symbols","modified","by","this","statement","in","its","types_out","property",".","Note",":","this","inferrer","is","able","to","capture","side","effects","of","functions",",","however",",","these","side","effects","will","not","be","applied","to","the","current","expression",".","Doing","so","would","create","too","much","of","a","dependence","on","the","runtime","'s","internal","rules","about","execution","order",".","Example",":","def","f","(",")",":","nonlocal","a","a","=","1","return","a","a","=","0.0","b","=","f","(",")","+","a","#","a","=","float",";","side","effect","of","f","(",")","ignored","print","(","a",")","#","a","=","int",";","side","effect","of","f","(",")","accounted","for"]
code: def visit(self, node):
      types = super().visit(node)
      if __debug__:
          self._check_set(types)
      if types is not None:
          # TODO(mdan): Normalize by removing subtypes.
          anno.setanno(node, anno.Static.TYPES, tuple(types))
      return types
  
imports: import itertools
  from typing import Any, Callable, Dict, Set
  import gast
  from nvidia.dali._autograph.pyct import anno
  from nvidia.dali._autograph.pyct import cfg
  from nvidia.dali._autograph.pyct import qual_names
  from nvidia.dali._autograph.pyct import transformer
  from nvidia.dali._autograph.pyct.static_analysis import activity
  from nvidia.dali._autograph.pyct.static_analysis import annos
label_desc: Use image node_id 2 for calling the StmtInferrer obj's underlying member method code with example usage: obj.visit(node) and returns: types