ginhang2209 commited on
Commit
2401f91
·
verified ·
1 Parent(s): 5cacc93

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -68,7 +68,7 @@ except Exception as e:
68
  # Helper
69
  def prepare_canny(image_path):
70
  img = cv2.imread(image_path)
71
- img = cv2.resize(img, (512, 512))
72
  edge = cv2.Canny(img, 100, 200)
73
  edge = cv2.cvtColor(edge, cv2.COLOR_GRAY2RGB)
74
  return Image.fromarray(edge)
 
68
  # Helper
69
  def prepare_canny(image_path):
70
  img = cv2.imread(image_path)
71
+ img = cv2.resize(img, (768, 768)) # tăng từ 512 nếu muốn ảnh chi tiết hơn
72
  edge = cv2.Canny(img, 100, 200)
73
  edge = cv2.cvtColor(edge, cv2.COLOR_GRAY2RGB)
74
  return Image.fromarray(edge)