79610349

Date: 2025-05-07 10:48:25
Score: 0.5
Natty:
Report link

you need to change color format of the image after resizing because opencv works with bgr format and yolo expects rgb

img = cv2.resize(image, (640, 640))  # Resize to model input size
img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB) 
img = img.astype(np.float32)

I guess this will solve your problem

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Ariya