Im trying out an example from one of the blog posts and am getting an error. I looked through the forum, and the solution of upgrading roboflow to latest doesnt solve the issue. Whats the problem?
from roboflow import Roboflow
import supervision as sv
import cv2
import tempfile
import os
Load the Roboflow API and authenticate with your API key
rf = Roboflow(api_key=“xxxxxxx”)
Load the project for identifying parts of the car
project_parts = rf.workspace().project(“car-parts-segmentation”)
model_parts = project_parts.version(2).model
Load the project for detecting damaged areas of the car
project_damage = rf.workspace().project(“car-damage-detection-ha5mm”)
model_damage = project_damage.version(1).model
Path to the input image
img_path = “13b15550cec5cabf63fe48bcf17aaa05.jpg”
Run the models on the input image
result_damage = model_damage.predict(img_path, confidence=40).json()
Im getting the following error " line 22, in
result_damage = model_damage.predict(img_path, confidence=40).json()
^^^^^^^^^^^^^^^^^^^^
AttributeError: ‘NoneType’ object has no attribute ‘predict’"