Mercurial Hosting > traffic-intelligence
diff scripts/dltrack.py @ 1270:20a5e1292321
added smoothing functions and velocity generation to dltrack
author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
---|---|
date | Mon, 10 Jun 2024 16:44:19 -0400 |
parents | 27b206d118b7 |
children | b2f90cada58f |
line wrap: on
line diff
--- a/scripts/dltrack.py Wed Jun 05 10:12:43 2024 -0400 +++ b/scripts/dltrack.py Mon Jun 10 16:44:19 2024 -0400 @@ -256,7 +256,8 @@ if smoothingHalfWidth is not None: # smoothing for num, obj in objects.items(): for f in obj.getFeatures(): - f.positions = f.getPositions().filterMovingWindow(smoothingHalfWidth) + f.smoothPositions(smoothingHalfWidth, replace = True)#f.positions = f.getPositions().filterMovingWindow(smoothingHalfWidth) + f.computeVelocities() storage.saveTrajectoriesToSqlite(args.databaseFilename, list(objects.values()), 'object')