35#ifndef NEKTAR_SPATIALDOMAINS_MGIOHDF5_H
36#define NEKTAR_SPATIALDOMAINS_MGIOHDF5_H
65 const std::string &outfilename,
bool defaultExp =
false,
75 const std::unordered_set<int> &readIds);
81 std::string datasetName);
83 template <
class T,
typename DataType>
86 const std::unordered_set<int> &readIds,
87 std::vector<int> &ids,
88 std::vector<DataType> &geomData);
89 template <
class T,
typename DataType>
90 void FillGeomMap(std::map<
int, std::shared_ptr<T>> &geomMap,
91 const CurveMap &curveMap, std::vector<int> &ids,
92 std::vector<DataType> &geomData);
93 template <
class T,
typename DataType>
98 std::unordered_map<int, int> &id2row);
105 void WriteDomain(std::map<int, CompositeMap> &domain);
#define SPATIAL_DOMAINS_EXPORT
static std::shared_ptr< DataType > AllocateSharedPtr(const Args &...args)
Allocate a shared pointer from the memory pool.
void v_PartitionMesh(LibUtilities::SessionReaderSharedPtr session) final
Partition the mesh.
LibUtilities::H5::GroupSharedPtr m_mesh
LibUtilities::H5::GroupSharedPtr m_maps
void FillGeomMap(std::map< int, std::shared_ptr< T > > &geomMap, const CurveMap &curveMap, std::vector< int > &ids, std::vector< DataType > &geomData)
static std::string cmdSwitch
MeshGraphIOHDF5()=default
void WriteDomain(std::map< int, CompositeMap > &domain)
void WriteGeometryMap(std::map< int, std::shared_ptr< T > > &geomMap, std::string datasetName)
void ConstructGeomObject(std::map< int, std::shared_ptr< T > > &geomMap, int id, DataType *data, CurveSharedPtr curve)
unsigned int m_inFormatVersion
~MeshGraphIOHDF5() override=default
void v_ReadGeometry(LibUtilities::DomainRangeShPtr rng, bool fillGraph) final
static const unsigned int FORMAT_VERSION
Version of the Nektar++ HDF5 geometry format, which is embedded into the main NEKTAR/GEOMETRY group a...
void ReadGeometryData(std::map< int, std::shared_ptr< T > > &geomMap, std::string dataSet, const std::unordered_set< int > &readIds, std::vector< int > &ids, std::vector< DataType > &geomData)
void WriteCurveMap(CurveMap &curves, std::string dsName, MeshCurvedPts &curvedPts, int &ptOffset, int &newIdx)
void v_WriteGeometry(const std::string &outfilename, bool defaultExp=false, const LibUtilities::FieldMetaDataMap &metadata=LibUtilities::NullFieldMetaDataMap) final
void WriteCurvePoints(MeshCurvedPts &curvedPts)
static std::string className
void WriteComposites(CompositeMap &comps)
LibUtilities::H5::FileSharedPtr m_file
void ReadCurveMap(CurveMap &curveMap, std::string dsName, const std::unordered_set< int > &readIds)
LibUtilities::H5::PListSharedPtr m_readPL
static MeshGraphIOSharedPtr create()
CompositeDescriptor CreateCompositeDescriptor()
std::shared_ptr< PList > PListSharedPtr
std::shared_ptr< File > FileSharedPtr
std::shared_ptr< Group > GroupSharedPtr
std::map< std::string, std::string > FieldMetaDataMap
std::shared_ptr< SessionReader > SessionReaderSharedPtr
static FieldMetaDataMap NullFieldMetaDataMap
std::shared_ptr< DomainRange > DomainRangeShPtr
std::shared_ptr< MeshGraphIO > MeshGraphIOSharedPtr
std::map< int, std::pair< LibUtilities::ShapeType, std::vector< int > > > CompositeDescriptor
std::shared_ptr< Curve > CurveSharedPtr
std::unordered_map< int, CurveSharedPtr > CurveMap
std::map< int, CompositeSharedPtr > CompositeMap