Write MOAB HDF5 file in parallel. More...
#include <WriteHDF5Parallel.hpp>
Classes | |
struct | DataSetCreator |
Argument ot create_dataset. More... | |
struct | NoopDescCreator |
Public Member Functions | |
WriteHDF5Parallel (Interface *iface) | |
virtual | ~WriteHDF5Parallel () |
Public Member Functions inherited from moab::WriteHDF5 | |
WriteHDF5 (Interface *iface) | |
virtual | ~WriteHDF5 () |
ErrorCode | write_file (const char *filename, const bool overwrite, const FileOptions &opts, const EntityHandle *export_sets, const int export_set_count, const std::vector< std::string > &qa_records, const Tag *tag_list=NULL, int num_tags=0, int user_dimension=3) |
mhdf_FileHandle | file_ptr () |
WriteUtilIface * | write_util () |
ErrorCode | create_elem_table (const ExportSet &block, long num_ents, long &first_id_out) |
ErrorCode | create_set_meta (long num_sets, long &first_id_out) |
Public Member Functions inherited from moab::WriterIface | |
virtual | ~WriterIface () |
Static Public Member Functions | |
static WriterIface * | factory (Interface *) |
Static Public Member Functions inherited from moab::WriteHDF5 | |
static WriterIface * | factory (Interface *) |
Protected Member Functions | |
virtual void | debug_barrier_line (int lineno) |
virtual void | print_times (const double *times) const |
virtual ErrorCode | parallel_create_file (const char *filename, bool overwrite, const std::vector< std::string > &qa_records, const FileOptions &opts, const Tag *user_tag_list=0, int user_tag_count=0, int dimension=3, double *times=0) |
Called by normal (non-parallel) writer. Sets up necessary data for parallel write. More... | |
ErrorCode | gather_interface_meshes (Range &non_local_ents) |
Figure out which mesh local mesh is duplicated on remote processors and which processor will write that mesh. More... | |
ErrorCode | exchange_file_ids (const Range &non_local_ents) |
For entities that will be written by another processor but are referenced by entities on this processor, get the file Ids that will be assigned to those so they can be referenced by entities to be written on this processor. More... | |
ErrorCode | communicate_shared_set_ids (const Range &owned, const Range &remote) |
Get remote ids for shared sets. More... | |
ErrorCode | pack_set (Range::const_iterator set, unsigned long *set_data, size_t set_data_length) |
Pack set data for communication. More... | |
ErrorCode | unpack_set (EntityHandle set, const unsigned long *set_data, size_t set_data_length) |
Unpack set data from communication. More... | |
ErrorCode | communicate_shared_set_data (const Range &owned, const Range &remote) |
Communicate set contents between processors such that each owner knows the contents, parents, & child lists from all processors that have a copy of the set. More... | |
ErrorCode | create_node_table (int dimension) |
Create the node table in the file. More... | |
ErrorCode | negotiate_type_list () |
Communicate with other processors to negotiate the types of elements that will be written (the union of the types defined on each proc.) More... | |
ErrorCode | create_element_tables () |
Create tables to hold element connectivity. More... | |
ErrorCode | create_adjacency_tables () |
Create tables to hold element adjacencies. More... | |
ErrorCode | create_meshset_tables (double *times) |
Create tables for mesh sets. More... | |
ErrorCode | create_tag_tables () |
Write tag descriptions and create tables to hold tag data. More... | |
void | remove_remote_entities (EntityHandle relative, Range &range) |
Remove any remote mesh entities from the passed range. More... | |
void | remove_remote_entities (EntityHandle relative, std::vector< EntityHandle > &vect) |
void | remove_remote_sets (EntityHandle relative, Range &range) |
void | remove_remote_sets (EntityHandle relative, std::vector< EntityHandle > &vect) |
ErrorCode | get_sharedset_tags () |
get any existing tags which aren't excluded and add to shared set tags More... | |
ErrorCode | append_serial_tag_data (std::vector< unsigned char > &buffer, const WriteHDF5::TagDesc &tag) |
ErrorCode | check_serial_tag_data (const std::vector< unsigned char > &buffer, std::vector< TagDesc * > *missing=0, std::vector< TagDesc * > *newlist=0) |
helper function for create_tag_tables More... | |
ErrorCode | create_dataset (int num_datasets, const long *num_owned_entities, long *offsets_out, long *max_proc_ents_out, long *total_ents_out, const DataSetCreator &creator=NoopDescCreator(), ExportSet *groups[]=0, wid_t *first_ids_out=NULL) |
Do typical communication for dataset creation. More... | |
void | print_shared_sets () |
void | print_set_sharing_data (const Range &range, const char *label, Tag idt) |
Protected Member Functions inherited from moab::WriteHDF5 | |
virtual ErrorCode | write_finished () |
ErrorCode | gather_tags (const Tag *user_tag_list, int user_tag_list_length) |
Gather tags. More... | |
bool | check_dense_format_tag (const ExportSet &ents, const Range &all_tagged, bool prefer_dense) |
ErrorCode | count_adjacencies (const Range &elements, wid_t &result) |
ErrorCode | count_set_size (const Range &sets, long &contents_length_out, long &children_length_out, long &parents_length_out) |
ErrorCode | get_set_info (EntityHandle set, long &num_entities, long &num_children, long &num_parents, unsigned long &flags) |
Get information about a meshset. More... | |
ErrorCode | create_set_tables (long contents_length, long children_length, long parents_length) |
ErrorCode | write_qa (const std::vector< std::string > &list) |
Write exodus-type QA info. More... | |
ErrorCode | get_num_sparse_tagged_entities (const TagDesc &tag, size_t &count) |
Get tagged entities for which to write tag values. More... | |
ErrorCode | get_sparse_tagged_entities (const TagDesc &tag, Range &range) |
Get tagged entities for which to write tag values. More... | |
void | get_write_entities (Range &range) |
Get entities that will be written to file. More... | |
const ExportSet * | find (const ExportType &type) const |
const SpecialSetData * | find_set_data (EntityHandle h) const |
SpecialSetData * | find_set_data (EntityHandle h) |
void | print_id_map () const |
void | print_id_map (std::ostream &str, const char *prefix="") const |
ErrorCode | create_tag (const TagDesc &tag_data, unsigned long num_entities, unsigned long var_len_total) |
ErrorCode | assign_ids (const Range &entities, wid_t first_id) |
add entities to idMap More... | |
ErrorCode | range_to_blocked_list (const Range &input_range, std::vector< wid_t > &output_id_list, bool &ranged_list) |
ErrorCode | range_to_blocked_list (const EntityHandle *input_ranges, size_t num_input_ranges, std::vector< wid_t > &output_id_list, bool &ranged_list) |
ErrorCode | range_to_id_list (const Range &input_range, wid_t *array) |
ErrorCode | vector_to_id_list (const std::vector< EntityHandle > &input, std::vector< wid_t > &output, bool remove_non_written=false) |
Get IDs for entities. More... | |
ErrorCode | vector_to_id_list (const EntityHandle *input, wid_t *output, size_t num_entities) |
Get IDs for entities. More... | |
ErrorCode | vector_to_id_list (const EntityHandle *input, size_t input_len, wid_t *output, size_t &output_len, bool remove_non_written) |
Get IDs for entities. More... | |
bool | convert_handle_tag (EntityHandle *data, size_t count) const |
bool | convert_handle_tag (const EntityHandle *source, EntityHandle *dest, size_t count) const |
ErrorCode | get_adjacencies (EntityHandle entity, std::vector< wid_t > &adj) |
ErrorCode | get_tag_data_length (const TagDesc &tag_info, const Range &range, unsigned long &result) |
get sum of lengths of tag values (as number of type) for variable length tag data. More... | |
virtual void | print_times (const double times[NUM_TIMES]) const |
Private Attributes | |
ParallelComm * | myPcomm |
pcomm controlling parallel nature of mesh More... | |
bool | pcommAllocated |
whether this instance allocated (and dtor should delete) the pcomm More... | |
H5S_seloper_t | hslabOp |
Operation to use to append hyperslab selections. More... | |
Additional Inherited Members | |
Public Types inherited from moab::WriteHDF5 | |
typedef EntityHandle | wid_t |
Static Public Attributes inherited from moab::WriteHDF5 | |
static const hid_t | id_type = get_id_type() |
Protected Types inherited from moab::WriteHDF5 | |
enum | TimingValues { TOTAL_TIME = 0 , GATHER_TIME , CREATE_TIME , CREATE_NODE_TIME , NEGOTIATE_TYPES_TIME , CREATE_ELEM_TIME , FILEID_EXCHANGE_TIME , CREATE_ADJ_TIME , CREATE_SET_TIME , SHARED_SET_IDS , SHARED_SET_CONTENTS , SET_OFFSET_TIME , CREATE_TAG_TIME , COORD_TIME , CONN_TIME , SET_TIME , SET_META , SET_CONTENT , SET_PARENT , SET_CHILD , ADJ_TIME , TAG_TIME , DENSE_TAG_TIME , SPARSE_TAG_TIME , VARLEN_TAG_TIME , NUM_TIMES } |
Protected Attributes inherited from moab::WriteHDF5 | |
HDF5ErrorHandler | errorHandler |
Store old HDF5 error handling function. More... | |
size_t | bufferSize |
The size of the data buffer (dataBuffer ). More... | |
char * | dataBuffer |
A memory buffer to use for all I/O operations. More... | |
Interface * | iFace |
Interface pointer passed to constructor. More... | |
WriteUtilIface * | writeUtil |
Cached pointer to writeUtil interface. More... | |
mhdf_FileHandle | filePtr |
The file handle from the mhdf library. More... | |
RangeMap< EntityHandle, wid_t > | idMap |
Map from entity handles to file IDs. More... | |
std::list< ExportSet > | exportList |
The list elements to export. More... | |
ExportSet | nodeSet |
The list of nodes to export. More... | |
ExportSet | setSet |
The list of sets to export. More... | |
unsigned long | setContentsOffset |
Offset into set contents table (zero except for parallel) More... | |
unsigned long | setChildrenOffset |
Offset into set children table (zero except for parallel) More... | |
unsigned long | setParentsOffset |
long | maxNumSetContents |
The largest number of values to write for any processor (needed to do collective IO). More... | |
long | maxNumSetChildren |
long | maxNumSetParents |
bool | writeSets |
Flags idicating if set data should be written. For the normal (non-parallel) case, these values will depend only on whether or not there is any data to be written. For parallel-meshes, opening the data table is collective so the values must depend on whether or not any processor has meshsets to be written. More... | |
bool | writeSetContents |
bool | writeSetChildren |
bool | writeSetParents |
std::vector< SpecialSetData > | specialSets |
Array of special/shared sets, in order of handle value. More... | |
std::list< TagDesc > | tagList |
The list of tags to export. More... | |
bool | parallelWrite |
True if doing parallel write. More... | |
bool | collectiveIO |
True if using collective IO calls for parallel write. More... | |
bool | writeTagDense |
True if writing dense-formatted tag data. More... | |
hid_t | writeProp |
Property set to pass to H5Dwrite calls. For serial, should be H5P_DEFAULTS. For parallel, may request collective IO. More... | |
DebugOutput | dbgOut |
Utility to log debug output. More... | |
bool | debugTrack |
Look for overlapping and/or missing writes. More... | |
Static Protected Attributes inherited from moab::WriteHDF5 | |
static MPEState | topState |
static MPEState | subState |
Write MOAB HDF5 file in parallel.
Definition at line 20 of file WriteHDF5Parallel.hpp.
moab::WriteHDF5Parallel::WriteHDF5Parallel | ( | Interface * | iface | ) |
|
virtual |
Definition at line 284 of file WriteHDF5Parallel.cpp.
References myPcomm, and pcommAllocated.
|
protected |
Definition at line 582 of file WriteHDF5Parallel.cpp.
References buffer, moab::serial_tag_data::def_val_len, moab::error(), ErrorCode, moab::WriteHDF5::iFace, moab::serial_tag_data::len(), MB_SUCCESS, MB_VARIABLE_DATA_LENGTH, MB_VARIABLE_LENGTH, moab::serial_tag_data::name, moab::serial_tag_data::name_len, moab::serial_tag_data::set_default_value(), moab::serial_tag_data::size, moab::serial_tag_data::storage, moab::Interface::tag_get_data_type(), moab::Interface::tag_get_default_value(), moab::Interface::tag_get_length(), moab::Interface::tag_get_name(), moab::Interface::tag_get_type(), moab::WriteHDF5::TagDesc::tag_id, and moab::serial_tag_data::type.
Referenced by create_tag_tables().
|
protected |
helper function for create_tag_tables
Definition at line 632 of file WriteHDF5Parallel.cpp.
References buffer, moab::serial_tag_data::def_val_len, moab::serial_tag_data::default_value(), moab::error(), ErrorCode, moab::WriteHDF5::iFace, moab::serial_tag_data::len(), moab::WriteHDF5::TagDesc::max_num_ents, moab::WriteHDF5::TagDesc::max_num_vals, MB_SET_ERR, MB_SUCCESS, MB_TAG_CREAT, MB_TAG_VARLEN, MB_VARIABLE_LENGTH, moab::serial_tag_data::name, size, moab::serial_tag_data::size, moab::WriteHDF5::TagDesc::sparse_offset, moab::serial_tag_data::storage, moab::Interface::tag_get_data_type(), moab::Interface::tag_get_handle(), moab::Interface::tag_get_length(), moab::Interface::tag_get_name(), moab::WriteHDF5::TagDesc::tag_id, moab::WriteHDF5::tagList, moab::serial_tag_data::type, moab::WriteHDF5::TagDesc::var_data_offset, and moab::WriteHDF5::TagDesc::write_sparse.
Referenced by create_tag_tables().
|
protected |
Communicate set contents between processors such that each owner knows the contents, parents, & child lists from all processors that have a copy of the set.
Definition at line 1866 of file WriteHDF5Parallel.cpp.
References moab::Range::begin(), CHECK_MB, CHECK_MPI, moab::CREATE_HANDLE(), moab::WriteHDF5::dbgOut, moab::Range::end(), ErrorCode, moab::Interface::get_child_meshsets(), moab::Interface::get_entities_by_handle(), moab::ParallelComm::get_entityset_owner(), moab::ParallelComm::get_entityset_procs(), moab::Interface::get_meshset_options(), moab::Interface::get_parent_meshsets(), moab::ID_FROM_HANDLE(), moab::WriteHDF5::iFace, MB_SUCCESS, MBENTITYSET, moab::Range::merge(), mhdf_SET_RANGE_BIT, myPcomm, pack_set(), moab::DebugOutput::printf(), moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::WriteHDF5::range_to_blocked_list(), moab::WriteHDF5::SpecialSetData::setFlags, moab::WriteHDF5::SpecialSetData::setHandle, size, moab::Range::size(), moab::WriteHDF5::specialSets, moab::DebugOutput::tprintf(), unpack_set(), and moab::WriteHDF5::vector_to_id_list().
Referenced by create_meshset_tables().
|
protected |
Get remote ids for shared sets.
Definition at line 1517 of file WriteHDF5Parallel.cpp.
References moab::Range::begin(), CHECK_MB, CHECK_MPI, moab::WriteHDF5::dbgOut, moab::Range::end(), moab::error(), ErrorCode, moab::RangeMap< KeyType, ValType, NullVal >::find(), moab::ParallelComm::get_entityset_local_handle(), moab::ParallelComm::get_entityset_owner(), moab::ParallelComm::get_entityset_owners(), moab::ParallelComm::get_entityset_procs(), moab::ParallelComm::get_owned_sets(), moab::DebugOutput::get_verbosity(), moab::WriteHDF5::idMap, moab::Range::insert(), moab::RangeMap< KeyType, ValType, NullVal >::insert(), moab::intersect(), MB_SUCCESS, myPcomm, moab::DebugOutput::print(), print_shared_sets(), moab::DebugOutput::printf(), moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::Range::rbegin(), moab::Range::rend(), size, moab::Range::size(), moab::SSVB, and moab::DebugOutput::tprint().
Referenced by create_meshset_tables().
|
protected |
Create tables to hold element adjacencies.
Definition at line 1405 of file WriteHDF5Parallel.cpp.
References CHECK_HDFN, CHECK_MB, moab::WriteHDF5::count_adjacencies(), create_dataset(), ErrorCode, moab::WriteHDF5::exportList, moab::WriteHDF5::file_ptr(), MB_SUCCESS, mhdf_closeData(), mhdf_createAdjacency(), moab::WriteHDF5::ExportSet::name(), moab::WriteHDF5::nodeSet, and size.
Referenced by parallel_create_file().
|
protected |
Do typical communication for dataset creation.
Given the number of entities each processor intends to write, do necessary communication and create dataset on root, passing back misc info to each proc.
creator | Functor to do actual dataset creation. Used only on root process. |
num_datasets | The number of datasets to create. |
groups | Third argument passed to DataSetCreator. Array of length num_datasets pr NULL. |
num_owned_entities | The number of entities this proc will write. Array of length num_datasets . |
offsets_out | Output: The offset in the dataset at which this process should write. Array of length num_datasets . |
max_proc_ents_out | Output: The maximun number of entities that any proc will write Array of length num_datasets . |
total_ents_out | Output: The size of the created dataset (sum of counts over all procs) Array of length num_datasets . |
first_ids_out | Output: The first ID of the first entity in the data set. First ID for this proc's entities is first_id_out+offset_out Array of length num_datasets or NULL. |
Definition at line 1080 of file WriteHDF5Parallel.cpp.
References CHECK_MB, CHECK_MPI, ErrorCode, MB_SUCCESS, myPcomm, moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::ProcConfig::proc_size(), and VALGRIND_CHECK_MEM_IS_DEFINED.
Referenced by create_adjacency_tables(), create_element_tables(), create_meshset_tables(), create_node_table(), and create_tag_tables().
|
protected |
Create tables to hold element connectivity.
Definition at line 1363 of file WriteHDF5Parallel.cpp.
References moab::WriteHDF5::assign_ids(), CHECK_MB, create_dataset(), moab::WriteHDF5::create_elem_table(), ErrorCode, moab::WriteHDF5::exportList, MB_SUCCESS, and size.
Referenced by parallel_create_file().
|
protected |
Create tables for mesh sets.
Definition at line 2116 of file WriteHDF5Parallel.cpp.
References moab::WriteHDF5::assign_ids(), CHECK_MB, communicate_shared_set_data(), communicate_shared_set_ids(), moab::WriteHDF5::count_set_size(), create_dataset(), moab::WriteHDF5::create_set_meta(), moab::WriteHDF5::create_set_tables(), moab::WriteHDF5::dbgOut, END_SERIAL, ErrorCode, moab::WriteHDF5::ExportSet::first_id, moab::ParallelComm::get_owned_sets(), moab::ParallelComm::get_shared_sets(), moab::WriteHDF5::iFace, moab::intersect(), moab::WriteHDF5::ExportSet::max_num_ents, moab::WriteHDF5::maxNumSetChildren, moab::WriteHDF5::maxNumSetContents, moab::WriteHDF5::maxNumSetParents, MB_SUCCESS, myPcomm, moab::WriteHDF5::ExportSet::offset, moab::print_type_sets(), moab::DebugOutput::printf(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::WriteHDF5::ExportSet::range, moab::WriteHDF5::SET_OFFSET_TIME, moab::WriteHDF5::setChildrenOffset, moab::WriteHDF5::setContentsOffset, moab::WriteHDF5::setParentsOffset, moab::WriteHDF5::setSet, moab::WriteHDF5::SHARED_SET_CONTENTS, moab::WriteHDF5::SHARED_SET_IDS, size, moab::Range::size(), START_SERIAL, moab::subtract(), moab::CpuTimer::time_elapsed(), moab::WriteHDF5::ExportSet::total_num_ents, moab::WriteHDF5::writeSetChildren, moab::WriteHDF5::writeSetContents, moab::WriteHDF5::writeSetParents, and moab::WriteHDF5::writeSets.
Referenced by parallel_create_file().
|
protected |
Create the node table in the file.
Definition at line 1180 of file WriteHDF5Parallel.cpp.
References moab::WriteHDF5::assign_ids(), CHECK_HDFN, CHECK_MB, create_dataset(), ErrorCode, moab::WriteHDF5::file_ptr(), moab::WriteHDF5::ExportSet::first_id, moab::WriteHDF5::ExportSet::max_num_ents, MB_SUCCESS, mhdf_closeData(), mhdf_createNodeCoords(), moab::WriteHDF5::nodeSet, moab::WriteHDF5::ExportType::num_nodes, moab::WriteHDF5::ExportSet::offset, moab::WriteHDF5::ExportSet::range, moab::Range::size(), and moab::WriteHDF5::ExportSet::total_num_ents.
Referenced by parallel_create_file().
|
protected |
Write tag descriptions and create tables to hold tag data.
Definition at line 753 of file WriteHDF5Parallel.cpp.
References append_serial_tag_data(), moab::WriteHDF5::check_dense_format_tag(), CHECK_MB, CHECK_MPI, check_serial_tag_data(), create_dataset(), moab::WriteHDF5::create_tag(), moab::WriteHDF5::dbgOut, moab::error(), ErrorCode, moab::WriteHDF5::exportList, moab::get_bit(), moab::WriteHDF5::get_num_sparse_tagged_entities(), moab::WriteHDF5::get_sparse_tagged_entities(), moab::WriteHDF5::get_tag_data_length(), moab::DebugOutput::get_verbosity(), moab::WriteHDF5::iFace, MB_SET_ERR_CONT, MB_SUCCESS, MB_TAG_DENSE, MB_VARIABLE_DATA_LENGTH, moab::my_Gatherv(), myPcomm, moab::WriteHDF5::nodeSet, moab::DebugOutput::print(), moab::DebugOutput::printf(), moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::WriteHDF5::ExportSet::range, moab::set_bit(), moab::WriteHDF5::setSet, size, moab::Range::size(), moab::WriteHDF5::subState, moab::Interface::tag_get_default_value(), moab::Interface::tag_get_length(), moab::Interface::tag_get_name(), moab::Interface::tag_get_type(), moab::WriteHDF5::tagList, TagType, moab::DebugOutput::tprint(), and moab::WriteHDF5::writeTagDense.
Referenced by parallel_create_file().
|
protectedvirtual |
Reimplemented from moab::WriteHDF5.
Definition at line 263 of file WriteHDF5Parallel.cpp.
References moab::WriteHDF5::dbgOut, moab::DebugOutput::get_verbosity(), myPcomm, moab::DebugOutput::printf(), moab::ProcConfig::proc_comm(), and moab::ParallelComm::proc_config().
For entities that will be written by another processor but are referenced by entities on this processor, get the file Ids that will be assigned to those so they can be referenced by entities to be written on this processor.
non_local_ents | List of entities that are not to be written by this processor but are referenced by other entities that are to be written. |
Definition at line 2263 of file WriteHDF5Parallel.cpp.
References moab::Range::begin(), moab::Range::clear(), moab::WriteHDF5::dbgOut, moab::Range::end(), moab::CN::EntityTypeName(), moab::error(), ErrorCode, moab::ParallelComm::exchange_tags(), moab::WriteHDF5::exportList, moab::ParallelComm::filter_pstatus(), moab::RangeMap< KeyType, ValType, NullVal >::find(), moab::ParallelComm::get_owner(), moab::ID_FROM_HANDLE(), moab::WriteHDF5::idMap, moab::WriteHDF5::iFace, moab::RangeMap< KeyType, ValType, NullVal >::insert(), MB_SET_ERR, MB_SET_ERR_CONT, MB_SUCCESS, MB_TAG_CREAT, MB_TAG_DENSE, MB_TYPE_HANDLE, moab::Range::merge(), myPcomm, moab::WriteHDF5::nodeSet, moab::DebugOutput::printf(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), PSTATUS_AND, PSTATUS_SHARED, moab::WriteHDF5::ExportSet::range, moab::Range::size(), moab::Interface::tag_delete(), moab::Interface::tag_get_data(), moab::Interface::tag_get_handle(), moab::Interface::tag_set_data(), and moab::TYPE_FROM_HANDLE().
Referenced by parallel_create_file().
|
static |
Definition at line 274 of file WriteHDF5Parallel.cpp.
References iface, and WriteHDF5Parallel().
Referenced by moab::ReaderWriterSet::ReaderWriterSet().
Figure out which mesh local mesh is duplicated on remote processors and which processor will write that mesh.
non_local_ents | Output list of entities that are not to be written by this processor but are referenced by other entities that are to be written. |
Definition at line 295 of file WriteHDF5Parallel.cpp.
References moab::Range::clear(), moab::WriteHDF5::dbgOut, moab::error(), ErrorCode, moab::WriteHDF5::exportList, moab::ParallelComm::filter_pstatus(), MB_SUCCESS, moab::Range::merge(), myPcomm, moab::WriteHDF5::nodeSet, moab::DebugOutput::print(), PSTATUS_AND, PSTATUS_NOT_OWNED, moab::WriteHDF5::ExportSet::range, moab::WriteHDF5::setSet, and moab::subtract().
Referenced by parallel_create_file().
|
protected |
get any existing tags which aren't excluded and add to shared set tags
|
protected |
Communicate with other processors to negotiate the types of elements that will be written (the union of the types defined on each proc.)
Definition at line 1228 of file WriteHDF5Parallel.cpp.
References moab::WriteHDF5::ExportSet::adj_offset, CHECK_MPI, moab::WriteHDF5::dbgOut, moab::CN::EntityTypeName(), moab::WriteHDF5::exportList, moab::WriteHDF5::ExportSet::first_id, MB_SUCCESS, myPcomm, moab::WriteHDF5::ExportType::num_nodes, moab::WriteHDF5::ExportSet::offset, moab::DebugOutput::print(), moab::DebugOutput::printf(), moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::ProcConfig::proc_size(), moab::WriteHDF5::ExportType::type, VALGRIND_CHECK_MEM_IS_DEFINED, and moab::VALGRIND_MAKE_VEC_UNDEFINED().
Referenced by parallel_create_file().
|
protected |
Pack set data for communication.
If set_data_length is insufficient for the set data, the length entries at indices 1, 2, and 3 of set_data will be set with the necessary lengths, but no data will be written to set_data beyond that.
Definition at line 1675 of file WriteHDF5Parallel.cpp.
References buffer, CHECK_MB, moab::WriteUtilIface::CHILDREN, moab::WriteUtilIface::CONTENTS, ErrorCode, moab::WriteUtilIface::get_entity_list_pointers(), MB_SUCCESS, mhdf_SET_RANGE_BIT, moab::WriteUtilIface::PARENTS, moab::WriteHDF5::range_to_blocked_list(), moab::WriteHDF5::vector_to_id_list(), and moab::WriteHDF5::writeUtil.
Referenced by communicate_shared_set_data().
|
protectedvirtual |
Called by normal (non-parallel) writer. Sets up necessary data for parallel write.
Reimplemented from moab::WriteHDF5.
Definition at line 334 of file WriteHDF5Parallel.cpp.
References moab::WriteHDF5::collectiveIO, moab::WriteHDF5::CREATE_ADJ_TIME, create_adjacency_tables(), moab::WriteHDF5::CREATE_ELEM_TIME, create_element_tables(), create_meshset_tables(), create_node_table(), moab::WriteHDF5::CREATE_NODE_TIME, moab::WriteHDF5::CREATE_SET_TIME, create_tag_tables(), moab::WriteHDF5::CREATE_TAG_TIME, moab::WriteHDF5::dbgOut, debug_barrier, moab::CN::EntityTypeName(), moab::error(), ErrorCode, exchange_file_ids(), moab::WriteHDF5::FILEID_EXCHANGE_TIME, moab::WriteHDF5::filePtr, gather_interface_meshes(), moab::WriteHDF5::gather_tags(), moab::FileOptions::get_int_option(), moab::FileOptions::get_null_option(), moab::ParallelComm::get_pcomm(), moab::FileOptions::get_str_option(), moab::HDF5_can_append_hyperslabs(), hslabOp, moab::WriteHDF5::id_type, moab::WriteHDF5::iFace, moab::DebugOutput::limit_output_to_first_N_procs(), MB_SET_ERR, MB_SUCCESS, MBEDGE, MBENTITYSET, MBMAXTYPE, mhdf_closeFile(), mhdf_createFile(), mhdf_message(), mhdf_openFileWithOpt(), myPcomm, negotiate_type_list(), moab::WriteHDF5::NEGOTIATE_TYPES_TIME, pcommAllocated, moab::DebugOutput::print(), moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), moab::DebugOutput::set_rank(), moab::CpuTimer::time_elapsed(), moab::WriteHDF5::topState, moab::DebugOutput::tprint(), moab::DebugOutput::tprintf(), moab::WriteHDF5::write_qa(), and moab::WriteHDF5::writeProp.
|
protected |
Definition at line 1459 of file WriteHDF5Parallel.cpp.
References moab::Range::begin(), moab::WriteHDF5::dbgOut, moab::Range::end(), moab::RangeMap< KeyType, ValType, NullVal >::find(), moab::ParallelComm::get_entityset_owner(), moab::ParallelComm::get_entityset_procs(), moab::WriteHDF5::idMap, moab::WriteHDF5::iFace, myPcomm, moab::DebugOutput::print(), moab::DebugOutput::printf(), moab::SSVB, and moab::Interface::tag_get_data().
Referenced by print_shared_sets().
|
protected |
Definition at line 1486 of file WriteHDF5Parallel.cpp.
References DIRICHLET_SET_TAG_NAME, GEOM_DIMENSION_TAG_NAME, moab::Interface::get_entities_by_type_and_tag(), moab::Interface::globalId_tag(), moab::WriteHDF5::iFace, MATERIAL_SET_TAG_NAME, MB_SUCCESS, MB_TYPE_INTEGER, MBENTITYSET, NEUMANN_SET_TAG_NAME, print_set_sharing_data(), and moab::Interface::tag_get_handle().
Referenced by communicate_shared_set_ids().
|
protectedvirtual |
Definition at line 2395 of file WriteHDF5Parallel.cpp.
References myPcomm, moab::WriteHDF5::NUM_TIMES, moab::WriteHDF5::print_times(), moab::ProcConfig::proc_comm(), moab::ParallelComm::proc_config(), and moab::ProcConfig::proc_rank().
|
protected |
Remove any remote mesh entities from the passed range.
Definition at line 2200 of file WriteHDF5Parallel.cpp.
References moab::Range::begin(), moab::CREATE_HANDLE(), moab::Range::end(), moab::WriteHDF5::exportList, moab::intersect(), moab::Range::lower_bound(), MBENTITYSET, moab::Range::merge(), moab::WriteHDF5::nodeSet, moab::WriteHDF5::ExportSet::range, remove_remote_sets(), moab::WriteHDF5::setSet, and moab::Range::swap().
Referenced by remove_remote_entities().
|
protected |
Definition at line 2225 of file WriteHDF5Parallel.cpp.
References moab::Range::end(), moab::Range::find(), moab::Range::insert(), and remove_remote_entities().
|
protected |
Definition at line 2217 of file WriteHDF5Parallel.cpp.
References moab::intersect(), moab::WriteHDF5::ExportSet::range, moab::WriteHDF5::setSet, and moab::Range::swap().
Referenced by remove_remote_entities(), and remove_remote_sets().
|
protected |
Definition at line 2244 of file WriteHDF5Parallel.cpp.
References moab::Range::end(), moab::Range::find(), moab::Range::insert(), and remove_remote_sets().
|
protected |
Unpack set data from communication.
Definition at line 1798 of file WriteHDF5Parallel.cpp.
References buffer, moab::WriteHDF5::SpecialSetData::childIds, children, moab::WriteHDF5::SpecialSetData::contentIds, moab::convert_to_ranged_ids(), moab::WriteHDF5::find_set_data(), MB_SUCCESS, moab::merge_ranged_ids(), moab::merge_vector_ids(), mhdf_SET_RANGE_BIT, moab::WriteHDF5::SpecialSetData::parentIds, and moab::WriteHDF5::SpecialSetData::setFlags.
Referenced by communicate_shared_set_data().
|
private |
Operation to use to append hyperslab selections.
Definition at line 186 of file WriteHDF5Parallel.hpp.
Referenced by parallel_create_file().
|
private |
pcomm controlling parallel nature of mesh
Definition at line 180 of file WriteHDF5Parallel.hpp.
Referenced by communicate_shared_set_data(), communicate_shared_set_ids(), create_dataset(), create_meshset_tables(), create_tag_tables(), debug_barrier_line(), exchange_file_ids(), gather_interface_meshes(), negotiate_type_list(), parallel_create_file(), print_set_sharing_data(), print_times(), and ~WriteHDF5Parallel().
|
private |
whether this instance allocated (and dtor should delete) the pcomm
Definition at line 183 of file WriteHDF5Parallel.hpp.
Referenced by parallel_create_file(), and ~WriteHDF5Parallel().