def sresample(src, outshape):
    """ Simple 3d array resampling

    Inputs:
      src -- a ndimensional array (dim>2)
      outshape -- fixed output shape for the first 2 dimensions

    Outputs:
       hout -- resulting n-dimensional array

    """

    inh, inw = src.shape[:2]
    outh, outw = outshape
    hslice = (np.arange(outh) * (inh-1.)/(outh-1.)).round().astype(int)
    wslice = (np.arange(outw) * (1.-inw)/(outw-1.)).round().astype(int)
    hout = src[hslice, :][:, wslice]
    return hout.copy()
dataset/ETHPy150Open bolme/pyvision/src/pyvision/features/v1like.py/sresample/swapped operands of `-`