大家好!
使用julia中发现@threads后的for循环如果需要调用python程序,Julia会崩溃。如下是一个简单例子。请各位大佬给一个解决方案!多谢!
using Base.Threads
using PyCall
const itg = pyimport(“scipy.integrate”)
function test()
@threads for i in 1:10
println(i)
temp=itg.quad(exp,0,i)
end
end
test()