[MOAB-dev] r4064 - MOAB/trunk/src/io
kraftche at cae.wisc.edu
kraftche at cae.wisc.edu
Wed Jul 21 17:30:04 CDT 2010
Author: kraftche
Date: 2010-07-21 17:30:04 -0500 (Wed, 21 Jul 2010)
New Revision: 4064
Added:
MOAB/trunk/src/io/ReadHDF5Dataset.cpp
MOAB/trunk/src/io/ReadHDF5Dataset.hpp
Modified:
MOAB/trunk/src/io/Makefile.am
MOAB/trunk/src/io/ReadHDF5.cpp
MOAB/trunk/src/io/ReadHDF5.hpp
Log:
use complex hyperslabs to avoid many read calls to HDF5 library for fragmented data
Modified: MOAB/trunk/src/io/Makefile.am
===================================================================
--- MOAB/trunk/src/io/Makefile.am 2010-07-21 22:29:24 UTC (rev 4063)
+++ MOAB/trunk/src/io/Makefile.am 2010-07-21 22:30:04 UTC (rev 4064)
@@ -23,7 +23,12 @@
if HDF5_FILE
libmoabio_la_LIBADD += mhdf/libmhdf.la
- MOAB_HDF5_SRCS = ReadHDF5.cpp ReadHDF5.hpp WriteHDF5.cpp WriteHDF5.hpp
+ MOAB_HDF5_SRCS = ReadHDF5.cpp \
+ ReadHDF5.hpp \
+ ReadHDF5Dataset.hpp \
+ ReadHDF5Dataset.cpp \
+ WriteHDF5.cpp \
+ WriteHDF5.hpp
AM_CPPFLAGS += -I$(srcdir)/mhdf/include
else
MOAB_HDF5_SRCS =
Modified: MOAB/trunk/src/io/ReadHDF5.cpp
===================================================================
--- MOAB/trunk/src/io/ReadHDF5.cpp 2010-07-21 22:29:24 UTC (rev 4063)
+++ MOAB/trunk/src/io/ReadHDF5.cpp 2010-07-21 22:30:04 UTC (rev 4064)
@@ -51,6 +51,7 @@
#include <functional>
#include "IODebugTrack.hpp"
+#include "ReadHDF5Dataset.hpp"
namespace moab {
@@ -1031,7 +1032,6 @@
mhdf_Status status;
const int dim = fileInfo->nodes.vals_per_ent;
Range range;
- IODebugTrack debug_track(debugTrack, "NodeCoords");
if (node_file_ids.empty())
return MB_SUCCESS;
@@ -1054,79 +1054,54 @@
EntityHandle handle;
std::vector<double*> arrays(dim);
- rval = readUtil->get_node_coords( dim, (int)node_file_ids.size(), 0, handle, arrays );
+ const size_t num_nodes = node_file_ids.size();
+ rval = readUtil->get_node_coords( dim, (int)num_nodes, 0, handle, arrays );
if (MB_SUCCESS != rval)
{
mhdf_closeData( filePtr, data_id, &status );
return error(rval);
}
More information about the moab-dev
mailing list