def test_roi_max_counts():
    img_stack1 = np.random.randint(0, 60, size=(50, ) + (50, 50))
    img_stack2 = np.random.randint(0, 60, size=(100, ) + (50, 50))

    img_stack1[0][20, 20] = 60

    samples = (img_stack1, img_stack2)

    label_array = np.zeros((img_stack1[0].shape))

    label_array[img_stack1[0] < 20] = 1
    label_array[40 > img_stack1[0]] = 2

    assert_array_equal(60, roi.roi_max_counts(samples, label_array))
dataset/ETHPy150Open scikit-beam/scikit-beam/skbeam/core/tests/test_roi.py/test_roi_max_counts/swapped operands of `>`