Fixed preparation of predictions for evaluate

Signed-off-by: Jim Martens <github@2martens.de>
This commit is contained in:
Jim Martens 2019-09-16 13:17:31 +02:00
parent d24c622d86
commit 48ee5466fb
1 changed files with 5 additions and 5 deletions

View File

@ -104,11 +104,11 @@ def prepare_predictions(predictions: Sequence[Sequence[Sequence[Union[int, float
# Round the box coordinates to reduce the required memory.
confidence = box[1]
xmin = round(box[xmin])
ymin = round(box[ymin])
xmax = round(box[xmax])
ymax = round(box[ymax])
prediction = (image_id, confidence, xmin, ymin, xmax, ymax)
xmin_value = round(box[xmin])
ymin_value = round(box[ymin])
xmax_value = round(box[xmax])
ymax_value = round(box[ymax])
prediction = (image_id, confidence, xmin_value, ymin_value, xmax_value, ymax_value)
# Append the predicted box to the results list for its class.
results[class_id].append(prediction)