-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Hybrid functionals for planewave basis [Draft, WIP] #5940
base: develop
Are you sure you want to change the base?
Feature: Hybrid functionals for planewave basis [Draft, WIP] #5940
Conversation
* run INPUT.Default() in every process in InputParaTest (deepmodeling#3490) Co-authored-by: kirk0830 <[email protected]> * add blas support for FindLAPACK.cmake (deepmodeling#3497) * more unittest of QO: towards orbital selection (deepmodeling#3499) * Fix: fix bug in mulliken charge calculation (deepmodeling#3503) * fix phase * fix case test * Refactor: namespace Conv_Coulomb_Pot_K (deepmodeling#3446) * Refactor: namespace Conv_Coulomb_Pot_K * Refactor: namespace Conv_Coulomb_Pot_K --------- Co-authored-by: wqzhou <[email protected]> * enable the computation of all zeros in one function call (deepmodeling#3449) Co-authored-by: wqzhou <[email protected]> * replace ios.eof() by ios.good() to avoid meeting badbit and failbit in reading STRU (deepmodeling#3506) * Build: add ccache to accelerate the testing process (deepmodeling#3509) * Build: add ccache to accelerate the testing process * Update test.yml * Update test.yml * Update test.yml * Docs: to avoid the misunderstanding in docs (deepmodeling#3518) * to avoid the misunderstanding in docs * Update docs/quick_start/hands_on.md Co-authored-by: Chun Cai <[email protected]> --------- Co-authored-by: Chun Cai <[email protected]> * Docs: fix a missing depencency in conda build env (deepmodeling#3508) * Feature: Add ENABLE_RAPIDJSON option to control the output of abacus.json (deepmodeling#3519) Add ENABLE_RAPIDJSON option to control the output of abacus.json * Feature: add python wrapper for math sphbes (deepmodeling#3475) * recommit for review * add python wrapper * remove timer since performace tests add * Feature: support segment split in kline mode in KPT file and `out_band` band output precision control, `8` as default (deepmodeling#3493) * add precision control * correct serial version of nscf_band function * fix issue 3482 * update unit and integrated test * update document * correct unittest and make compatible with false and true * fix: bug in Autotest.sh when result.ref has no totaltimeref (deepmodeling#3523) * Fix : unit test of module_xc (deepmodeling#3524) * Fix: omit small magnetic moments to avoid numerical instability (deepmodeling#3530) * update deltalambda * avoid numerical error in orbMulP * add constrain on Mi * change case reference value * Fix: fix multiple compiler warnings (deepmodeling#3515) * Fix: add noreturn attribute to warning_quit * Add type conversion * fix string literal * fix small number trunctuation * Fix system call returned value not checked * fix missing braket * Refactor parameter_pool.cpp and parameter_pool.h * remove duplicated return statements * Change WARNING_QUIT occurances in tests * Add warning message to help debug UT * output the default precision flag (deepmodeling#3496) Co-authored-by: kirk0830 <[email protected]> * Build: Improving CMake performance for finding LibXC and ELPA (deepmodeling#3478) * Fix for finding LibXC and ELPA * For compatibility to previous routines * syntax fix for FindELPA.cmake * Update cmake/FindELPA.cmake Co-authored-by: Chun Cai <[email protected]> * Using CMake interface as default for finding LibXC * update docs * fix for FindLibxc: changing imcompatible if statement * fix for FindLibxc: changing imcompatible if statement * fix for FindLibxc: changing imcompatible if statement * update docs for installing pkg-config * Update FindLibxc.cmake * Update FindLibxc.cmake * remove previous LibXC routine in CMakeLists.txt Co-authored-by: Chun Cai <[email protected]> * Update easy_install.md with Makefile-built LibXC supported * Update easy_install.md to include different behavior in different version on finding ELPA --------- Co-authored-by: Chun Cai <[email protected]> * Docs: correct some docs about mp2 smearing method (deepmodeling#3533) * correct some docs about mp2 smearing method * add docs about mv method * Feature : printing band density (deepmodeling#3501) Co-authored-by: wenfei-li <[email protected]> Co-authored-by: wqzhou <[email protected]> * add some docs for PR#3501 (deepmodeling#3537) * Feature: enable restart charge density mixing during SCF (deepmodeling#3542) * add a new parameter mixing_restart * do not update rho if iter==mixing_restart * do not update rho if iter==mixing_restart-1 * reset mix and rho_mdata if iter==mixing_restart * fix SCF exit directly since drho=0 if iter=GlobalV::MIXING_RESTART * re-set_mixing in eachiterinit for PW and LCAO * enable SCF restarts in esolver_ks::RUN * add some UnitTests * add some Docs * new inputs added * Update input-main.md (deepmodeling#3551) Solve the format problem mentioned in issue 3543 * Build: fix compatibility issue against toolchain install (deepmodeling#3540) * Fix for finding LibXC and ELPA * For compatibility to previous routines * syntax fix for FindELPA.cmake * Update cmake/FindELPA.cmake Co-authored-by: Chun Cai <[email protected]> * Using CMake interface as default for finding LibXC * update docs * fix for FindLibxc: changing imcompatible if statement * fix for FindLibxc: changing imcompatible if statement * fix for FindLibxc: changing imcompatible if statement * update docs for installing pkg-config * Update FindLibxc.cmake * Update FindLibxc.cmake * remove previous LibXC routine in CMakeLists.txt Co-authored-by: Chun Cai <[email protected]> * Update easy_install.md with Makefile-built LibXC supported * Update easy_install.md to include different behavior in different version on finding ELPA * fix compatibility issue against toolchain * Change default ELPA install routine to old one --------- Co-authored-by: Chun Cai <[email protected]> * Test: Configure performance tests for math libraries (deepmodeling#3511) * add performace test of sphbes functions. * fix benchmark cmake errors * add dependencies for docker * update docs * add performance tests for sphbes * add google benchmark * rewrite benchmark tests in fixtures * disable internal testing in benchmark * merge benchmark into integration test --------- Co-authored-by: StarGrys <[email protected]> * Configure Makefile Compiling, fix typos * Fix Makefile Intel toolchains compile errors * Fix even more PEXSI related Makefile compiling issues * Update hsolver_pw.cpp (deepmodeling#3556) when use_uspp==false, overlap matrix should be E. * Fix: cuda build target (deepmodeling#3276) * Fix: cuda buid target * Update CMakeLists.txt --------- Co-authored-by: Denghui Lu <[email protected]> --------- Co-authored-by: wqzhou <[email protected]> Co-authored-by: kirk0830 <[email protected]> Co-authored-by: Haozhi Han <[email protected]> Co-authored-by: Zhao Tianqi <[email protected]> Co-authored-by: PeizeLin <[email protected]> Co-authored-by: jinzx10 <[email protected]> Co-authored-by: Chun Cai <[email protected]> Co-authored-by: Peng Xingliang <[email protected]> Co-authored-by: Jie Li <[email protected]> Co-authored-by: Wenfei Li <[email protected]> Co-authored-by: Denghui Lu <[email protected]> Co-authored-by: YI Zeping <[email protected]> Co-authored-by: wenfei-li <[email protected]> Co-authored-by: jingan-181 <[email protected]> Co-authored-by: StarGrys <[email protected]> Co-authored-by: Haozhi Han <[email protected]>
Revert "Modify inputs and update to latest version"
Modify Inputs and Update to Latest
# Conflicts: # .github/workflows/build_test_cmake.yml # source/module_elecstate/module_charge/charge_init.cpp # source/module_esolver/esolver_ks.cpp # source/module_esolver/esolver_ks_pw.cpp # source/module_esolver/esolver_ks_pw.h # source/module_hamilt_general/operator.h # source/module_hamilt_pw/hamilt_pwdft/CMakeLists.txt # source/module_hamilt_pw/hamilt_pwdft/hamilt_pw.cpp # source/module_psi/psi.cpp # source/module_psi/psi.h # source/module_psi/psi_initializer.h
auto *kv = &this_->kv; | ||
|
||
// lambda | ||
auto exx_divergence = [&]() -> double |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the difference between this and OperatorEXXPW<T, Device>::exx_divergence
, and the div calculation in "stress_func_exx.cpp"? Can they merged into one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Completely the same. These classes should share some variables. I'll fix it later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hybrid Functionals for planewave basis is still under development, so plz be patient.
@@ -31,6 +33,61 @@ class ESolver_KS_PW : public ESolver_KS<T, Device> | |||
|
|||
void after_all_runners(UnitCell& ucell) override; | |||
|
|||
#ifdef __EXX |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest the structure be defined in other places, not in esolver_ks_pw.h
@@ -273,6 +297,22 @@ void ESolver_KS_PW<T, Device>::before_scf(UnitCell& ucell, const int istep) | |||
// allocate HamiltPW | |||
this->allocate_hamilt(ucell); | |||
|
|||
#ifdef __EXX |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need #ifdef __EXX?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not really. But some procedures related to hybrid functionals require this marco.
#include "module_esolver/esolver_ks_pw.h" | ||
|
||
template <typename T, typename Device> | ||
double ModuleESolver::ESolver_KS_PW<T, Device>::Exx_Helper::cal_exx_energy(psi::Psi<T, Device>& psi, ESolver_KS_PW<T, Device>* this_) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe the definition of Exx_Helper can be moved to other source directories
Reminder
Any changes of core modules? (ignore if not applicable)