Comments (3)
using OrdinaryDiffEq, DiffEqGPU, CuArrays, LinearAlgebra
CuArrays.device!(0)
function lorenz(du,u,p,t)
@inbounds begin
du[1] = p[1]*(u[2]-u[1])
du[2] = u[1]*(p[2]-u[3]) - u[2]
du[3] = u[1]*u[2] - p[3]*u[3]
end
nothing
end
u0 = Float32[1.0;0.0;0.0]
tspan = (0.0f0,100.0f0)
p = (10.0f0,28.0f0,8/3f0)
prob = ODEProblem(lorenz,u0,tspan,p)
prob_func = (prob,i,repeat) -> remake(prob,p=rand(Float32,3).*p)
monteprob = EnsembleProblem(prob, prob_func = prob_func)
@time sol = solve(monteprob,Tsit5(),EnsembleGPUArray(),trajectories=100_000,batch_size=50_000,saveat=1.0f0)
is 2.5 seconds,
using OrdinaryDiffEq, DiffEqGPU, CuArrays, LinearAlgebra
CuArrays.device!(1)
function lorenz(du,u,p,t)
@inbounds begin
du[1] = p[1]*(u[2]-u[1])
du[2] = u[1]*(p[2]-u[3]) - u[2]
du[3] = u[1]*u[2] - p[3]*u[3]
end
nothing
end
u0 = Float32[1.0;0.0;0.0]
tspan = (0.0f0,100.0f0)
p = (10.0f0,28.0f0,8/3f0)
prob = ODEProblem(lorenz,u0,tspan,p)
prob_func = (prob,i,repeat) -> remake(prob,p=rand(Float32,3).*p)
monteprob = EnsembleProblem(prob, prob_func = prob_func)
@time sol = solve(monteprob,Tsit5(),EnsembleGPUArray(),trajectories=100_000,batch_size=50_000,saveat=1.0f0)
is 3 seconds, but multi-GPU is 94 seconds on master! Trying to figure it out, we added
which was sufficient to send the figure down to 1.5 seconds, making multi-GPU the fastest. However, this is clearly not the ideal strategy.
from diffeqgpu.jl.
Fixed with yield()
90d10d0
from diffeqgpu.jl.
Turns out that only happened when the return was broken...
from diffeqgpu.jl.
Related Issues (20)
- Support for ODE with Matrix-Vector multiplication HOT 5
- Recent benchmarks of Kernelized GPU ODE solvers with MPGOS HOT 30
- Stiff-ODEs with numerical Jacobian HOT 1
- ContinuousCallback does not work correctly with EnsembleGPUArray() HOT 8
- `terminate!` callback support HOT 1
- Just wonder how faster DiffEqGPU.jl is compared to DifferentialEquations.jl HOT 1
- Add a section to the manual on how to use the lower level API for lower overhead
- Out of dynamic GPU memory in EnsembleGPUKernel for higher number of threads
- Out of Dynamic GPU memory in EnsembleGPUKernel for higher number of threads when using ContinuousCallback HOT 6
- `EnsembleGPUKernel `+ Texture Memory Support HOT 20
- codecov not running
- Performance example Parameter-Parallelism with GPU Ensemble Methods HOT 3
- Example in docs fails HOT 5
- GPU locks up at full usage with EnsembleGPUKernel on tspan ensemble study HOT 2
- Support non-array parameter types HOT 1
- Problem with EnsembleGPUArray() when updating library HOT 4
- Add a tutorial example for usage with MPI
- EnsembleGPUArray() incompatibility with SecondOrderODEProblem() HOT 2
- Python support for DiffEqGPU HOT 4
- `EnsembleGPUArray` compatibility with different time intervals
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from diffeqgpu.jl.