From 2ba19a9e07fb948d473552a424276f4511e4e9b8 Mon Sep 17 00:00:00 2001 From: Antonin Portelli Date: Mon, 19 Nov 2018 16:17:51 +0000 Subject: [PATCH] Hadrons: contractor IO fix --- Hadrons/Utilities/Contractor.cc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Hadrons/Utilities/Contractor.cc b/Hadrons/Utilities/Contractor.cc index 2bed6bf5..302eedc7 100644 --- a/Hadrons/Utilities/Contractor.cc +++ b/Hadrons/Utilities/Contractor.cc @@ -124,13 +124,14 @@ void makeTimeSeq(std::vector> &timeSeq, void saveCorrelator(const Contractor::CorrelatorResult &result, const std::string dir, const unsigned int dt, const unsigned int traj) { - std::string fileStem = "", us = "_", filename; + std::string fileStem = "", filename; + std::vector terms = strToVec(result.contraction.terms); - for (unsigned int i = 0; i < result.contraction.terms.size() - 1; i++) + for (unsigned int i = 0; i < terms.size() - 1; i++) { - fileStem += result.contraction.terms[i] + us + std::to_string(result.times[i]) + us; + fileStem += terms[i] + "_" + std::to_string(result.times[i]) + "_"; } - fileStem += result.contraction.terms.back(); + fileStem += terms.back(); if (!result.contraction.translationAverage) { fileStem += "_dt_" + std::to_string(dt);