mirror of
https://github.com/Laurent2916/REVA-QCAV.git
synced 2024-11-08 14:39:00 +00:00
chore: remove unused file
Former-commit-id: bf466229627337e31bff835bd7615b764ab982ac [formerly 919ecf8585bd9910ffd9722ff390e16d265dc2fa] Former-commit-id: 2e4531522077a9191c55b5952f05bd0c4f2346f4
This commit is contained in:
parent
3bbc132359
commit
db90446eb0
|
@ -1,70 +0,0 @@
|
|||
import torch
|
||||
from torchmetrics.detection.mean_ap import MeanAveragePrecision
|
||||
|
||||
preds = [
|
||||
dict(
|
||||
boxes=torch.tensor(
|
||||
[
|
||||
[880.0560, 41.7845, 966.9839, 131.3355],
|
||||
[1421.0029, 682.4420, 1512.7570, 765.2380],
|
||||
[132.0775, 818.5026, 216.0825, 1020.8573],
|
||||
]
|
||||
),
|
||||
scores=torch.tensor(
|
||||
[0.9989, 0.9936, 0.0932],
|
||||
),
|
||||
labels=torch.tensor(
|
||||
[1, 1, 1],
|
||||
),
|
||||
)
|
||||
]
|
||||
target = [
|
||||
dict(
|
||||
boxes=torch.tensor(
|
||||
[[879, 39, 1513, 766]],
|
||||
),
|
||||
labels=torch.tensor(
|
||||
[1],
|
||||
),
|
||||
)
|
||||
]
|
||||
metric = MeanAveragePrecision()
|
||||
metric.update(preds, target)
|
||||
|
||||
from pprint import pprint
|
||||
|
||||
pprint(metric.compute())
|
||||
|
||||
# --------------------------------------------------------------------------
|
||||
|
||||
preds = [
|
||||
dict(
|
||||
boxes=torch.tensor(
|
||||
[
|
||||
[880.0560, 41.7845, 1500, 700.3355],
|
||||
]
|
||||
),
|
||||
scores=torch.tensor(
|
||||
[0.9989],
|
||||
),
|
||||
labels=torch.tensor(
|
||||
[1],
|
||||
),
|
||||
)
|
||||
]
|
||||
target = [
|
||||
dict(
|
||||
boxes=torch.tensor(
|
||||
[[879, 39, 1513, 766]],
|
||||
),
|
||||
labels=torch.tensor(
|
||||
[1],
|
||||
),
|
||||
)
|
||||
]
|
||||
metric = MeanAveragePrecision()
|
||||
metric.update(preds, target)
|
||||
|
||||
from pprint import pprint
|
||||
|
||||
pprint(metric.compute())
|
Loading…
Reference in a new issue