Open Burhan-Q opened 10 months ago
NOTES HUB API requests:
Ultralytics HUB Documentation reference
f"https://api.ultralytics.com/v1/predict/{MODEL_ID}"
is the new end point
all inference arguments are passed into data
keyword as a dictionary
conf
: prediction confidencesize
: prediction image sizeiou
: prediction iou thresholdurl
: image URLnormalize
[!NOTE] Image URL can be passed directly to inference API
HUB account API key is required as part of the headers
headers = {"x-api-key": f"API_KEY"}
inference results returned as part of .json()
method of response
detect
results, response is:{data: [
{
class: int,
confidence: float,
name: str,
width: float,
height: float,
xcenter: float,
ycenter: float,
},
{...}, # additional objects detected
]
After release of latest HUB API, bot inference requests no longer working