jibsn commited on
Commit
b8b9877
·
verified ·
1 Parent(s): 879dc13

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -12,7 +12,7 @@ def preprocess_image(image):
12
  预处理输入图片
13
  """
14
  # 将图片调整为模型所需的输入尺寸
15
- image = image.resize((224, 224)) # 根据实际模型需求调整尺寸
16
  # 转换为numpy数组并归一化
17
  img_array = np.array(image)
18
  img_array = img_array.astype(np.float32) / 255.0
 
12
  预处理输入图片
13
  """
14
  # 将图片调整为模型所需的输入尺寸
15
+ image = image.resize((640, 640)) # 根据实际模型需求调整尺寸
16
  # 转换为numpy数组并归一化
17
  img_array = np.array(image)
18
  img_array = img_array.astype(np.float32) / 255.0