There was a very similar question asked on StackExchange. You might be
interested in the answers there.
http://mathematica.stackexchange.com/questions/1548/monitor-doesnt-work-with-paralleltable
Here's a slightly modified version of Leonid's solution:
SetSharedVariable[progress]
progress = 0;
Monitor[
ParallelTable[progress++; Pause[0.5]; i, {i, 100}],
progress
]
The caveat here is that SetSharedVariable causes 'progress' to be always
evaluated on the main kernel. Accessing the main kernel is expensive
(it takes a long time). So this only makes sense if:
- it is reasonable to break the parallel evaluation into the smallest
possible pieces (equivalent of Method -> "FinestGrained")
- each single evaluation in your ParallelDo takes considerably longer
than the overhead due to the callback to the main kernel
Otherwise doing this will kill performance. Personally I do not
recommend doing this unless you are experienced with parallelization in
Mathematica and understand what factors affect performance.
Do check my link for more complex but also more efficient variations on
the same idea (Eli Lansey's answer).
Szabolcs