changeset 1229:759d76d6d20c

minor variable name update
author Nicolas Saunier <nicolas.saunier@polymtl.ca>
date Thu, 13 Jul 2023 17:40:37 -0400
parents 5654c9173548
children c582b272108f
files scripts/dltrack.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/dltrack.py	Wed Jul 12 13:21:08 2023 -0400
+++ b/scripts/dltrack.py	Thu Jul 13 17:40:37 2023 -0400
@@ -2,7 +2,7 @@
 # from https://docs.ultralytics.com/modes/track/
 import sys, argparse
 
-from trafficintelligence.moving import cocoUserTypeNames
+from trafficintelligence.moving import cocoTypeNames
 from ultralytics import YOLO
 
 parser = argparse.ArgumentParser(description='The program tracks objects following the ultralytics yolo executable.')#, epilog = 'Either the configuration filename or the other parameters (at least video and database filenames) need to be provided.')
@@ -19,9 +19,9 @@
 
 # Track with the model
 if args.display:
-    results = model.track(source=args.videoFilename, tracker="/home/nicolas/Research/Data/classification-models/bytetrack.yaml", classes=list(cocoUserTypeNames.keys()), show=True) # , save_txt=True 
+    results = model.track(source=args.videoFilename, tracker="/home/nicolas/Research/Data/classification-models/bytetrack.yaml", classes=list(cocoTypeNames.keys()), show=True) # , save_txt=True 
 else:
-    results = model.track(source=args.videoFilename, tracker="/home/nicolas/Research/Data/classification-models/bytetrack.yaml", classes=list(cocoUserTypeNames.keys()), stream=True)
+    results = model.track(source=args.videoFilename, tracker="/home/nicolas/Research/Data/classification-models/bytetrack.yaml", classes=list(cocoTypeNames.keys()), stream=True)
     for result in results:
         for box in result.boxes:
             print(box.xyxy)