| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -29,17 +29,21 @@ void read_data(const std::string &filename, Compression *comp, std::vector<doub | |||
| 29 | 29 | file.open(filename); | |
| 30 | 30 | ||
| 31 | 31 | if(file.is_open()) { | |
| 32 | + LOG(">>> DATA_FILE"); | ||
| 32 | 33 | file >> a >> dp >> b >> eps; | |
| 34 | + LOG(a, " ", dp, " ", b, " ", eps); | ||
| 33 | 35 | comp->aPrioriA = a; | |
| 34 | 36 | comp->aPrioridPrime = dp; | |
| 35 | 37 | comp->aPosterioriB = b; | |
| 36 | 38 | file >> nAtoms; | |
| 37 | 39 | for(unsigned int i = 0; i < nAtoms; ++i){ | |
| 38 | 40 | file >> charge >> x >> y >> z; | |
| 41 | + LOG(charge, " ", x," ", y, " ", z); | ||
| 39 | 42 | Eigen::Vector3d position(x,y,z); | |
| 40 | 43 | atoms_->push_back(position); | |
| 41 | 44 | charge_->push_back(charge); | |
| 42 | 45 | } | |
| 46 | + LOG("<<< DATA_FILE"); | ||
| 43 | 47 | } else { | |
| 44 | 48 | throw std::runtime_error("Data file could not be opened"); | |
| 45 | 49 | } | |
@@ -53,7 +57,10 @@ int main(int argc, char* argv[]) { | |||
| 53 | 57 | std::vector<double> charge_; | |
| 54 | 58 | std::vector<Eigen::Vector3d> atoms_; | |
| 55 | 59 | read_data(argv[2], &comp, &charge_, &atoms_); | |
| 56 | - | ||
| 60 | + | ||
| 61 | + LOG(">>> GEOMETRY_FILE"); | ||
| 62 | + LOG(argv[1]); | ||
| 63 | + LOG("<<< GEOMETRY_FILE"); | ||
| 57 | 64 | // Set up cavity, read it from Maharavo's file | |
| 58 | 65 | WaveletCavity cavity(argv[1]); | |
| 59 | 66 | //cavity.scaleCavity(1./convertBohrToAngstrom); | |
@@ -73,6 +80,7 @@ int main(int argc, char* argv[]) { | |||
| 73 | 80 | FILE* debugFile = fopen("debug.out","w"); | |
| 74 | 81 | fclose(debugFile); | |
| 75 | 82 | #endif | |
| 83 | + LOG(">>> PCMSOLVER"); | ||
| 76 | 84 | PWCSolver solver(gfInside, gfOutside, comp, firstKind); | |
| 77 | 85 | solver.buildSystemMatrix(cavity); | |
| 78 | 86 | cavity.uploadPoints(solver.getQuadratureLevel(), solver.getT_()); | |
@@ -102,5 +110,9 @@ int main(int argc, char* argv[]) { | |||
| 102 | 110 | LOG("totalFakeASC = ", totalFakeASC); | |
| 103 | 111 | LOG("Delta = ", totalASC - totalFakeASC); | |
| 104 | 112 | LOG("Energy = ", energy); | |
| 113 | + LOG("<<< PCMSOLVER"); | ||
| 114 | + LOG(">>> TIMING"); | ||
| 105 | 115 | LOG_TIME; | |
| 116 | + LOG("<<< TIMING"); | ||
| 117 | + LOG("# vim: foldmarker=>>>,<<< foldlevel=0 foldmethod=marker"); | ||
| 106 | 118 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -67,7 +67,8 @@ namespace logging | |||
| 67 | 67 | : globalPrintLevel_(print), policy_(new logPolicy) | |
| 68 | 68 | { | |
| 69 | 69 | std::stringstream namestream; | |
| 70 | - namestream << "pcmsolver" << rand(); | ||
| 70 | + srand(time(NULL)); | ||
| 71 | + namestream << "pcmsolver" << "_" << rand() << "_" << getpid(); | ||
| 71 | 72 | std::string nameB = namestream.str(); | |
| 72 | 73 | if(!policy_) { | |
| 73 | 74 | throw std::runtime_error("LOGGER: Unable to create the logger instance"); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments