summaryrefslogtreecommitdiff
path: root/numpy/_array_api/manipulation_functions.py
blob: 80ca3381eb4b41c8d24f1fb0c43bb4c998ff4f0b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
def concat(arrays, /, *, axis=0):
    # Note: the function name is different here
    from .. import concatenate
    return concatenate(arrays, axis=axis)

def expand_dims(x, axis, /):
    from .. import expand_dims
    return expand_dims(x, axis)

def flip(x, /, *, axis=None):
    from .. import flip
    return flip(x, axis=axis)

def reshape(x, shape, /):
    from .. import reshape
    return reshape(x, shape)

def roll(x, shift, /, *, axis=None):
    from .. import roll
    return roll(x, shift, axis=axis)

def squeeze(x, /, *, axis=None):
    from .. import squeeze
    return squeeze(x, axis=axis)

def stack(arrays, /, *, axis=0):
    from .. import stack
    return stack(arrays, axis=axis)

__all__ = ['concat', 'expand_dims', 'flip', 'reshape', 'roll', 'squeeze', 'stack']