Skip to content

Commit

Permalink
Perf: change default pw_seed=0 (#5179)
Browse files Browse the repository at this point in the history
* change default pw_seed=0

* fix pw_seed=1 in some cases

* avoid multi-definition of pw_seed in INPUT

* fix pw_seed=1 in GPU test
  • Loading branch information
WHUweiqingzhou authored Sep 27, 2024
1 parent 7014205 commit 22964f0
Show file tree
Hide file tree
Showing 28 changed files with 55 additions and 1 deletion.
2 changes: 1 addition & 1 deletion source/module_parameter/input_parameter.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ struct Input_para
bool diago_full_acc = false; ///< all the empty states are diagonalized
std::string init_wfc = "atomic"; ///< "file","atomic","random"
bool psi_initializer = false; ///< whether use psi_initializer to initialize wavefunctions
int pw_seed = 1; ///< random seed for initializing wave functions qianrui 2021-8-12
int pw_seed = 0; ///< random seed for initializing wave functions
std::string init_chg = "atomic"; ///< "file","atomic"
bool dm_to_rho = false; ///< read density matrix from npz format and calculate charge density
std::string chg_extrap = "default"; ///< xiaohui modify 2015-02-01
Expand Down
2 changes: 2 additions & 0 deletions tests/integrate/101_PW_15_pseudopots_LibxcLDA/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@ dft_functional XC_LDA_X+XC_LDA_C_PZ

cal_force 1
cal_stress 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/101_PW_GTH_CF_CS_Si/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,5 @@ mixing_beta 0.7
mixing_gg0 1.5
pseudo_dir ../../PP_ORB


pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/101_PW_lps6_pseudopots/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ dft_functional pbe
#Parameters (5.Mixing)
mixing_type broyden
mixing_beta 0.7

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/101_PW_upf100_Rappe_Fe/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,5 @@ mixing_gg0 1.0

cal_force 1
cal_stress 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/101_PW_upf100_uspp_Fe/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,5 @@ pseudo_rcut 10

cal_force 1
cal_stress 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/101_PW_upf201_uspp_Fe/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,5 @@ cal_force 1
cal_stress 1

kpar 3

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/102_PW_BPCG_GPU/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,5 @@ cal_stress 1
mixing_type broyden
mixing_beta 0.4
mixing_gg0 1.5

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/103_PW_15_CS_CF/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ cal_stress 1
mixing_type broyden
mixing_beta 0.4
mixing_gg0 1.5

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/103_PW_15_CS_CF_bspline/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,5 @@ mixing_type broyden
mixing_beta 0.4
mixing_gg0 1.5
nbspline 20

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/103_PW_OU_CS_CF/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,5 @@ cal_stress 1
mixing_type broyden
mixing_beta 0.4
mixing_gg0 1.5

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/104_PW_FM_magnetic/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,5 @@ basis_type pw
symmetry 1
pseudo_dir ../../PP_ORB
orbital_dir ../../PP_ORB

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/107_PW_OB_outputbands/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ smearing_sigma 0.002
mixing_type plain
mixing_beta 0.7


pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/107_PW_W90/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@ symmetry 0
towannier90 1
nnkpfile diamond.nnkp
read_file_dir ./

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/107_PW_outWfcPw/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ scf_nmax 100
basis_type pw

out_wfc_pw 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/107_PW_outWfcR/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ scf_nmax 100
basis_type pw

out_wfc_r 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/110_PW_SY/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ dft_functional XC_GGA_X_PBE+XC_GGA_C_PBE

cal_force 1
cal_stress 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/112_PW_dipole/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,5 @@ efield_pos_dec 0.1
efield_amp 0.01
cal_force 1
cal_stress 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/112_PW_efield/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,5 @@ efield_flag 1
dip_cor_flag 0
cal_force 1
cal_stress 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/113_PW_gatefield/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,5 @@ cal_stress 1
gate_flag 1
zgate 0.2
nelec 7

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/114_PW_BD_15/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,5 @@ smearing_sigma 0.002
mixing_type broyden
mixing_beta 0.7


pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/115_PW_sol_H2O/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,5 @@ eb_k 80
tau 0.000010798
sigma_k 0.6
nc_k 0.00037

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/116_PW_scan_Si2/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@ cal_force 1
cal_stress 1

mixing_tau 1

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/118_PW_CHG_BINARY/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ cal_stress 1

init_chg auto
read_file_dir .

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/120_PW_KP_MD_MSST/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,5 @@ init_vel 1

msst_qmass 1
msst_vel 10

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/127_PW_15_PK_AF/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ symmetry 0
nspin 2
pseudo_dir ../../PP_ORB
orbital_dir ../../PP_ORB

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/140_PW_15_SO/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,5 @@ pw_diag_thr 0.00001
mixing_type broyden
mixing_beta 0.4
mixing_gg0 1.5

pw_seed 1
2 changes: 2 additions & 0 deletions tests/integrate/801_PW_LT_sc/INPUT
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ scf_thr 1e-10

cal_force 1
cal_stress 1

pw_seed 1

0 comments on commit 22964f0

Please sign in to comment.