Open Soongja opened 1 year ago
I am sorry for the late reply.
Yes
msk = ((wc[:, :, 0] != 0) & (wc[:, :, 1] != 0) & (wc[:, :, 2] != 0)).astype(np.uint8)
xmx, xmn, ymx, ymn, zmx, zmn = 1.2485291, -1.2410645, 1.2387834, -1.2280148, 0.63452387, -0.67187124
wc[:, :, 0] = (wc[:, :, 0] - zmn) / (zmx - zmn)
wc[:, :, 1] = (wc[:, :, 1] - ymn) / (ymx - ymn)
wc[:, :, 2] = (wc[:, :, 2] - xmn) / (xmx - xmn)
wc = cv2.bitwise_and(wc, wc, mask=msk)
Hope this helps! Good luck~