parameters: (arr, val, mask=None, compare="eq")
return_statement: return cudf.core.column.column.as_column(found).set_mask(mask)
docstring: Returns the indices of the occurrence of *val* in *arr*
      as per *compare*, if not found it will be filled with
      size of *arr*
  
      Parameters
      ----------
      arr : device array
      val : scalar
      mask : mask of the array
      compare: str ('gt', 'lt', or 'eq' (default))
docstring_summary: Returns the indices of the occurrence of *val* in *arr*
      as per *compare*, if not found it will be filled with
      size of *arr*
docstring_tokens: Returns the indices of the occurrence of * val * in * arr * as per * compare * if not found it will be filled with size of * arr *
function: def find_index_of_val(arr, val, mask=None, compare="eq"):
      """
      Returns the indices of the occurrence of *val* in *arr*
      as per *compare*, if not found it will be filled with
      size of *arr*
  
      Parameters
      ----------
      arr : device array
      val : scalar
      mask : mask of the array
      compare: str ('gt', 'lt', or 'eq' (default))
      """
      found = cuda.device_array(shape=(arr.shape), dtype="int32")
      if found.size > 0:
          if compare == "gt":
              gpu_mark_gt.forall(found.size)(arr, val, found, arr.size)
          elif compare == "lt":
              gpu_mark_lt.forall(found.size)(arr, val, found, arr.size)
          else:
              if arr.dtype in ("float32", "float64"):
                  gpu_mark_found_float.forall(found.size)(
                      arr, val, found, arr.size
                  )
              else:
                  gpu_mark_found_int.forall(found.size)(
                      arr, val, found, arr.size
                  )
  
      return cudf.core.column.column.as_column(found).set_mask(mask)
function_tokens: def find_index_of_val ( arr , val , mask = None , compare = "eq" ) : found = cuda . device_array ( shape = ( arr . shape ) , dtype = "int32" ) if found . size > 0 : if compare == "gt" : gpu_mark_gt . forall ( found . size ) ( arr , val , found , arr . size ) elif compare == "lt" : gpu_mark_lt . forall ( found . size ) ( arr , val , found , arr . size ) else : if arr . dtype in ( "float32" , "float64" ) : gpu_mark_found_float . forall ( found . size ) ( arr , val , found , arr . size ) else : gpu_mark_found_int . forall ( found . size ) ( arr , val , found , arr . size ) return cudf . core . column . column . as_column ( found ) . set_mask ( mask )