def METHOD_NAME(x, quantize_zero_to):
    """ Performs binarization of one kernel """
    y = np.sign(x)
    y[y == 0] = quantize_zero_to
    y = (y.T * np.mean(np.abs(x), tuple(range(1, x.ndim))).T).T
    return y