comparison scripts/learn-motion-patterns.py @ 922:acb5379c5fd7

corrected
author Nicolas Saunier <nicolas.saunier@polymtl.ca>
date Wed, 05 Jul 2017 18:07:53 -0400
parents 630934595871
children c030f735c594
comparison
equal deleted inserted replaced
921:630934595871 922:acb5379c5fd7
69 69
70 clusterSizes = ml.computeClusterSizes(labels, prototypeIndices, -1) 70 clusterSizes = ml.computeClusterSizes(labels, prototypeIndices, -1)
71 print(clusterSizes) 71 print(clusterSizes)
72 72
73 73
74 prototypes = [moving.Prototype(objects[i].getNum(), args.databaseFilename, prototypeType, clusterSizes[i]) for i in prototypeIndices] 74 prototypes = [moving.Prototype(args.databaseFilename, objects[i].getNum(), prototypeType, clusterSizes[i]) for i in prototypeIndices]
75 if args.outputPrototypeDatabaseFilename is None: 75 if args.outputPrototypeDatabaseFilename is None:
76 outputPrototypeDatabaseFilename = args.databaseFilename 76 outputPrototypeDatabaseFilename = args.databaseFilename
77 else: 77 else:
78 outputPrototypeDatabaseFilename = args.outputPrototypeDatabaseFilename 78 outputPrototypeDatabaseFilename = args.outputPrototypeDatabaseFilename
79 storage.savePrototypesToSqlite(outputPrototypeDatabaseFilename, prototypes) 79 storage.savePrototypesToSqlite(outputPrototypeDatabaseFilename, prototypes)