fix: what is this shit

This commit is contained in:
2023-10-09 00:16:54 +08:00
parent c009a28f92
commit 1aa71685ce

View File

@ -21,7 +21,6 @@ def phash_opencv(img_gray, hash_size=8, highfreq_factor=4):
img_size = hash_size * highfreq_factor
image = cv2.resize(img_gray, (img_size, img_size), interpolation=cv2.INTER_LANCZOS4)
image = np.float32(image)
dct = cv2.dct(image, flags=cv2.DCT_ROWS)
dct = cv2.dct(image)
dctlowfreq = dct[:hash_size, :hash_size]
med = np.median(dctlowfreq)