class_docstr: Default graph compiler.
  It applies its topology to the input token sequence to compile the supervision graph.
  
  Based on https://github.com/k2-fsa/snowfall/blob/master/snowfall/training/ctc_graph.py
code: def to(self, device: torch.device):
      self.ctc_topo_inv = self.ctc_topo_inv.to(device)
      if self.base_graph is not None:
          self.base_graph = self.base_graph.to(device)
      self.device = device
  
imports: from typing import Optional, Tuple
  import torch
  from nemo.collections.asr.parts.k2.utils import add_self_loops, compose_with_self_loops, intersect_with_self_loops
  from nemo.core.utils.k2_guard import k2
label_desc: Use image node_id 2 for calling the CtcTopologyCompiler obj's underlying member method code with example usage: obj.to(device) without return types