From 264a307a8ea44712e5e56a8b471643e516afc117 Mon Sep 17 00:00:00 2001 From: linpz Date: Sat, 4 Oct 2025 02:42:33 +0800 Subject: [PATCH 1/2] Feature: add ABFS_ORBITAL and ABFS_JLES_ORBITAL in Exx_Opt_Orb --- source/source_cell/bcast_cell.cpp | 10 ++- source/source_cell/read_atom_species.cpp | 10 +++ source/source_hamilt/module_xc/exx_info.h | 5 ++ source/source_io/input_conv.cpp | 1 + source/source_io/read_input_item_exx_dftu.cpp | 6 -- source/source_lcao/module_ri/exx_abfs-io.cpp | 30 ++++--- source/source_lcao/module_ri/exx_abfs-jle.cpp | 7 +- .../module_ri/exx_opt_orb-print.cpp | 79 +++++++++---------- source/source_lcao/module_ri/exx_opt_orb.cpp | 51 ++++++++++-- source/source_lcao/module_ri/exx_opt_orb.h | 10 ++- 10 files changed, 135 insertions(+), 74 deletions(-) diff --git a/source/source_cell/bcast_cell.cpp b/source/source_cell/bcast_cell.cpp index bb23fd82fe..2f9b88955a 100644 --- a/source/source_cell/bcast_cell.cpp +++ b/source/source_cell/bcast_cell.cpp @@ -112,8 +112,14 @@ namespace unitcell #ifdef __EXX ModuleBase::bcast_data_cereal(GlobalC::exx_info.info_ri.files_abfs, - MPI_COMM_WORLD, - 0); + MPI_COMM_WORLD, + 0); + ModuleBase::bcast_data_cereal(GlobalC::exx_info.info_opt_abfs.files_abfs, + MPI_COMM_WORLD, + 0); + ModuleBase::bcast_data_cereal(GlobalC::exx_info.info_opt_abfs.files_jles, + MPI_COMM_WORLD, + 0); #endif return; #endif diff --git a/source/source_cell/read_atom_species.cpp b/source/source_cell/read_atom_species.cpp index 54e131e6b3..354d40cf8f 100644 --- a/source/source_cell/read_atom_species.cpp +++ b/source/source_cell/read_atom_species.cpp @@ -112,6 +112,16 @@ bool read_atom_species(std::ifstream& ifa, std::string ofile; ifa >> ofile; GlobalC::exx_info.info_ri.files_abfs.push_back(ofile); + GlobalC::exx_info.info_opt_abfs.files_abfs.push_back(ofile); + } + } + if( ModuleBase::GlobalFunc::SCAN_LINE_BEGIN(ifa, "ABFS_JLES_ORBITAL") ) + { + for(int i=0; i> ofile; + GlobalC::exx_info.info_opt_abfs.files_jles.push_back(ofile); } } } diff --git a/source/source_hamilt/module_xc/exx_info.h b/source/source_hamilt/module_xc/exx_info.h index 91c4652707..fa01daf46b 100644 --- a/source/source_hamilt/module_xc/exx_info.h +++ b/source/source_hamilt/module_xc/exx_info.h @@ -82,6 +82,11 @@ struct Exx_Info int abfs_Lmax = 0; // tmp double ecut_exx = 60; double tolerence = 1E-12; + std::vector files_jles; + + double pca_threshold = 0; + std::vector files_abfs; + double kmesh_times = 4; }; Exx_Info_Opt_ABFs info_opt_abfs; diff --git a/source/source_io/input_conv.cpp b/source/source_io/input_conv.cpp index 952ca873d1..279c09c405 100644 --- a/source/source_io/input_conv.cpp +++ b/source/source_io/input_conv.cpp @@ -473,6 +473,7 @@ void Input_Conv::Convert() GlobalC::exx_info.info_ri.ccp_rmesh_times = std::stod(PARAM.inp.exx_ccp_rmesh_times); GlobalC::exx_info.info_ri.exx_symmetry_realspace = PARAM.inp.exx_symmetry_realspace; + GlobalC::exx_info.info_opt_abfs.pca_threshold = PARAM.inp.exx_pca_threshold; GlobalC::exx_info.info_opt_abfs.abfs_Lmax = PARAM.inp.exx_opt_orb_lmax; GlobalC::exx_info.info_opt_abfs.ecut_exx = PARAM.inp.exx_opt_orb_ecut; GlobalC::exx_info.info_opt_abfs.tolerence = PARAM.inp.exx_opt_orb_tolerence; diff --git a/source/source_io/read_input_item_exx_dftu.cpp b/source/source_io/read_input_item_exx_dftu.cpp index 7f9edc633e..eec98263c1 100644 --- a/source/source_io/read_input_item_exx_dftu.cpp +++ b/source/source_io/read_input_item_exx_dftu.cpp @@ -337,12 +337,6 @@ void ReadInput::item_exx() Input_Item item("exx_opt_orb_lmax"); item.annotation = "the maximum l of the spherical Bessel functions for opt ABFs"; read_sync_int(input.exx_opt_orb_lmax); - item.check_value = [](const Input_Item& item, const Parameter& para) { - if (para.input.exx_opt_orb_lmax < 0) - { - ModuleBase::WARNING_QUIT("ReadInput", "exx_opt_orb_lmax must >= 0"); - } - }; this->add_item(item); } { diff --git a/source/source_lcao/module_ri/exx_abfs-io.cpp b/source/source_lcao/module_ri/exx_abfs-io.cpp index 6e961f3e2f..78184e1c52 100644 --- a/source/source_lcao/module_ri/exx_abfs-io.cpp +++ b/source/source_lcao/module_ri/exx_abfs-io.cpp @@ -36,7 +36,7 @@ std::vector>> Exx_Abfs::IO::constr const double kmesh_times ) { std::vector>> - &&abfs = construct_abfs( orbs, files_abfs, kmesh_times ); + abfs = construct_abfs( orbs, files_abfs, kmesh_times ); assert( abfs.size() == abfs_pre.size() ); for( size_t T=0; T!=abfs.size(); ++T ) @@ -73,7 +73,7 @@ std::vector> Exx_Abfs::IO::construct_abfs_T( std::ifstream ifs( file_name.c_str() ); if(!ifs) - throw std::runtime_error(" Can't find the abfs ORBITAL file."); + throw std::runtime_error(" Can't find the abfs ORBITAL file " + file_name); while( ifs.good() ) { @@ -130,10 +130,22 @@ std::vector> Exx_Abfs::IO::construct_abfs_T( { ModuleBase::GlobalFunc::READ_VALUE( ifs, N_size[8] ); } + else if ( "Lorbital-->"==word ) + { + ModuleBase::GlobalFunc::READ_VALUE( ifs, N_size[9] ); + } + else if ( "Morbital-->"==word ) + { + ModuleBase::GlobalFunc::READ_VALUE( ifs, N_size[10] ); + } + else if ( "Norbital-->"==word ) + { + ModuleBase::GlobalFunc::READ_VALUE( ifs, N_size[11] ); + } else if ( "END"==word ) { break; - } + } } ModuleBase::CHECK_NAME(ifs, "Mesh"); @@ -169,19 +181,11 @@ std::vector> Exx_Abfs::IO::construct_abfs_T( ----------------------*/ for( size_t L=0; L<=L_size; ++L ) if( N_size.find(L) == N_size.end() ) - { - std::stringstream ss; - ss<<"Can't find N of L="<>> Exx_Abfs::Jle::init_jle( @@ -13,15 +14,19 @@ Exx_Abfs::Jle::init_jle( const UnitCell& ucell, const LCAO_Orbitals& orb) { + ModuleBase::TITLE("Exx_Abfs::Jle","init_jle"); std::vector>> jle( ucell.ntype ); for(int T=0; T0) + { jle[T].resize( info.abfs_Lmax+1 ); } for(int L=0; L<=info.abfs_Lmax; ++L) { const size_t ecut_number = static_cast( std::sqrt( info.ecut_exx ) * orb.Phi[T].getRcut() / ModuleBase::PI ); // Rydberg Unit. + if(ecut_number<=0) + { continue; } jle[T][L].resize( ecut_number ); diff --git a/source/source_lcao/module_ri/exx_opt_orb-print.cpp b/source/source_lcao/module_ri/exx_opt_orb-print.cpp index d3d5444ff4..bf19815cfc 100644 --- a/source/source_lcao/module_ri/exx_opt_orb-print.cpp +++ b/source/source_lcao/module_ri/exx_opt_orb-print.cpp @@ -1,18 +1,21 @@ #include "exx_opt_orb.h" #include "../../source_pw/module_pwdft/global.h" #include "exx_abfs-jle.h" +#include "source_base/tool_title.h" #include void Exx_Opt_Orb::print_matrix( const Exx_Info::Exx_Info_Opt_ABFs &info, const UnitCell& ucell, - const K_Vectors &kv, - const std::string& file_name, + const K_Vectors &kv, + const int Lmax, + const std::vector &ecut_number, + const std::string &file_name, const std::vector> &matrix_Q, const std::vector>> &matrix_S, const RI::Tensor &matrix_V, - const size_t TA, const size_t IA, const size_t TB, const size_t IB, - const std::vector& orb_cutoff, + const std::size_t TA, const std::size_t IA, const std::size_t TB, const std::size_t IB, + const std::vector& orb_cutoff, const ModuleBase::Element_Basis_Index::Range &range_jles, const ModuleBase::Element_Basis_Index::IndexLNM &index_jles) const { @@ -61,45 +64,40 @@ void Exx_Opt_Orb::print_matrix( << ucell.atoms[TB].tau[IB].z << std::endl; } - // ecutwfc_jlq determine the jlq corresponding to plane wave calculation. - ofs << info.ecut_exx << " ecutwfc" << std::endl; // mohan add 2009-09-08 + ofs << info.ecut_exx << " ecutwfc" << std::endl; // this parameter determine the total number of jlq. - ofs << info.ecut_exx << " ecutwfc_jlq" << std::endl;//mohan modify 2009-09-08 + ofs << info.ecut_exx << " ecutwfc_jlq" << std::endl; if(TA==TB) { ofs << orb_cutoff[TA] << " rcut_Jlq" << std::endl; } else { ofs << orb_cutoff[TA] << " " << orb_cutoff[TB] << " rcut_Jlq" << std::endl; } - // mohan add 'smooth' and 'smearing_sigma' 2009-08-28 ofs << 0 << " smooth" << std::endl; ofs << 0 << " smearing_sigma" << std::endl; ofs << info.tolerence << " tolerence" << std::endl; - ofs << info.abfs_Lmax << " lmax" << std::endl; + ofs << Lmax << " lmax" << std::endl; ofs << kv.get_nkstot() << " nks" << std::endl; assert( matrix_V.shape[0]*matrix_V.shape[1] == matrix_V.shape[2]*matrix_V.shape[3] ); ofs << matrix_V.shape[0]*matrix_V.shape[1] << " nbands" << std::endl; - auto cal_sum_M = [&range_jles](size_t T) -> size_t + auto cal_sum_M = [&range_jles](std::size_t T) -> std::size_t { - size_t sum_M = 0; - for( size_t L = 0; L!=range_jles[T].size(); ++L ) + std::size_t sum_M = 0; + for( std::size_t L = 0; L!=range_jles[T].size(); ++L ) { sum_M += range_jles[T][L].M; } return sum_M; }; - const size_t nwfc = (TA==TB && IA==IB) ? cal_sum_M(TA) : cal_sum_M(TA)+cal_sum_M(TB); + const std::size_t nwfc = (TA==TB && IA==IB) ? cal_sum_M(TA) : cal_sum_M(TA)+cal_sum_M(TB); ofs << nwfc << " nwfc" << std::endl; - const size_t ecut_numberA = static_cast( std::sqrt( info.ecut_exx ) * orb_cutoff[TA] / ModuleBase::PI ); // Rydberg Unit - const size_t ecut_numberB = static_cast( std::sqrt( info.ecut_exx ) * orb_cutoff[TB] / ModuleBase::PI ); // Rydberg Unit - if(TA==TB) - { ofs << ecut_numberA << " ne" << std::endl; } - else - { ofs << ecut_numberA << " " << ecut_numberB << " ne" << std::endl; } + for(const std::size_t ne : ecut_number) + { ofs << ne << " "; } + ofs << "ne" << std::endl; ofs << "" << std::endl; for( int ik=0; ik!=kv.get_nkstot(); ++ik ) @@ -119,18 +117,18 @@ void Exx_Opt_Orb::print_matrix( // < Psi | jY > //--------------------- ofs<< "" << std::endl; - for( size_t iw0=0; iw0!=matrix_V.shape[0]; ++iw0 ) + for( std::size_t iw0=0; iw0!=matrix_V.shape[0]; ++iw0 ) { - for( size_t iw1=0; iw1!=matrix_V.shape[1]; ++iw1 ) + for( std::size_t iw1=0; iw1!=matrix_V.shape[1]; ++iw1 ) { - for( size_t iat=0; iat!=matrix_Q.size(); ++iat ) + for( std::size_t iat=0; iat!=matrix_Q.size(); ++iat ) { - const size_t it = (iat==0) ? TA : TB; - for( size_t il=0; il!=range_jles[it].size(); ++il ) + const std::size_t it = (iat==0) ? TA : TB; + for( std::size_t il=0; il!=range_jles[it].size(); ++il ) { - for( size_t im=0; im!=range_jles[it][il].M; ++im ) + for( std::size_t im=0; im!=range_jles[it][il].M; ++im ) { - for( size_t iq=0; iq!=range_jles[it][il].N; ++iq ) + for( std::size_t iq=0; iq!=range_jles[it][il].N; ++iq ) { ofs< //--------------------- ofs<< "" < //--------------------- ofs << "" << std::endl; - for( size_t iw0=0; iw0!=matrix_V.shape[0]; ++iw0 ) + for( std::size_t iw0=0; iw0!=matrix_V.shape[0]; ++iw0 ) { - for( size_t iw1=0; iw1!=matrix_V.shape[1]; ++iw1 ) + for( std::size_t iw1=0; iw1!=matrix_V.shape[1]; ++iw1 ) { - for( size_t iw2=0; iw2!=matrix_V.shape[2]; ++iw2 ) + for( std::size_t iw2=0; iw2!=matrix_V.shape[2]; ++iw2 ) { - for( size_t iw3=0; iw3!=matrix_V.shape[3]; ++iw3 ) + for( std::size_t iw3=0; iw3!=matrix_V.shape[3]; ++iw3 ) { ofs<" << std::endl << std::endl; }; + ModuleBase::TITLE("Exx_Opt_Orb","print_matrix"); std::ofstream ofs(file_name+"_"+std::to_string(TA)+"_"+std::to_string(IA)+"_"+std::to_string(TB)+"_"+std::to_string(IB)); print_header(ofs); ofs<>> &orbs) -> bool + { + for(const auto &orb_t : orbs) { + for(const auto &orb_tl : orb_t) { + if(orb_tl.size()>0) { + return false; + }}} + return true; + }; + std::vector>> lcaos = Exx_Abfs::Construct_Orbs::change_orbs( orb, info.kmesh_times ); Exx_Abfs::Construct_Orbs::filter_empty_orbs(lcaos); std::vector>> - abfs = Exx_Abfs::Construct_Orbs::abfs_same_atom(ucell,orb, lcaos, info.kmesh_times, GlobalC::exx_info.info_ri.pca_threshold ); + abfs = Exx_Abfs::Construct_Orbs::abfs_same_atom(ucell,orb, lcaos, info.kmesh_times, info.pca_threshold ); + if(!info.files_abfs.empty()) + { abfs = Exx_Abfs::IO::construct_abfs( abfs, orb, info.files_abfs, info.kmesh_times ); } Exx_Abfs::Construct_Orbs::filter_empty_orbs(abfs); std::vector< std::vector< std::vector< Numerical_Orbital_Lm>>> jle = Exx_Abfs::Jle::init_jle(info, info.kmesh_times, ucell , orb); + if(!info.files_jles.empty()) + { jle = Exx_Abfs::IO::construct_abfs( jle, orb, info.files_jles, info.kmesh_times ); } Exx_Abfs::Construct_Orbs::filter_empty_orbs(jle); - GlobalC::exx_info.info_ri.abfs_Lmax = info.abfs_Lmax; - for( size_t T=0; T!=abfs.size(); ++T ) - { GlobalC::exx_info.info_ri.abfs_Lmax = std::max( GlobalC::exx_info.info_ri.abfs_Lmax, static_cast(abfs[T].size())-1 ); } + // GlobalC::exx_info.info_ri.abfs_Lmax is used for Center2 temporarily + for(const auto &orb_T : abfs) + { GlobalC::exx_info.info_ri.abfs_Lmax = std::max( GlobalC::exx_info.info_ri.abfs_Lmax, static_cast(orb_T.size())-1 ); } + for(const auto &orb_T : jle) + { GlobalC::exx_info.info_ri.abfs_Lmax = std::max( GlobalC::exx_info.info_ri.abfs_Lmax, static_cast(orb_T.size())-1 ); } const ModuleBase::Element_Basis_Index::Range range_lcaos = Exx_Abfs::Abfs_Index::construct_range( lcaos ); const ModuleBase::Element_Basis_Index::IndexLNM index_lcaos = ModuleBase::Element_Basis_Index::construct_index( range_lcaos ); @@ -46,12 +63,14 @@ void Exx_Opt_Orb::generate_matrix( const ModuleBase::Element_Basis_Index::IndexLNM index_jys = ModuleBase::Element_Basis_Index::construct_index( range_jys ); Exx_Abfs::Construct_Orbs::print_orbs_size(ucell, abfs, GlobalV::ofs_running); + Exx_Abfs::Construct_Orbs::print_orbs_size(ucell, jle, GlobalV::ofs_running); const std::map>> radial_R = get_radial_R(ucell); // < lcaos lcaos | lcaos lcaos > const auto ms_lcaoslcaos_lcaoslcaos = [&]() -> std::map>>>> { + if(judge_orbs_empty(lcaos)) { return {}; } Matrix_Orbs22 m_lcaoslcaos_lcaoslcaos; ORB_gaunt_table MGT; int Lmax; @@ -70,6 +89,8 @@ void Exx_Opt_Orb::generate_matrix( // < lcaos lcaos | jys > const auto ms_lcaoslcaos_jys = [&]() -> std::map>>>>> { + if(judge_orbs_empty(lcaos)) { return {}; } + if(judge_orbs_empty(jle)) { return {}; } Matrix_Orbs21 m_jyslcaos_lcaos; ORB_gaunt_table MGT; int Lmax; @@ -88,6 +109,7 @@ void Exx_Opt_Orb::generate_matrix( // < jys | jys > const auto ms_jys_jys = [&]() -> std::map>>>> { + if(judge_orbs_empty(jle)) { return {}; } Matrix_Orbs11 m_jys_jys; ORB_gaunt_table MGT; int Lmax; @@ -106,6 +128,7 @@ void Exx_Opt_Orb::generate_matrix( // < abfs | abfs > const auto ms_abfs_abfs = [&]() -> std::map>>>> { + if(judge_orbs_empty(abfs)) { return {}; } Matrix_Orbs11 m_abfs_abfs; ORB_gaunt_table MGT; int Lmax; @@ -124,6 +147,8 @@ void Exx_Opt_Orb::generate_matrix( // < lcaos lcaos | abfs > const auto ms_lcaoslcaos_abfs = [&]() -> std::map>>>>> { + if(judge_orbs_empty(lcaos)) { return {}; } + if(judge_orbs_empty(abfs)) { return {}; } Matrix_Orbs21 m_abfslcaos_lcaos; ORB_gaunt_table MGT; int Lmax; @@ -142,6 +167,8 @@ void Exx_Opt_Orb::generate_matrix( // < jys | abfs > const auto ms_jys_abfs = [&]() -> std::map>>>> { + if(judge_orbs_empty(jle)) { return {}; } + if(judge_orbs_empty(abfs)) { return {}; } Matrix_Orbs11 m_jys_abfs; ORB_gaunt_table MGT; int Lmax; @@ -168,7 +195,7 @@ void Exx_Opt_Orb::generate_matrix( if( TA==TB && IA==IB ) { const size_t T=TA, I=IA; - if(GlobalC::exx_info.info_ri.pca_threshold<=1) + if(!judge_orbs_empty(abfs)) { // < abfs | abfs >.I const std::vector>> ms_abfs_abfs_I = cal_I( ms_abfs_abfs, T,I,T,I ); @@ -194,11 +221,13 @@ void Exx_Opt_Orb::generate_matrix( info, ucell, kv, + jle.at(T).size()-1, + {jle.at(T).at(0).size()}, PARAM.globalv.global_out_dir+"/matrix-opt-abfs", m_lcaoslcaos_jys_proj, m_jys_jys_proj, m_lcaoslcaos_lcaoslcaos_proj, - TA, IA, TB, IB, + T, I, T, I, orb.cutoffs(), range_jys, index_jys ); } @@ -208,18 +237,20 @@ void Exx_Opt_Orb::generate_matrix( info, ucell, kv, + jle.at(T).size()-1, + {jle.at(T).at(0).size()}, PARAM.globalv.global_out_dir+"/matrix-opt-abfs", ms_lcaoslcaos_jys.at(T).at(I).at(T).at(I), {{ms_jys_jys.at(T).at(I).at(T).at(I)}}, ms_lcaoslcaos_lcaoslcaos.at(T).at(I).at(T).at(I), - TA, IA, TB, IB, + T, I, T, I, orb.cutoffs(), range_jys, index_jys ); } } else { - if(GlobalC::exx_info.info_ri.pca_threshold<=1) + if(!judge_orbs_empty(abfs)) { // < abfs | abfs >.I const std::vector>> ms_abfs_abfs_I = cal_I( ms_abfs_abfs, TA,IA,TB,IB ); @@ -261,6 +292,8 @@ void Exx_Opt_Orb::generate_matrix( info, ucell, kv, + std::max(jle.at(TA).size(), jle.at(TB).size())-1, + {jle.at(TA).at(0).size(), jle.at(TB).at(0).size()}, PARAM.globalv.global_out_dir+"/matrix-opt-abfs", m_lcaoslcaos_jys_proj, m_jys_jys_proj, @@ -275,6 +308,8 @@ void Exx_Opt_Orb::generate_matrix( info, ucell, kv, + std::max(jle.at(TA).size(), jle.at(TB).size())-1, + {jle.at(TA).at(0).size(), jle.at(TB).at(0).size()}, PARAM.globalv.global_out_dir+"/matrix-opt-abfs", ms_lcaoslcaos_jys.at(TA).at(IA).at(TB).at(IB), {{ms_jys_jys.at(TA).at(IA).at(TA).at(IA), ms_jys_jys.at(TA).at(IA).at(TB).at(IB)}, diff --git a/source/source_lcao/module_ri/exx_opt_orb.h b/source/source_lcao/module_ri/exx_opt_orb.h index 7ccaf0854b..f3252877ce 100644 --- a/source/source_lcao/module_ri/exx_opt_orb.h +++ b/source/source_lcao/module_ri/exx_opt_orb.h @@ -39,16 +39,18 @@ class Exx_Opt_Orb const std::vector> & m_left, const std::vector>> & m_middle, const std::vector> & m_right ) const; - void print_matrix( + void print_matrix( const Exx_Info::Exx_Info_Opt_ABFs &info, const UnitCell& ucell, - const K_Vectors &kv, - const std::string& file_name, + const K_Vectors &kv, + const int Lmax, + const std::vector &ecut_number, + const std::string& file_name, const std::vector> &matrix_Q, const std::vector>> &matrix_S, const RI::Tensor &matrix_V, const size_t TA, const size_t IA, const size_t TB, const size_t IB, - const std::vector& orb_cutoff, + const std::vector& orb_cutoff, const ModuleBase::Element_Basis_Index::Range &range_jles, const ModuleBase::Element_Basis_Index::IndexLNM &index_jles) const; std::map>> get_radial_R(const UnitCell& ucell) const; From 1cf1991e90ee1de161729063fe0572fa58a40506 Mon Sep 17 00:00:00 2001 From: linpz Date: Sun, 5 Oct 2025 23:43:01 +0800 Subject: [PATCH 2/2] Fix: delete exx_opt_orb_lmax=-1 unittest --- source/source_io/test_serial/read_input_item_test.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/source/source_io/test_serial/read_input_item_test.cpp b/source/source_io/test_serial/read_input_item_test.cpp index 8e1eaba646..a7770976b0 100644 --- a/source/source_io/test_serial/read_input_item_test.cpp +++ b/source/source_io/test_serial/read_input_item_test.cpp @@ -1403,14 +1403,6 @@ TEST_F(InputTest, Item_test2) output = testing::internal::GetCapturedStdout(); EXPECT_THAT(output, testing::HasSubstr("NOTICE")); } - { // exx_opt_orb_lmax - auto it = find_label("exx_opt_orb_lmax", readinput.input_lists); - param.input.exx_opt_orb_lmax = -1; - testing::internal::CaptureStdout(); - EXPECT_EXIT(it->second.check_value(it->second, param), ::testing::ExitedWithCode(1), ""); - output = testing::internal::GetCapturedStdout(); - EXPECT_THAT(output, testing::HasSubstr("NOTICE")); - } { // exx_opt_orb_ecut auto it = find_label("exx_opt_orb_ecut", readinput.input_lists); param.input.exx_opt_orb_ecut = -1;