1 | initial version |
Parallel computations on multiples nodes are effective in Sage provided they have been implemented for the objects you are manipulating. It is not sufficient to set Parallelism().set(nproc=32)
to have it work for any type of computation. For instance, parallelization is effective for computations on differentiable manifolds. Here is an example regarding the computation of the Riemann curvature tensor of the 4-dimensional sphere:
1/ without parallelization:
sage: S4 = manifolds.Sphere(4)
sage: g = S4.metric()
sage: %time g.riemann()
CPU times: user 4.88 s, sys: 47.8 ms, total: 4.92 s
Wall time: 3.89 s
2/ with parallelization on 8 nodes:
sage: Parallelism().set(nproc=8)
sage: S4 = manifolds.Sphere(4)
sage: g = S4.metric()
sage: %time g.riemann()
CPU times: user 491 ms, sys: 158 ms, total: 648 ms
Wall time: 1.59 s
2 | No.2 Revision |
Parallel computations on multiples nodes are effective in Sage provided they have been implemented for the objects you are manipulating. It is not sufficient to set Parallelism().set(nproc=32)
to have it work for any type of computation. For instance, parallelization is effective for computations on differentiable manifolds. Here is an example regarding the computation of the Riemann curvature tensor of the 4-dimensional sphere:
1/ without parallelization:
sage: S4 = manifolds.Sphere(4)
sage: g = S4.metric()
sage: %time g.riemann()
CPU times: user 4.88 s, sys: 47.8 ms, total: 4.92 s
Wall time: 3.89 s
2/ with parallelization on 8 nodes:cores:
sage: Parallelism().set(nproc=8)
sage: S4 = manifolds.Sphere(4)
sage: g = S4.metric()
sage: %time g.riemann()
CPU times: user 491 ms, sys: 158 ms, total: 648 ms
Wall time: 1.59 s