changeset 1218:1f0b1fc172f8

adding COCO person and vehicle types
author Nicolas Saunier <nicolas.saunier@polymtl.ca>
date Sat, 17 Jun 2023 08:48:22 -0400
parents 5038c357b57f
children 8a626226793e
files trafficintelligence/moving.py
diffstat 1 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/trafficintelligence/moving.py	Tue May 16 22:12:39 2023 -0400
+++ b/trafficintelligence/moving.py	Sat Jun 17 08:48:22 2023 -0400
@@ -1358,11 +1358,20 @@
                  'car',
                  'pedestrian',
                  'motorcycle',
-                 'bicycle',
+                 'cyclist',
                  'bus',
                  'truck',
                  'automated']
 
+coco2UserTypes = {1: 2, 2: 4, 3: 1, 6: 5, 8: 6}
+cocoUserTypeNames = {1: person,
+                     2: bicycle,
+	             3:	car,
+                     4: motorcycle,
+                     6: bus,
+                     7: train,
+                     8: truck}
+
 userType2Num = utils.inverseEnumeration(userTypeNames)
 
 class CarClassifier: