roboflow / roboflow/roboflow-python
Wrong Roboflow return result after prediction
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Python
- Sterne
- 629
- Forks
- 140
- Ø Merge
- 2 T. 2 Std.
- Gemergte PRs (30 T.)
- 5
Beschreibung
Hi
I am trying out the api to return the result. The result of the bounding box seem to be off despite when I do the roboflow save action to save the image to visualize the bounding box. The save action shows the correct position of the bounding box but not the return result. Any advice?
predict = model.predict("test.jpg", confidence=40, overlap=0).json()
gives when the python return the json result:
{'x': 508.5, 'y': 212.5, 'width': 263.0, 'height': 225.0, 'confidence': 0.9291292428970337, 'class': 'car', 'image_path': 'test.jpg', 'prediction_type': 'ObjectDetectionModel'}
{'x': 233.0, 'y': 164.0, 'width': 40.0, 'height': 34.0, 'confidence': 0.8354455232620239, 'class': 'car', 'image_path': 'test.jpg', 'prediction_type': 'ObjectDetectionModel'}
{'x': 347.5, 'y': 173.0, 'width': 53.0, 'height': 146.0, 'confidence': 0.7597783803939819, 'class': 'person', 'image_path': 'test.jpg', 'prediction_type': 'ObjectDetectionModel'}
whereas if i drop the image into the roboflow ui to do the detection, using confidence level of 40 and overlap of 0, on the roboflow ui , it is
{
"predictions": [
{
"x": 406.5,
"y": 170,
"width": 211,
"height": 180,
"confidence": 0.929,
"class": "car"
},
{
"x": 277.5,
"y": 138.5,
"width": 43,
"height": 117,
"confidence": 0.84,
"class": "person"
},
{
"x": 186.5,
"y": 131.5,
"width": 31,
"height": 27,
"confidence": 0.784,
"class": "car"
}
]
}
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne mit dem Aufruf model.predict("test.jpg", confidence=40, overlap=0).json() und reproduziere die gemeldeten Koordinaten für test.jpg. Vergleiche diese Ergebnisse mit der Ausgabe der Roboflow UI und der gespeicherten Visualisierung und ermittle anschließend, warum sich die Bounding Boxes unterscheiden. Die Aufgabe ist erledigt, wenn die Ergebnisse von API und UI für diese Reproduktion übereinstimmen oder die Abweichung mit einer eindeutigen Lösung dokumentiert ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- python
- Bereich
- computer-vision, machine-learning
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Muss geklärt werden
- Anfängerfreundlichkeit
- 25/100