예제 #1
0
def indices(dimensions, dtype=int32):
    ind = _dsutils.indices(asIterable(dimensions))
    dtype = _translatenativetype(dtype)
    if dtype != int32:
        ind = _dsutils.cast(ind, dtype.value)
    return ind
예제 #2
0
def indices(dimensions, dtype=int32):
    ind = _dsutils.indices(asIterable(dimensions))
    dtype = _translatenativetype(dtype)
    if dtype != int32:
        ind = _dsutils.cast(ind, dtype.value)
    return ind
예제 #3
0
def cast(a, dtype):
    return _dsutils.cast(a, dtype.value)
예제 #4
0
def cast(a, dtype):
    return _dsutils.cast(a, dtype.value)