multithreading - Matlab parallel programming -
first of all, sorry general title and, probably, general question.
i'm facing dilemma, worked in c++ , right i'm trying similar 1 of previous projects, parallelize single-target object tracker written in matlab in order assign each concurrent thread object , gather results @ each frame. in c++, used boost thread api so, , results. possibile in matlab? reading around i'm finding rather unclear, i'm reading lot parfor
loop that's pretty it? can impose synchronization barriers similar boost::barrier
in order stop each thread after each frame , wait other before going next frame?
basically, wish initialize common data structures , launch few parallel instances of tracker, shares data , take different objects track input. suggestion appreciated!
parfor
1 piece of functionality provided parallel computing toolbox. it's simplest, , people find useful, why of resources research has found discuss that.
parfor
gives way parallelize "embarassingly parallel" tasks, in other words tasks independent , not require communication between them (such as, example, parameter sweeps or monte carlo analyses).
it sounds that's not need. question, i'm not entirely sure need; since mention synchronization, barriers, , waiting 1 task finish before moves forward, suggest take @ features of parallel computing toolbox such labsend
, labreceive
, labbarrier
, , spmd
, allow implement more message-passing style of parallelization. there plenty more functionality in toolbox parfor
.
also - don't afraid ask mathworks advice on this, there several (free) recorded webinars , tutorials on sort of parallelization can point towards.
hope helps!
Comments
Post a Comment