Dear Julia users,
I am trying to use Julia's parallel capabilities to do a simple parameter
sweep. I am probably doing something wrong, but top seems to indicate that
half om my julia processes are doing nothing at all:
This is my workflow (not very pro, but it suits my case for now)
I start the julia REPL (in a screen session) with "julia -p 20" (on a
machine with enough = 24 processors)
I then type ' include("run.jl") ' where run.jl contains:
require("project.jl")
Arange=2:2:12
Brange=linspace(0,5,101)
I=length(Arange)
J=length(Brange)
e1=SharedArray(Float64,(I,J))
e2=SharedArray(Float64,(I,J))
@parallel for iter=1:I*J
i,j=ind2sub((I,J),iter)
e=F(Arange[i],Brange[j])
e=sort(abs(e),rev=true)
e1[i,j]=e[1]
e2[i,j]=e[2]
end
and where project.jl loads a number of modules and defines the function F.
As soon as I hit ' include("run.jl") ', all julia processes start doing
something, running at a 100% for a time that could be compatible with
processing a single iteration. But then, about half of them fall back to 0%
CPU, and even some more fall back to 0% later. Am I doing something wrong?
Best regards,
Jutho