I have a question regarding the speed of epwwrite step of EPW.
My workflow, starting from the point, where wannierisation is finished is the following:
-calculate kmaps separately
-calculate epmatw* files
-reuse epmatw* files for all futher (selfens, nesting function…) calculations.
My inputs are the following:
[url:3h730nl9]https://paper.dropbox.com/doc/EPW-epwwrite-minimal-setup-I0KKTtMQhuQuGtz5GMuhw?_tk=share_copylink[/url:3h730nl9]
I run epw like that (through slurm and all):
[code:3h730nl9]mpirun.sh -np 16 $QE/bin/epw.x -npool 16 < epw_init.in > epw_init.out[/code:3h730nl9]
On a single node with 16 cores.
So:
epwwrite is a major bottleneck for me, depending on the parameters this step lasts for days, if not weeks. I would be quite happy to speed it up.
What can be done for that?
I can think of a couple of options:
-set etf_mem = 0
will it work on this step?
-use more nodes
I doubt it will work, since we need npools=ncores, but maybe something has changed?
The calculation of the epmatwp can indeed be a bottleneck.
Possible solution to speed things up:
use etf_mem = 0: This should speed things up [u:13s8tuai]a little bit[/u:13s8tuai] but is usually very memory demanding. In most cases you will
not have enough memory on your nodes.
use more nodes: Use the maximum number of nodes possible. The limit is set by your total number of k-points in the coarse grid.
If you have a 4x4x4 coarse k-point grid, then you can use 64 cores:
[code:13s8tuai]
mpirun.sh -np 64 $QE/bin/epw.x -npool 64 < epw_init.in > epw_init.out[/code:13s8tuai]
If you have a lot of nodes, there is another option. You can use parallelization on bands via the "image parallelization". To do this, you can look into
EPW/tests/Inputs/t01
[code:13s8tuai]
mpirun -np 4 ../../../../bin/pw.x < scf_epw.in > scf_epw.out
mpirun -np 2 ../../../../bin/pw.x -npool 2 < nscf_epw.in > nscf_epw.out
mpirun -np 4 ../../../src/epw.x -npool 2 -nimage 2 < epw5.in > epw5.out[/code:13s8tuai]
The calculation of the epmatwp can indeed be a bottleneck.
Possible solution to speed things up:
use etf_mem = 0: This should speed things up [u:1og9vcmd]a little bit[/u:1og9vcmd] but is usually very memory demanding. In most cases you will
not have enough memory on your nodes.
use more nodes: Use the maximum number of nodes possible. The limit is set by your total number of k-points in the coarse grid.
If you have a 4x4x4 coarse k-point grid, then you can use 64 cores:
[code:1og9vcmd]
mpirun.sh -np 64 $QE/bin/epw.x -npool 64 < epw_init.in > epw_init.out[/code:1og9vcmd]
If you have a lot of nodes, there is another option. You can use parallelization on bands via the "image parallelization". To do this, you can look into
EPW/tests/Inputs/t01
[code:1og9vcmd]
mpirun -np 4 ../../../../bin/pw.x < scf_epw.in > scf_epw.out
mpirun -np 2 ../../../../bin/pw.x -npool 2 < nscf_epw.in > nscf_epw.out
mpirun -np 4 ../../../src/epw.x -npool 2 -nimage 2 < epw5.in > epw5.out[/code:1og9vcmd]
Best,
Samuel[/quote:1og9vcmd]
Dear Samuel,
thank you for the advice!
I had an impression, that
[code:1og9vcmd]
kmaps = .false.
epwwrite = .true.
[/code:1og9vcmd]
are pool dependent (np and npool should be strictly) same as scf and nscf runs. Well if it is not,
I am quite happy:)
[quote:1og9vcmd]etf_mem = 0[/quote:1og9vcmd]
allowed me to advance a few steps (same time_limit) if compared to [b:1og9vcmd]etf_mem = 1[/b:1og9vcmd] (default), I have some high_mem nodes
among the available resources, which I use anyway, thus I will apply it.