def METHOD_NAME(self, arg_pos, arr, dtype=np.float32):
    """
    Add an input buffer to the kernel program. Input buffers
    must be added in the same order as they are declared inside
    the kernel code (.cl file).
    Parameters
    ----------
    arg_pos: int
        Position of the buffer in the input buffers list.
    arr: numpy ndarray
        Data array.
    dtype: dtype, optional
        Optional type for array data. It is recommended to use float32
        whenever possible to avoid unexpected behaviours.
    Returns
    -------
    indice: int
        Index of the input buffer in the input buffers list.
    Note
    ----
    Array is reordered as fortran array and then flattened. This is
    important to keep in mind when writing kernel code.
    For example, for a 3-dimensional array of shape (X, Y, Z), the flat
    index for position i, j, k is idx = i + j * X + z * X * Y.
    """
    # convert to fortran ordered, dtype array
    arr = np.asfortranarray(arr, dtype=dtype)
    buf = cl.Buffer(self.context,
                    cl.mem_flags.READ_ONLY | cl.mem_flags.COPY_HOST_PTR,
                    hostbuf=arr)
    self.input_buffers[arg_pos] = buf