(arg, stream=None)
return fracpart, intpart
Return a tuple `(fracpart, intpart)` of arrays containing the
    integer and fractional parts of `arg`.
Return a tuple `(fracpart, intpart)` of arrays containing the
    integer and fractional parts of `arg`.
Return a tuple ( fracpart intpart ) of arrays containing the integer and fractional parts of arg .
def modf(arg, stream=None):
    """Return a tuple `(fracpart, intpart)` of arrays containing the
    integer and fractional parts of `arg`.
    """
    if not arg.flags.forc:
        raise RuntimeError(
            "only contiguous arrays may " "be used as arguments to this operation"
        )

    intpart = gpuarray.GPUArray(arg.shape, arg.dtype)
    fracpart = gpuarray.GPUArray(arg.shape, arg.dtype)

    func = elementwise.get_modf_kernel()
    func.prepared_async_call(
        arg._grid,
        arg._block,
        stream,
        arg.gpudata,
        intpart.gpudata,
        fracpart.gpudata,
        arg.mem_size,
    )

    return fracpart, intpart
def modf ( arg , stream = None ) : if not arg . flags . forc : raise RuntimeError ( "only contiguous arrays may " "be used as arguments to this operation" ) intpart = gpuarray . GPUArray ( arg . shape , arg . dtype ) fracpart = gpuarray . GPUArray ( arg . shape , arg . dtype ) func = elementwise . get_modf_kernel ( ) func . prepared_async_call ( arg . _grid , arg . _block , stream , arg . gpudata , intpart . gpudata , fracpart . gpudata , arg . mem_size , ) return fracpart , intpart