On Tue, Mar 1, 2016 at 12:42 AM, Néstor Castillo <[email protected]> wrote:
> Hello all,
>
> I'm timing a parallel function and I get a return value "elapsed time"
> before the whole function is evaluated!! If i print the current t index
> inside the for loop and execute the function with @time disjoint... First I
> get the elapsed time and later I get something like worker 2 101
> worker 3 105
> etc
> so the function has not been completely evaluated but it returned :(
>
> The function is like  this
>
> function disjointComponents(Data::Array, tini=1, tfini=tmax)
>     @parallel for t=tini:tfini
>           stuff();
>           println(t)
>     end
> end

http://julia.readthedocs.org/en/latest/stdlib/parallel/#Base.@sync
http://julia.readthedocs.org/en/latest/stdlib/parallel/#Base.@parallel

>
> Thank you very much in advance,
> Néstor

Reply via email to