consumer模块完成度95%,准备部署消费者端测试

This commit is contained in:
cyh666666
2026-03-05 08:45:00 +08:00
parent cceb556c62
commit 7f7f723d93
1043 changed files with 53958 additions and 3445 deletions

20
check_icons.py Normal file
View File

@@ -0,0 +1,20 @@
import cv2
import numpy as np
import os
def check_icon_brightness(file_path):
if not os.path.exists(file_path):
return None
img = cv2.imread(file_path, cv2.IMREAD_GRAYSCALE)
if img is None:
return None
# 计算非透明区域的平均亮度
return np.mean(img)
icon_dir = r'D:\companyproject\mall\pages\mall\consumer\icons'
fav = os.path.join(icon_dir, 'favorite.png')
fav_active = os.path.join(icon_dir, 'favorite-active.png')
print(f"favorite.png brightness: {check_icon_brightness(fav)}")
print(f"favorite-active.png brightness: {check_icon_brightness(fav_active)}")