1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-04-09 21:50:45 +01:00

Hadrons: A2A matrix IO fix

This commit is contained in:
Antonin Portelli 2018-09-02 01:46:22 +01:00
parent 26cee605b8
commit 6f09df0daf
2 changed files with 5 additions and 5 deletions

View File

@ -80,10 +80,10 @@ void A2AMatrixIo<T, MetadataType>::initFile(const MetadataType &d)
} }
// create the dataset // create the dataset
Hdf5Writer writer(filename_); Hdf5Reader reader(filename_);
push(writer, dataname_); push(reader, dataname_);
auto &group = writer.getGroup(); auto &group = reader.getGroup();
plist.setChunk(chunk.size(), chunk.data()); plist.setChunk(chunk.size(), chunk.data());
dataset = group.createDataSet("data", Hdf5Type<T>::type(), dataspace, plist); dataset = group.createDataSet("data", Hdf5Type<T>::type(), dataspace, plist);
#else #else

View File

@ -102,7 +102,7 @@ private:
// IO // IO
std::string ioname(unsigned int m, unsigned int g) const; std::string ioname(unsigned int m, unsigned int g) const;
std::string filename(unsigned int m, unsigned int g) const; std::string filename(unsigned int m, unsigned int g) const;
void saveBlock(MF_IO_TYPE *data, IoHelper &h, unsigned int i, unsigned int j); void saveBlock(const MF_IO_TYPE *data, IoHelper &h, unsigned int i, unsigned int j);
private: private:
bool hasPhase_{false}; bool hasPhase_{false};
std::string momphName_; std::string momphName_;
@ -416,7 +416,7 @@ std::string TA2AMesonField<FImpl>::filename(unsigned int m, unsigned int g) cons
} }
template <typename FImpl> template <typename FImpl>
void TA2AMesonField<FImpl>::saveBlock(MF_IO_TYPE *data, IoHelper &h, void TA2AMesonField<FImpl>::saveBlock(const MF_IO_TYPE *data, IoHelper &h,
unsigned int i, unsigned int j) unsigned int i, unsigned int j)
{ {
if ((i == 0) and (j == 0)) if ((i == 0) and (j == 0))