code: def _get_check_index(trans, right, row_idx=0, col_idx=1):
      if trans ^ right:
          return row_idx
      else:
          return col_idx
  
imports: import warnings
  import numpy
  from chainer import backend
  from chainer.backends import cuda
  from chainer import function_node
  import chainer.functions
  from chainer import utils
  from chainer.utils import type_check
  import chainerx
label_desc: Use image node_id 6 for calling a global function with example usage: _get_check_index(trans, right, row_idx, col_idx) and returns: row_idx, col_idx