Skip to content

Commit 8528f51

Browse files
1041176461jiyuangQianruipkuESROAMERmaki49
authored
Refactor: new ccp param framework (#6350)
* Use template to reconstruct parse_expression * Feature: output R matrix at each MD step * Modify'matrix_HS' to 'matrix' for R matrix output * Merge branches 'develop' and 'develop' of https://github.com/1041176461/abacus-develop into develop * Fix: modify index in parse_expression * Fix: add regfree for parse_expression * Doc: update phonopy doc * Doc: update phonopy doc * fix tdos plot for nspin=2 * optimize dosplot for nspin=2 * fix legend for dosplot * Add files via upload * Update cal_edm_tddft.cpp * Refactor: modify exx loop for relax/md * Update result.ref * Fix wrong parameters in integrate test * Update result.ref * Update result.ref * Update result.ref * Update result.ref * Update result.ref * Update result.ref * Update result.ref * Update result.ref * add exx when istep>0 * Update dos.py * Update esolver_sdft_pw.cpp * Update lcao_before_scf.cpp * Update Exx_LRI_interface.h * Update Exx_LRI_interface.hpp * Fix: compile error * Fix: compile error * Fix: change HSE relax/md result.ref for new framework * Fix: compile error * compatible with exx_iter_finish * Add files via upload * Update esolver_ks_lcao_tddft.h * Update esolver_ks_lcao_tddft.cpp * Fix: support negative value in parse_expression * [pre-commit.ci lite] apply automatic fixes * Fix: parse_expression for scientific notation * Update input_conv.h * add complex erf function * refactor ccp framework * fix compile * fix compile * fix compile * fix compile * fix compile * fix compile * fix compile * fix empty error --------- Co-authored-by: jiyuang <jiyuyang@mail.ustc.com> Co-authored-by: Qianrui <76200646+Qianruipku@users.noreply.github.com> Co-authored-by: HTZhao <104255052+ESROAMER@users.noreply.github.com> Co-authored-by: maki49 <1579492865@qq.com> Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
1 parent 174f31f commit 8528f51

File tree

11 files changed

+772
-385
lines changed

11 files changed

+772
-385
lines changed

source/source_hamilt/module_xc/exx_info.h

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,10 @@ struct Exx_Info
5151

5252
struct Exx_Info_RI
5353
{
54-
const std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>> &coulomb_param;
55-
54+
std::map<Conv_Coulomb_Pot_K::Coulomb_Method,
55+
std::pair<bool,
56+
std::map<Conv_Coulomb_Pot_K::Coulomb_Type,
57+
std::vector<std::map<std::string,std::string>>>>> coulomb_settings;
5658

5759
bool real_number = false;
5860

@@ -70,15 +72,10 @@ struct Exx_Info
7072
double kmesh_times = 4;
7173

7274
int abfs_Lmax = 0; // tmp
73-
74-
Exx_Info_RI(const Exx_Info::Exx_Info_Global& info_global)
75-
: coulomb_param(info_global.coulomb_param)
76-
{
77-
}
7875
};
7976
Exx_Info_RI info_ri;
8077

81-
Exx_Info() : info_lip(this->info_global), info_ri(this->info_global)
78+
Exx_Info() : info_lip(this->info_global)
8279
{
8380
}
8481
};

