Mercurial Hosting > traffic-intelligence
changeset 175:a234a5e818f3
using single view for frame_numbers and getting max trajectory length
author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
---|---|
date | Wed, 26 Oct 2011 19:09:50 -0400 |
parents | ec9734015d53 |
children | 9323427aa0a3 |
files | c/feature-based-tracking.cpp |
diffstat | 1 files changed, 6 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/c/feature-based-tracking.cpp Wed Oct 26 17:46:11 2011 -0400 +++ b/c/feature-based-tracking.cpp Wed Oct 26 19:09:50 2011 -0400 @@ -263,8 +263,11 @@ // c_end = std::clock(); // cout << "Loaded " << trajectories.size() << " trajectories one by one in " << 1000.0 * (c_end-c_start) / CLOCKS_PER_SEC << " CPU seconds" << endl; - trajectoryDB->createViewInstants("first"); - trajectoryDB->createViewInstants("last"); + trajectoryDB->createViewInstants(); + //trajectoryDB->createViewInstants("last"); + int maxTrajectoryLength; + trajectoryDB->maxTrajectoryLength(maxTrajectoryLength); + cout << "max trajectory length " << maxTrajectoryLength << endl; // main loop // TODO version que l'on peut interrompre ? @@ -277,7 +280,7 @@ //cout << trajectoryId << " " << endl; boost::shared_ptr<Trajectory<cv::Point2f> > trajectory; success = trajectoryDB->read(trajectory, trajectoryId, "positions"); // velocities - stringstream ss;ss << *trajectory; cout << ss.str() << endl; + //stringstream ss;ss << *trajectory; cout << ss.str() << endl; } // should the trajectory be loaded one by one? yes