def _thin_cond_g2():
    '\n    Thinning morphological operation; condition G2\n    :return: a LUT index mask\n    '
    n1 = np.zeros(512, dtype=int)
    n2 = np.zeros(512, dtype=int)
    for k in range(1, 5):
        n1 += (lut_masks_one(((2 * k) - 1)) | lut_masks_one((2 * k)))
        n2 += (lut_masks_one((2 * k)) | lut_masks_one(((2 * k) + 1)))
    m = np.minimum(n1, n2)
    return ((m >= 2) & (m <= 3))
Thinning morphological operation; condition G2
:return: a LUT index mask
def _thin_cond_g2():
    '\n    Thinning morphological operation; condition G2\n    :return: a LUT index mask\n    '
    n1 = np.zeros(512, dtype=int)
    n2 = np.zeros(512, dtype=int)
    for k in range(1, 5):
        n1 += (lut_masks_one(((2 * k) - 1)) | lut_masks_one((2 * k)))
        n2 += (lut_masks_one((2 * k)) | lut_masks_one(((2 * k) + 1)))
    m = np.minimum(n1, n2)
    return ((m >= 2) & (m <= 3))