CHROMA
two_flavor_ratio_conv_conv_multihasen_monomial_params_w.cc
Go to the documentation of this file.
1 /*! @file
2  * @brief Two-flavor RatioConvConv monomial params
3  */
4 
6 #include "io/param_io.h"
7 
8 namespace Chroma
9 {
10  // Read the parameters
13  // Get the top of the parameter XML tree
14  XMLReader paramtop(xml_in, path);
15  try{
16  read(paramtop, "Action", fermactInv);
17  read(paramtop, "ShiftedMass", mu);
18  read(paramtop, "NumofHasenTerms", numHasenTerms);
19  if(paramtop.count("./ChronologicalPredictor") == 0){
20  predictor.xml = "";
21  }else{
22  predictor = readXMLGroup(paramtop, "ChronologicalPredictor", "Name");
23  }
24  }catch(const std::string& s){
25  QDPIO::cerr<<"Caught Exception while reading parameters: "<<s<<std::endl;
26  QDP_abort(1);
27  }
28  }
29 
30  //! Read Parameters
31  void read(XMLReader& xml, const std::string& path,
34  params = tmp;
35  }
36 
37  //! Write Parameters
38  void write(XMLWriter& xml, const std::string& path,
40  write(xml, "Action", params.fermactInv);
41  write(xml, "ShiftedMass", params.mu);
42  write(xml, "NumofHasenTerms", params.numHasenTerms);
43  }
44 
45 }// end namespace Chroma
void read(XMLReader &xml, const std::string &path, AsqtadFermActParams &param)
Read parameters.
void write(XMLWriter &xml, const std::string &path, const AsqtadFermActParams &param)
Writer parameters.
GroupXML_t readXMLGroup(XMLReader &xml_in, const std::string &path, const std::string &type_name)
Read group and return as a std::string.
Params params
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
LatticeFermion tmp
Definition: mespbg5p_w.cc:36
multi1d< LatticeFermion > s(Ncb)
::std::string string
Definition: gtest.h:1979
Various parameter structs and reader/writers.
Two-flavor RatioConvConv monomial params.