source/source_io/input_conv.cpp

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -352,13 +352,15 @@ void Input_Conv::Convert()
352352
{
353353
if(PARAM.inp.basis_type == "lcao")
354354
{
355-
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock].resize(fock_alpha.size());
355+
std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>> coulomb_param;
356+
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock].resize(fock_alpha.size());
356357
for(std::size_t i=0; i<fock_alpha.size(); ++i)
357358
{
358-
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock][i] = {{
359+
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock][i] = {{
359360
{"alpha", ModuleBase::GlobalFunc::TO_STRING(fock_alpha[i])},
360361
{"Rcut_type", "spencer"} }};
361362
}
363+
GlobalC::exx_info.info_ri.coulomb_settings[Conv_Coulomb_Pot_K::Coulomb_Method::Center2] = std::make_pair(true, coulomb_param);
362364
}
363365
else if(PARAM.inp.basis_type == "lcao_in_pw")
364366
{
@@ -388,13 +390,18 @@ void Input_Conv::Convert()
388390
if(!erfc_alpha.empty())
389391
{
390392
assert(erfc_alpha.size() == PARAM.inp.exx_erfc_omega.size());
391-
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc].resize(erfc_alpha.size());
392-
for(std::size_t i=0; i<erfc_alpha.size(); ++i)
393+
if(PARAM.inp.basis_type == "lcao")
393394
{
394-
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc] = {{
395-
{"alpha", ModuleBase::GlobalFunc::TO_STRING(erfc_alpha[i])},
396-
{"omega", ModuleBase::GlobalFunc::TO_STRING(PARAM.inp.exx_erfc_omega[i])},
397-
{"Rcut_type", "limits"} }};
395+
std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>> coulomb_param;
396+
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc].resize(erfc_alpha.size());
397+
for(std::size_t i=0; i<erfc_alpha.size(); ++i)
398+
{
399+
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc] = {{
400+
{"alpha", ModuleBase::GlobalFunc::TO_STRING(erfc_alpha[i])},
401+
{"omega", ModuleBase::GlobalFunc::TO_STRING(PARAM.inp.exx_erfc_omega[i])},
402+
{"Rcut_type", "limits"} }};
403+
}
404+
GlobalC::exx_info.info_ri.coulomb_settings[Conv_Coulomb_Pot_K::Coulomb_Method::Center2] = std::make_pair(true, coulomb_param);
398405
}
399406
}
400407
}

source/source_lcao/module_ri/Exx_LRI.h

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,15 @@
3737
class OperatorLREXX;
3838
}
3939

