code: def tokenize(idx, token_type, n_special=4, n_note=128, n_velocity=2):
      if token_type == "TOKEN_TIME":
          return n_special + n_note + n_velocity + idx
      elif token_type == "TOKEN_VELOCITY":
          return n_special + n_note + idx
      elif token_type == "TOKEN_NOTE":
          return n_special + idx
      elif token_type == "TOKEN_SPECIAL":
          return idx
      else:
          return -1
  
imports: import json
  import torch
  from transformers import Pop2PianoConfig, Pop2PianoForConditionalGeneration
label_desc: Use image node_id 1 for calling a global function with example usage: tokenize(idx, token_type, n_special, n_note, n_velocity) and returns: unknown, unknown, unknown, idx, unknown