def decode_target(self, label):
    m = label.astype(np.uint16)
    (r, c) = m.shape
    cmap = np.zeros((r, c, 3), dtype=np.uint8)
    cmap[:, :, 0] = ((((m & 1) << 7) | ((m & 8) << 3)) | ((m & 64) >> 1))
    cmap[:, :, 1] = ((((m & 2) << 6) | ((m & 16) << 2)) | ((m & 128) >> 2))
    cmap[:, :, 2] = (((m & 4) << 5) | ((m & 32) << 1))
    return cmap
def decode_target(self, label):
    m = label.astype(np.uint16)
    (r, c) = m.shape
    cmap = np.zeros((r, c, 3), dtype=np.uint8)
    cmap[:, :, 0] = ((((m & 1) << 7) | ((m & 8) << 3)) | ((m & 64) >> 1))
    cmap[:, :, 1] = ((((m & 2) << 6) | ((m & 16) << 2)) | ((m & 128) >> 2))
    cmap[:, :, 2] = (((m & 4) << 5) | ((m & 32) << 1))
    return cmap