26#include "ioex_export.h"
33#define EXU_USE_HOPSCOTCH
34#if defined EXU_USE_HOPSCOTCH
36#elif defined EXU_USE_ROBIN
50 using EntityIdSet = std::set<std::pair<int64_t, int64_t>>;
52 using SideSetMap = std::map<std::string, const std::string, std::less<>>;
54 using NameTopoKey = std::pair<std::string, const Ioss::ElementTopology *>;
59 assert(lhs.second !=
nullptr);
60 assert(rhs.second !=
nullptr);
61 return lhs.first < rhs.first ||
62 (!(rhs.first < lhs.first) && lhs.second->name() < rhs.second->name());
70 return std::hash<std::string>{}(name_topo.first) +
71 std::hash<size_t>{}((size_t)name_topo.second);
75#if defined EXU_USE_HOPSCOTCH
77#elif defined EXU_USE_ROBIN
81 using TopologyMap = std::map<NameTopoKey, int, NameTopoKeyCompare>;
86 int processor_count,
int processor_id);
106 IOEX_EXPORT
void exodus_error(
int exoid,
int lineno,
const char *function,
const char *filename);
107 IOEX_EXPORT
void exodus_error(
int exoid,
int lineno,
const char *function,
const char *filename,
108 const std::string &extra);
116 int exoid, ex_entity_type type);
125 std::string *disp_name);
128 const std::string &basename,
int length,
129 bool lowercase_names,
bool &db_has_name);
135 const std::vector<unsigned char> &node_connectivity_status);
137 template <
typename T>
139 const std::vector<int64_t> &active_node_index)
141 for (
size_t i = 0; i < active_node_index.size(); i++) {
142 data[i] = dbvals[active_node_index[i]];
154 const std::string &surface_name);
160 for (
const auto &ge : entities) {
#define IOSS_NODISCARD
Definition Ioss_CodeTypes.h:56
std::set< EntityId > EntityIdSet
Definition UnitTestIotmTextMeshFixture.h:68
A collection of elements having the same topology.
Definition Ioss_ElementBlock.h:29
Base class for all 'grouping' entities. The following derived classes are typical:
Definition Ioss_GroupingEntity.h:67
A grouping entity that contains other grouping entities.
Definition Ioss_Region.h:93
A generic variable type.
Definition Ioss_VariableType.h:70
Definition hopscotch_map.h:82
Definition robin_map.h:90
A namespace for the exodus database format.
Definition Ioex_BaseDatabaseIO.C:170
bool set_id(const Ioss::GroupingEntity *entity, Ioex::EntityIdSet *idset)
Definition Ioex_Utils.C:499
void delete_name_array(char **names, int count)
Definition Ioex_Utils.C:358
std::set< std::string > SideSetSet
Definition Ioex_Utils.h:51
bool find_displacement_field(Ioss::NameList &fields, const Ioss::GroupingEntity *block, int ndim, std::string *disp_name)
Definition Ioex_Utils.C:611
bool check_processor_info(const std::string &filename, int exodusFilePtr, int processor_count, int processor_id)
Definition Ioex_Utils.C:431
void write_coordinate_frames(int exoid, const Ioss::CoordinateFrameContainer &frames)
Definition Ioex_Utils.C:796
int64_t extract_id(const std::string &name_id)
Definition Ioex_Utils.C:528
std::string map_ioss_field_type(ex_field_type type)
Definition Ioex_Utils.C:130
tsl::hopscotch_map< NameTopoKey, int, NameTopoKeyHash > TopologyMap
Definition Ioex_Utils.h:76
Ioss::EntityType map_exodus_type(ex_entity_type type)
Definition Ioex_Utils.C:252
void separate_surface_element_sides(Ioss::Int64Vector &element, Ioss::Int64Vector &sides, Ioss::Region *region, Ioex::TopologyMap &topo_map, Ioex::TopologyMap &side_map, Ioss::SurfaceSplitType split_type, const std::string &surface_name)
Definition Ioex_Utils.C:917
std::map< std::string, const std::string, std::less<> > SideSetMap
Definition Ioex_Utils.h:52
char ** get_name_array(size_t count, int size)
Definition Ioex_Utils.C:348
int read_exodus_basis(int exoid)
Definition Ioex_Utils.C:271
void add_coordinate_frames(int exoid, Ioss::Region *region)
Definition Ioex_Utils.C:806
void filter_element_list(Ioss::Region *region, Ioss::Int64Vector &elements, Ioss::Int64Vector &sides, bool remove_omitted_elements)
Definition Ioex_Utils.C:880
Ioss::NameList get_reduction_variable_names(int nvar, int maximumNameLength, int exoid, ex_entity_type type)
Definition Ioex_Utils.C:383
bool type_match(const std::string &type, const char *substring)
Definition Ioex_Utils.C:482
IOSS_NODISCARD IOEX_EXPORT const char * Version()
int add_map_fields(int exoid, Ioss::ElementBlock *block, int64_t my_element_count, size_t name_length)
Definition Ioex_Utils.C:732
Ioss::NameList get_variable_names(int nvar, int maximumNameLength, int exoid, ex_entity_type type)
Definition Ioex_Utils.C:366
void update_last_time_attribute(int exodusFilePtr, double value)
Definition Ioex_Utils.C:113
int read_exodus_quadrature(int exoid)
Definition Ioex_Utils.C:299
std::pair< std::string, const Ioss::ElementTopology * > NameTopoKey
Definition Ioex_Utils.h:54
bool read_last_time_attribute(int exodusFilePtr, double *value)
Definition Ioex_Utils.C:401
std::set< std::pair< int64_t, int64_t > > EntityIdSet
Definition Ioex_BaseDatabaseIO.h:75
std::string get_entity_name(int exoid, ex_entity_type type, int64_t id, const std::string &basename, int length, bool lowercase_names, bool &db_has_name)
Definition Ioex_Utils.C:660
void exodus_error(int exoid, int lineno, const char *function, const char *filename)
Definition Ioex_Utils.C:706
int64_t get_id(const Ioss::GroupingEntity *entity, Ioex::EntityIdSet *idset)
Definition Ioex_Utils.C:547
void cleanup_exodus_assembly_vector(std::vector< ex_assembly > &assemblies)
Definition Ioex_Utils.C:846
bool filter_node_list(Ioss::Int64Vector &nodes, const std::vector< unsigned char > &node_connectivity_status)
Definition Ioex_Utils.C:854
void fix_bad_name(char *name)
Definition Ioex_Utils.C:644
void write_reduction_attributes(int exoid, const Ioss::GroupingEntity *ge)
Definition Ioex_Utils.C:989
std::vector< ex_assembly > get_exodus_assemblies(int exoid)
Definition Ioex_Utils.C:816
The main namespace for the Ioss library.
Definition Ioad_DatabaseIO.C:40
std::vector< int64_t > Int64Vector
Definition Ioss_CodeTypes.h:22
SurfaceSplitType
Method used to split sidesets into homogeneous blocks.
Definition Ioss_SurfaceSplit.h:11
Ioss::NameList NameList
Definition Ioss_ChangeSetFactory.h:25
std::vector< CoordinateFrame > CoordinateFrameContainer
Definition Ioex_Utils.h:46
EntityType
The particular type of GroupingEntity.
Definition Ioss_EntityType.h:12
Definition Ioex_Utils.h:56
IOSS_NODISCARD bool operator()(const NameTopoKey &lhs, const NameTopoKey &rhs) const
Definition Ioex_Utils.h:57
Definition Ioex_Utils.h:67
IOSS_NODISCARD size_t operator()(const NameTopoKey &name_topo) const
Definition Ioex_Utils.h:68