Need help with image.image


i keep getting a error thrown saying that it cant find the file. I have the image on the openmv but unsure why it isnt doing anything.

# Load coin template
template = image.Image("coin.bmp")

    # Capture image
    img = sensor.snapshot()

    # Find template match in image
    match = img.find_template(template, 0.70)

    # Check if match is found
    if match:

Hi, can you verify the image is written to disk? I.e. safety remove the camera from the PC and then re-attach.


I removed the camera and plugged it back in and can see the image on its files

Okay, then it could be the bmp file format. The error message might not say that it’s just something in the file can’t be understood. Please save as a jpeg.