예제 #1
0
파일: math_ops.py 프로젝트: zhaoqiuye/trax
def append(arr, values, axis=None):
    if axis is None:
        return concatenate([array_ops.ravel(arr), array_ops.ravel(values)], 0)
    else:
        return concatenate([arr, values], axis=axis)
예제 #2
0
 def run_test(arr, *args, **kwargs):
     for fn in self.array_transforms:
         arg = fn(arr)
         self.match(array_ops.ravel(arg, *args, **kwargs),
                    np.ravel(arg, *args, **kwargs))