code: def _get_weights_dtype(input, weights):
      if weights.dtype.kind == "c" or input.dtype.kind == "c":
          return cupy.promote_types(input.real.dtype, cupy.complex64)
      elif weights.dtype.kind in "iub":
          # convert integer dtype weights to double as in SciPy
          return cupy.float64
      return cupy.promote_types(input.real.dtype, cupy.float32)
  
file_path: cupy/cupyx/scipy/ndimage/_util.py
imports: import warnings
  import numpy
  import cupy
label_desc: Use image node_id 4 for calling a global function with example usage: _get_weights_dtype(input, weights) and returns: cupy, cupy, cupy