code: def get_spm_tokens(model_path):
      """Fetch list of tokens, can be indexed by token id
  
      The resulting list can be used to map id to token.
  
      Arguments
      ---------
      model_path : str
          Path to SentencePiece model
  
      Returns
      -------
      list
          Tokens in order by id (can be indexed by id)
      """
      model = spm.SentencePieceProcessor()
      model.load(model_path)
      mapping = [
          model.sp.id_to_piece(i) for i in range(model.sp.vocab_size())
      ]
      return mapping
  
file_path: speechbrain/speechbrain/tokenizers/SentencePiece.py
imports: import os.path
  import torch
  import logging
  import csv
  import json
  import sentencepiece
  from speechbrain.dataio.dataio import merge_char
  from speechbrain.utils import edit_distance
  from speechbrain.utils.distributed import run_on_main
label_desc: Use image node_id 1 for calling a global function with example usage: get_spm_tokens(model_path) and returns: mapping