40+
template<typename Tdata>
41+
class Exx_Obj
42+
{
43+
// match with Conv_Coulomb_Pot_K::Coulomb_Method
44+
public:
45+
LRI_CV<Tdata> cv;
46+
std::vector<std::vector<std::vector<Numerical_Orbital_Lm>>> abfs_ccp;
47+
};
48+
4049
template<typename Tdata>
4150
class Exx_LRI
4251
{
@@ -85,9 +94,9 @@ class Exx_LRI
8594

8695
std::vector<std::vector<std::vector<Numerical_Orbital_Lm>>> lcaos;
8796
std::vector<std::vector<std::vector<Numerical_Orbital_Lm>>> abfs;
88-
std::vector<std::vector<std::vector<Numerical_Orbital_Lm>>> abfs_ccp;
89-
90-
LRI_CV<Tdata> cv;
97+
//std::vector<std::vector<std::vector<Numerical_Orbital_Lm>>> abfs_ccp;
98+
std::map<Conv_Coulomb_Pot_K::Coulomb_Method, Exx_Obj<Tdata>> exx_objs;
99+
//LRI_CV<Tdata> cv;
91100
RI::Exx<TA,Tcell,Ndim,Tdata> exx_lri;
92101

93102
void post_process_Hexx( std::map<TA, std::map<TAC, RI::Tensor<Tdata>>> &Hexxs_io ) const;

source/source_lcao/module_ri/Exx_LRI.hpp

Lines changed: 63 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -48,19 +48,18 @@ void Exx_LRI<Tdata>::init(const MPI_Comm &mpi_comm_in,
4848
{ this->abfs = Exx_Abfs::IO::construct_abfs( abfs_same_atom, orb, this->info.files_abfs, this->info.kmesh_times ); }
4949
Exx_Abfs::Construct_Orbs::print_orbs_size(ucell, this->abfs, GlobalV::ofs_running);
5050

51-
const std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>>
52-
53-
coulomb_param_updated = RI_Util::update_coulomb_param(this->info.coulomb_param, ucell.omega, this->p_kv->get_nkstot_full());
54-
this->abfs_ccp = Conv_Coulomb_Pot_K::cal_orbs_ccp(this->abfs, coulomb_param_updated, this->info.ccp_rmesh_times);
55-
5651
for( size_t T=0; T!=this->abfs.size(); ++T )
5752
{ GlobalC::exx_info.info_ri.abfs_Lmax = std::max( GlobalC::exx_info.info_ri.abfs_Lmax, static_cast<int>(this->abfs[T].size())-1 ); }
5853

59-
this->cv.set_orbitals(
60-
ucell,
61-
orb,
62-
this->lcaos, this->abfs, this->abfs_ccp,
63-
this->info.kmesh_times, this->info.ccp_rmesh_times );
54+
for(const auto &settings_list : this->info.coulomb_settings)
55+
{
56+
const std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>>
57+
coulomb_param_updated = RI_Util::update_coulomb_param(settings_list.second.second, ucell.omega, this->p_kv->get_nkstot_full());
58+
this->exx_objs[settings_list.first].abfs_ccp = Conv_Coulomb_Pot_K::cal_orbs_ccp(this->abfs, coulomb_param_updated, this->info.ccp_rmesh_times);
59+
this->exx_objs[settings_list.first].cv.set_orbitals(ucell, orb,
60+
this->lcaos, this->abfs, this->exx_objs[settings_list.first].abfs_ccp,
61+
this->info.kmesh_times, this->info.ccp_rmesh_times );
62+
}
6463

6564
ModuleBase::timer::tick("Exx_LRI", "init");
6665
}
@@ -96,26 +95,39 @@ void Exx_LRI<Tdata>::cal_exx_ions(const UnitCell& ucell,
9695
const std::pair<std::vector<TA>, std::vector<std::vector<std::pair<TA,std::array<Tcell,Ndim>>>>>
9796
list_As_Vs = RI::Distribute_Equally::distribute_atoms_periods(this->mpi_comm, atoms, period_Vs, 2, false);
9897

99-
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>
100-
Vs = this->cv.cal_Vs(ucell,
101-
list_As_Vs.first, list_As_Vs.second[0],
102-
{{"writable_Vws",true}});
103-
this->cv.Vws = LRI_CV_Tools::get_CVws(ucell,Vs);
98+
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>> Vs;
99+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, Ndim>>> dVs;
100+
for(const auto &settings_list : this->info.coulomb_settings)
101+
{
102+
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>
103+
Vs_temp = this->exx_objs[settings_list.first].cv.cal_Vs(ucell,
104+
list_As_Vs.first, list_As_Vs.second[0],
105+
{{"writable_Vws",true}});
106+
this->exx_objs[settings_list.first].cv.Vws = LRI_CV_Tools::get_CVws(ucell,Vs_temp);
107+
Vs = Vs.empty() ? Vs_temp : LRI_CV_Tools::add(Vs, Vs_temp);
108+
109+
if(PARAM.inp.cal_force || PARAM.inp.cal_stress)
110+
{
111+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, Ndim>>>
112+
dVs_temp = this->exx_objs[settings_list.first].cv.cal_dVs(ucell,
113+
list_As_Vs.first, list_As_Vs.second[0],
114+
{{"writable_dVws",true}});
115+
this->exx_objs[settings_list.first].cv.dVws = LRI_CV_Tools::get_dCVws(ucell,dVs_temp);
116+
dVs = dVs.empty() ? dVs_temp : LRI_CV_Tools::add(dVs, dVs_temp);
117+
}
118+
}
104119
if (write_cv && GlobalV::MY_RANK == 0)
105120
{ LRI_CV_Tools::write_Vs_abf(Vs, PARAM.globalv.global_out_dir + "Vs"); }
106121
this->exx_lri.set_Vs(std::move(Vs), this->info.V_threshold);
107122

108123
if(PARAM.inp.cal_force || PARAM.inp.cal_stress)
109124
{
110-
std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>
111-
dVs = this->cv.cal_dVs(ucell,
112-
list_As_Vs.first, list_As_Vs.second[0],
113-
{{"writable_dVws",true}});
114-
this->cv.dVws = LRI_CV_Tools::get_dCVws(ucell,dVs);
115-
this->exx_lri.set_dVs(std::move(dVs), this->info.V_grad_threshold);
125+
std::array<std::map<TA, std::map<TAC, RI::Tensor<Tdata>>>, Ndim>
126+
dVs_order = LRI_CV_Tools::change_order(std::move(dVs));
127+
this->exx_lri.set_dVs(std::move(dVs_order), this->info.V_grad_threshold);
116128
if(PARAM.inp.cal_stress)
117129
{
118-
std::array<std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>,3> dVRs = LRI_CV_Tools::cal_dMRs(ucell,dVs);
130+
std::array<std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>,3> dVRs = LRI_CV_Tools::cal_dMRs(ucell,dVs_order);
119131
this->exx_lri.set_dVRs(std::move(dVRs), this->info.V_grad_R_threshold);
120132
}
121133
}
@@ -124,26 +136,43 @@ void Exx_LRI<Tdata>::cal_exx_ions(const UnitCell& ucell,
124136
const std::pair<std::vector<TA>, std::vector<std::vector<std::pair<TA,std::array<Tcell,Ndim>>>>>
125137
list_As_Cs = RI::Distribute_Equally::distribute_atoms_periods(this->mpi_comm, atoms, period_Cs, 2, false);
126138

127-
std::pair<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>, std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>>
128-
Cs_dCs = this->cv.cal_Cs_dCs(
129-
ucell,
130-
list_As_Cs.first, list_As_Cs.second[0],
131-
{{"cal_dC",PARAM.inp.cal_force||PARAM.inp.cal_stress},
132-
{"writable_Cws",true}, {"writable_dCws",true}, {"writable_Vws",false}, {"writable_dVws",false}});
133-
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>> &Cs = std::get<0>(Cs_dCs);
134-
this->cv.Cws = LRI_CV_Tools::get_CVws(ucell,Cs);
139+
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>> Cs;
140+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>> dCs;
141+
for(const auto &settings_list : this->info.coulomb_settings)
142+
{
143+
if(settings_list.second.first)
144+
{
145+
std::pair<std::map<TA, std::map<TAC, RI::Tensor<Tdata>>>,
146+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>>>
147+
Cs_dCs = this->exx_objs[settings_list.first].cv.cal_Cs_dCs(
148+
ucell,
149+
list_As_Cs.first, list_As_Cs.second[0],
150+
{{"cal_dC",PARAM.inp.cal_force||PARAM.inp.cal_stress},
151+
{"writable_Cws",true}, {"writable_dCws",true}, {"writable_Vws",false}, {"writable_dVws",false}});
152+
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>> &Cs_temp = std::get<0>(Cs_dCs);
153+
this->exx_objs[settings_list.first].cv.Cws = LRI_CV_Tools::get_CVws(ucell,Cs_temp);
154+
Cs = Cs.empty() ? Cs_temp : LRI_CV_Tools::add(Cs, Cs_temp);
155+
156+
if(PARAM.inp.cal_force || PARAM.inp.cal_stress)
157+
{
158+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>> &dCs_temp = std::get<1>(Cs_dCs);
159+
this->exx_objs[settings_list.first].cv.dCws = LRI_CV_Tools::get_dCVws(ucell,dCs_temp);
160+
dCs = dCs.empty() ? dCs_temp : LRI_CV_Tools::add(dCs, dCs_temp);
161+
}
162+
}
163+
}
135164
if (write_cv && GlobalV::MY_RANK == 0)
136165
{ LRI_CV_Tools::write_Cs_ao(Cs, PARAM.globalv.global_out_dir + "Cs"); }
137166
this->exx_lri.set_Cs(std::move(Cs), this->info.C_threshold);
138167

139168
if(PARAM.inp.cal_force || PARAM.inp.cal_stress)
140169
{
141-
std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3> &dCs = std::get<1>(Cs_dCs);
142-
this->cv.dCws = LRI_CV_Tools::get_dCVws(ucell,dCs);
143-
this->exx_lri.set_dCs(std::move(dCs), this->info.C_grad_threshold);
170+
std::array<std::map<TA, std::map<TAC, RI::Tensor<Tdata>>>, Ndim>
171+
dCs_order = LRI_CV_Tools::change_order(std::move(dCs));
172+
this->exx_lri.set_dCs(std::move(dCs_order), this->info.C_grad_threshold);
144173
if(PARAM.inp.cal_stress)
145174
{
146-
std::array<std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>,3> dCRs = LRI_CV_Tools::cal_dMRs(ucell,dCs);
175+
std::array<std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>,3> dCRs = LRI_CV_Tools::cal_dMRs(ucell,dCs_order);
147176
this->exx_lri.set_dCRs(std::move(dCRs), this->info.C_grad_R_threshold);
148177
}
149178
}

source/source_lcao/module_ri/LRI_CV.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,14 @@ class LRI_CV
4747
const std::vector<TA> &list_A0,
4848
const std::vector<TAC> &list_A1,
4949
const std::map<std::string,bool> &flags); // "writable_Vws"
50-
inline std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>
50+
inline std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>>
5151
cal_dVs(
5252
const UnitCell &ucell,
5353
const std::vector<TA> &list_A0,
5454
const std::vector<TAC> &list_A1,
5555
const std::map<std::string,bool> &flags); // "writable_dVws"
56-
std::pair<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,
57-
std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>>
56+
std::pair<std::map<TA, std::map<TAC, RI::Tensor<Tdata>>>,
57+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>>>
5858
cal_Cs_dCs(
5959
const UnitCell &ucell,
6060
const std::vector<TA> &list_A0,

source/source_lcao/module_ri/LRI_CV.hpp

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -146,15 +146,14 @@ auto LRI_CV<Tdata>::cal_dVs(
146146
const std::vector<TA> &list_A0,
147147
const std::vector<TAC> &list_A1,
148148
const std::map<std::string,bool> &flags) // + "writable_dVws"
149-
-> std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>
149+
-> std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>>
150150
{
151151
ModuleBase::TITLE("LRI_CV","cal_dVs");
152152
const T_func_DPcal_data<std::array<RI::Tensor<Tdata>,3>>
153153
func_DPcal_dV = std::bind(
154154
&LRI_CV<Tdata>::DPcal_dV, this,
155155
std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4);
156-
return LRI_CV_Tools::change_order(
157-
this->cal_datas(ucell,list_A0, list_A1, flags, this->ccp_rmesh_times, func_DPcal_dV));
156+
return this->cal_datas(ucell,list_A0, list_A1, flags, this->ccp_rmesh_times, func_DPcal_dV);
158157
}
159158

160159
template<typename Tdata>
@@ -163,7 +162,9 @@ auto LRI_CV<Tdata>::cal_Cs_dCs(
163162
const std::vector<TA> &list_A0,
164163
const std::vector<TAC> &list_A1,
165164
const std::map<std::string,bool> &flags) // "cal_dC" + "writable_Cws", "writable_dCws", "writable_Vws", "writable_dVws"
166-
-> std::pair<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>, std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3>>
165+
-> std::pair<
166+
std::map<TA, std::map<TAC, RI::Tensor<Tdata>>>,
167+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>>>
167168
{
168169
ModuleBase::TITLE("LRI_CV","cal_Cs_dCs");
169170
const T_func_DPcal_data<std::pair<RI::Tensor<Tdata>, std::array<RI::Tensor<Tdata>,3>>>
@@ -173,16 +174,16 @@ auto LRI_CV<Tdata>::cal_Cs_dCs(
173174
std::map<TA,std::map<TAC, std::pair<RI::Tensor<Tdata>, std::array<RI::Tensor<Tdata>,3>>>>
174175
Cs_dCs_tmp = this->cal_datas(ucell,list_A0, list_A1, flags, std::min(1.0,this->ccp_rmesh_times), func_DPcal_C_dC);
175176

176-
std::map<TA,std::map<TAC,RI::Tensor<Tdata>>> Cs;
177-
std::array<std::map<TA,std::map<TAC,RI::Tensor<Tdata>>>,3> dCs;
178-
for(auto &Cs_dCs_A : Cs_dCs_tmp)
179-
for(auto &Cs_dCs_B : Cs_dCs_A.second)
180-
{
181-
Cs[Cs_dCs_A.first][Cs_dCs_B.first] = std::move(std::get<0>(Cs_dCs_B.second));
182-
if(flags.at("cal_dC"))
183-
for(int ix=0; ix<3; ++ix)
184-
dCs[ix][Cs_dCs_A.first][Cs_dCs_B.first] = std::move(std::get<1>(Cs_dCs_B.second)[ix]);
185-
}
177+
std::map<TA, std::map<TAC, RI::Tensor<Tdata>>> Cs;
178+
std::map<TA, std::map<TAC, std::array<RI::Tensor<Tdata>, 3>>> dCs;
179+
for (auto& Cs_dCs_A: Cs_dCs_tmp)
180+
for (auto& Cs_dCs_B: Cs_dCs_A.second) {
181+
Cs[Cs_dCs_A.first][Cs_dCs_B.first]
182+
= std::move(std::get<0>(Cs_dCs_B.second));
183+
if (flags.at("cal_dC"))
184+
dCs[Cs_dCs_A.first][Cs_dCs_B.first]
185+
= std::move(std::get<1>(Cs_dCs_B.second));
186+
}
186187
return std::make_pair(Cs, dCs);
187188
}
188189

0 commit comments

Comments
 (0)