code: def _get_multiindex_codes(mi):
      if isinstance(mi, _pandas_api.pd.MultiIndex):
          return mi.codes
      else:
          return None
  
imports: import ast
  from collections.abc import Sequence
  from concurrent import futures
  import concurrent.futures.thread
  from copy import deepcopy
  from itertools import zip_longest
  import json
  import operator
  import re
  import warnings
  import numpy
  import pyarrow
  from pyarrow.lib import _pandas_api, frombytes
label_desc: Use image node_id 31 for calling a global function with example usage: _get_multiindex_codes(mi) and returns: mi, None