code: def _map_l2_norm_kernel(dtype):
      """Creates cupy RawKernel for csr_raw_normalize_l2 function."""
  
      map_kernel_str = r"""
      ({0} *data, {1} *indices, {2} *indptr, int n_samples) {
  
        int tid = blockDim.x * blockIdx.x + threadIdx.x;
  
        if(tid >= n_samples) return;
        {0} sum = 0.0;
  
        for(int i = indptr[tid]; i < indptr[tid+1]; i++) {
          sum += (data[i] * data[i]);
        }
  
        if(sum == 0) return;
  
        sum = sqrt(sum);
  
        for(int i = indptr[tid]; i < indptr[tid+1]; i++) {
          data[i] /= sum;
        }
      }
      """
      return cuda_kernel_factory(
          map_kernel_str, dtype, "map_l2_norm_kernel"
      )
  
file_path: cuml/python/cuml/common/sparsefuncs.py
imports: import math
  import cuml
  from cuml.internals.input_utils import input_to_cuml_array, input_to_cupy_array
  from cuml.internals.memory_utils import with_cupy_rmm
  from cuml.internals.import_utils import has_scipy
  from cuml.common.kernel_utils import cuda_kernel_factory
  from cuml.internals.safe_imports import cpu_only_import
  from cuml.internals.safe_imports import gpu_only_import
  from cuml.internals.safe_imports import gpu_only_import_from
label_desc: Use image node_id 2 for calling a global function with example usage: _map_l2_norm_kernel(dtype) and returns: cuda_kernel_factory