exanauts / ExaPF.jl

A Power Flow Solver for GPUs in Julia
MIT License
58 stars 5 forks source link

Time to first power flow #157

Open frapac opened 3 years ago

frapac commented 3 years ago

Currently, we are spending almost a minute to solve the first power flow. On Julia 1.6 and my local machine, I get in a fresh Julia session:

julia> include("tmp/launch_powerflow.jl")
 42.329781 seconds (50.81 M allocations: 2.880 GiB, 10.27% gc time)

This is mostly due to type inference issues. On Julia 1.6, fixing the type inferences on ReducedSpaceEvaluator allowed to decrease the first compile time of ExaPF.hessprod! from 3mn to 10s (see #98 ). We should be able to do the same on powerflow, and most functions exposed to the users.

frapac commented 2 years ago

The situation has slightly improved with the refactoring. On my local machine:

fpacaud$~/dev/anl/ExaPF.jl time julia --project fastpf.jl 
#it 0: 8.97956e-01
#it 1: 3.07254e-02
#it 2: 1.12306e-04
#it 3: 1.60348e-09

real    0m21.608s
user    0m21.255s
sys     0m1.537s