how to save fields in a structure for all iterations from a processed video
Show older comments
Hi there, I am using the multiObjectTracking nested function in Matlab( http://www.mathworks.co.uk/help/vision/examples/motion-based-multiple-object-tracking.html ). Here is my code for saving all the tracks and their number of frames:
keep_tracks_ids= zeros(1,max(ids));
keep_tracks_framecount=zeros(1,max(ids));
for i=1:size(ids)
keep_tracks_ids=[keep_tracks_ids step(reliableTracks.id)]
keep_tracks_framecount=[keep_tracks_framecount step(reliableTracks.totalVisibleCount)]
end
save('keep_tracks_ids.mat','keep_tracks_ids');
save('keep_tracks_framecount.mat' ,'keep_tracks_framecount');
I get the following errors: Error using step (line 85) Not enough input arguments.
Error in ..."keep_tracks_ids=[keep_tracks_ids step(reliableTracks.id)]" Please what can I do? Without the for loop, I get the identity of the last track and its number of frames. So the main code is working. My coding for saving is not. Thanks for any help.
Answers (0)
Categories
Find more on Video Formats and Interfaces in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!