code: def _decide_ld_and_trans(a, trans):
      ld = None
      if trans in (cublas.CUBLAS_OP_N, cublas.CUBLAS_OP_T):
          if a._f_contiguous:
              ld = a.shape[0]
          elif a._c_contiguous:
              ld = a.shape[1]
              trans = 1 - trans
      return ld, trans
  
imports: import numpy
  from numpy import linalg
  import warnings
  import cupy
  from cupy import _core
  from cupy_backends.cuda.libs import cublas
  from cupy.cuda import device
  from cupy.linalg import _util
label_desc: Use image node_id 24 for calling a global function with example usage: _decide_ld_and_trans(a, trans) and returns: ld,  trans