Commit 2acfc28c authored by Dave Moxey's avatar Dave Moxey
Browse files

Merge branch 'master' into 'ticket/54-isocontour3DH1D'

# Conflicts:
#   CHANGELOG.md
parents 7334c7fc 1eda9fd3
......@@ -30,10 +30,12 @@ v4.4.1
- Fix Hdf5 output in FilterFieldConvert (!781)
- Fixed extreme memory consumption of Interpolator when interpolating from pts
to fld or between different meshes (!783)
- Fix deadlock with HDF5 input (!786)
**FieldConvert:**
- Fix issue with field ordering in the interppointdatatofld module (!754)
- Fix issue with FieldConvert when range flag used (!761)
- Fix issue when using output-points combined with noequispaced (!775)
- Fix equispacedoutput for 3DH1D with triangles (!787)
**NekMesh**:
......
......@@ -353,7 +353,7 @@ void InputXml::Process(po::variables_map &vm)
}
// reset expansion defintion to use equispaced points if required.
if (m_requireEquiSpaced || vm.count("output-points"))
if (m_requireEquiSpaced)
{
int nPointsNew = 0;
......
......@@ -864,6 +864,7 @@ void FieldIOHdf5::v_Import(const std::string &infilename,
// Set properties for parallel file access (if we're in parallel)
H5::PListSharedPtr parallelProps = H5::PList::Default();
H5::PListSharedPtr readPL = H5::PList::Default();
H5::PListSharedPtr readPLInd = H5::PList::Default();
if (nRanks > 1)
{
......@@ -873,6 +874,8 @@ void FieldIOHdf5::v_Import(const std::string &infilename,
// Use collective IO
readPL = H5::PList::DatasetXfer();
readPL->SetDxMpioCollective();
readPLInd = H5::PList::DatasetXfer();
readPLInd->SetDxMpioIndependent();
}
DataSourceSharedPtr dataSource = H5DataSource::create(
......@@ -1012,8 +1015,9 @@ void FieldIOHdf5::v_Import(const std::string &infilename,
map<uint64_t, set<uint64_t> >::iterator gIt;
for (gIt = groupsToDecomps.begin(); gIt != groupsToDecomps.end(); ++gIt)
{
// Select region from dataset for this decomposition.
set<uint64_t>::iterator sIt;
// Select region from dataset for this decomposition.
for (sIt = gIt->second.begin(); sIt != gIt->second.end(); ++sIt)
{
std::stringstream fieldNameStream;
......@@ -1021,7 +1025,7 @@ void FieldIOHdf5::v_Import(const std::string &infilename,
FieldDefinitionsSharedPtr fielddef =
MemoryManager<FieldDefinitions>::AllocateSharedPtr();
ImportFieldDef(readPL, root, decomps, *sIt, decompsToOffsets[*sIt],
ImportFieldDef(readPLInd, root, decomps, *sIt, decompsToOffsets[*sIt],
fieldNameStream.str(), fielddef);
fielddef->m_elementIDs = groupsToElmts[*sIt];
......@@ -1031,7 +1035,7 @@ void FieldIOHdf5::v_Import(const std::string &infilename,
{
std::vector<NekDouble> decompFieldData;
ImportFieldData(
readPL, data_dset, data_fspace,
readPLInd, data_dset, data_fspace,
decompsToOffsets[*sIt].data, decomps, *sIt, fielddef,
decompFieldData);
fielddata.push_back(decompFieldData);
......@@ -1276,7 +1280,6 @@ void FieldIOHdf5::ImportFieldData(
data_fspace->SelectRange(data_i, nFieldVals);
data_dset->Read(fielddata, data_fspace, readPL);
int datasize = CheckFieldDefinition(fielddef);
ASSERTL0(
fielddata.size() == datasize * fielddef->m_fields.size(),
......
......@@ -76,6 +76,7 @@ namespace H5
0); \
}
class Error : public std::exception
{
};
......@@ -474,12 +475,9 @@ public:
DataTypeSharedPtr mem_t = DataTypeTraits<T>::GetType();
DataSpaceSharedPtr memspace = DataSpace::OneD(data.size());
H5Dwrite(m_Id,
mem_t->GetId(),
memspace->GetId(),
filespace->GetId(),
dxpl->GetId(),
&data[0]);
H5_CALL(H5Dwrite,
(m_Id, mem_t->GetId(), memspace->GetId(), filespace->GetId(),
dxpl->GetId(), &data[0]) );
}
template <class T> void Read(std::vector<T> &data)
{
......@@ -508,12 +506,8 @@ public:
data.resize(len);
DataSpaceSharedPtr memspace = DataSpace::OneD(len);
H5Dread(m_Id,
mem_t->GetId(),
memspace->GetId(),
filespace->GetId(),
dxpl->GetId(),
&data[0]);
H5_CALL(H5Dread, (m_Id, mem_t->GetId(), memspace->GetId(),
filespace->GetId(), dxpl->GetId(), &data[0]));
}
private:
......
......@@ -160,6 +160,7 @@ IF( NEKTAR_SOLVER_INCNAVIERSTOKES )
ADD_NEKTAR_TEST_LENGTHY(Tet_channel_m8_petsc_sc_par)
ENDIF (NEKTAR_USE_PETSC)
IF (NEKTAR_USE_HDF5)
ADD_NEKTAR_TEST(TriQuadChannelHdf5)
ADD_NEKTAR_TEST(Tet_channel_m8_hdf)
ADD_NEKTAR_TEST(KovaFlow_3DH1D_P5_20modes_MVM_hdf5)
ENDIF (NEKTAR_USE_HDF5)
......
<?xml version="1.0" encoding="utf-8"?>
<test>
<description>Tri and Quad element channel Flow 2D reading hdf5 (3 proc) </description>
<executable>IncNavierStokesSolver</executable>
<parameters>TriQuadChannelHdf5.xml</parameters>
<processes>3</processes>
<files>
<file description="Session File">TriQuadChannelHdf5.xml</file>
<file description="Restart File">TriQuadChannelHdf5.rst</file>
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">6.53397e-14</value>
<value variable="v" tolerance="1e-12">2.89187e-15</value>
<value variable="p" tolerance="2.3e-10">2.26904e-10</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">5.31797e-14</value>
<value variable="v" tolerance="1e-12">4.82522e-15</value>
<value variable="p" tolerance="1.1e-10">1.00154e-10</value>
</metric>
</metrics>
</test>
This diff is collapsed.
......@@ -54,9 +54,9 @@ int main(int argc, char* argv[])
("modules-list,l",
"Print the list of available modules.")
("output-points,n", po::value<int>(),
"Output at n equipspaced points along the collapsed coordinates (for .dat, .vtk).")
"Output at n points along the collapsed coordinates (for .dat, .vtu).")
("output-points-hom-z", po::value<int>(),
"Number of planes in the z-direction for output of Homogeneous 1D expansion(for .dat, .vtk).")
"Number of planes in the z-direction for output of Homogeneous 1D expansion(for .dat, .vtu).")
("error,e",
"Write error of fields for regression checking")
("forceoutput,f",
......@@ -64,7 +64,7 @@ int main(int argc, char* argv[])
("range,r", po::value<string>(),
"Define output range i.e. (-r xmin,xmax,ymin,ymax,zmin,zmax) "
"in which any vertex is contained.")
("noequispaced","Do not use equispaced output. Currently stops the output-points option")
("noequispaced","Do not use equispaced output.")
("nprocs", po::value<int>(),
"Used to define nprocs if running serial problem to mimic "
"parallel run.")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment