08c76ed8511e2e4d7f7a3f4406df4c073112e6bd,python/test/function/test_flip.py,,ref_flip,#Any#Any#,23

Before Change


def ref_flip(x, axes):
    if axes is None:
        axes = [len(x.shape) - 1]
    x = x.copy()
    for axis in axes:
        if axis == 0:
            x = x[::-1]
        elif axis == 1:
            x = x[::, ::-1]
        elif axis == 2:
            x = x[::, ::, ::-1]
        else:
            raise
    return x


@pytest.mark.parametrize("ctx, func_name", ctxs)
@pytest.mark.parametrize("seed", [313])

After Change


    //         x = x[::, ::, ::-1]
    //     else:
    //         raise
    return np.flip(x, axes)


@pytest.mark.parametrize("ctx, func_name", ctxs)
@pytest.mark.parametrize("seed", [313])
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 10

Instances


Project Name: sony/nnabla
Commit Name: 08c76ed8511e2e4d7f7a3f4406df4c073112e6bd
Time: 2021-02-16
Author: Krishna.Wadhwani@sony.com
File Name: python/test/function/test_flip.py
Class Name:
Method Name: ref_flip


Project Name: sony/nnabla
Commit Name: 08c76ed8511e2e4d7f7a3f4406df4c073112e6bd
Time: 2021-02-16
Author: Krishna.Wadhwani@sony.com
File Name: python/test/function/test_flip.py
Class Name:
Method Name: ref_flip


Project Name: analysiscenter/batchflow
Commit Name: 49f4e83ae4323e032bdd232e466e59b4aeceb458
Time: 2018-03-28
Author: g.ivanov@analysiscenter.ru
File Name: dataset/batch_image.py
Class Name: ImagesBatch
Method Name: _flip_


Project Name: analysiscenter/batchflow
Commit Name: d381fb0787395076ecb8a3bd6984f52a16793fae
Time: 2018-03-27
Author: g.ivanov@analysiscenter.ru
File Name: dataset/batch_image.py
Class Name: ImagesBatch
Method Name: _flip_