Classes | |
| class | AsciiWriter |
| A class used to abstract away reading/writing files. More... | |
| class | HDF5data |
| Class to wrap HDF5 data. More... | |
| class | HDF5writer |
| A class used to abstract away reading/writing files for visualization. More... | |
| class | NullWriter |
| A class used to abstract away reading/writing files for visualization. More... | |
| class | RestartManager |
| Class to manage reading/writing restart data. More... | |
| class | SiloIO |
| A class used to abstract away reading/writing files for visualization. More... | |
| class | Writer |
| A class used to abstract away reading/writing files. More... | |
Enumerations | |
| enum class | Compression : uint8_t { None , GZIP , SZIP } |
Functions | |
| void | closeDataset (hid_t fid) |
| Close a dataset. | |
| void | closeDataspace (hid_t fid) |
| Close a dataspace. | |
| void | closeDatatype (hid_t fid) |
| Close a datatype. | |
| void | closeGroup (hid_t fid) |
| Close a group. | |
| void | closeHDF5 (hid_t fid, bool printLeaks=false) |
| Open an HDF5 file. | |
| hid_t | createChunk (AMP::ArraySize dims, Compression compress, size_t objSize=0) |
| Open an HDF5 file. | |
| hid_t | createGroup (hid_t fid, const std::string &name) |
| Create a group. | |
| Compression | defaultCompression (hid_t fid) |
| Retrun the the default compression. | |
| void | deleteFile (const std::string &filename) |
| Delete a file. If the file does not exist, nothing will happen. | |
| bool | exists (const std::string &filename) |
| Check if a file exists and return true if it does. | |
| bool | fileExists (const std::string &) |
| std::string | filename (const std::string &filename) |
| Return the filename (strip the path) | |
| size_t | fileSize (const std::string &filename) |
| Return the file size. | |
| template<class T > | |
| hid_t | getHDF5datatype () |
| Get HDF5 data type. | |
| hid_t | getHDF5datatype (hid_t fid, const std::string &name) |
| Get the type of a dataset. | |
| std::string | getSuffix (const std::string &filename) |
| Get the lower case suffix for a file. | |
| bool | H5Dexists (hid_t fid, const std::string &name) |
| Check if dataset exists. | |
| bool | H5Gexists (hid_t fid, const std::string &name) |
| Check if group exists. | |
| bool | HDF5enabled () |
| Is HDF5 enabled. | |
| hid_t | openGroup (hid_t fid, const std::string &name, bool create=false) |
| Open a group. | |
| hid_t | openHDF5 (const std::string &filename, const char *mode, Compression compress=Compression::None) |
| Open an HDF5 file. | |
| std::tuple< std::vector< hid_t >, std::vector< hid_t >, std::vector< hid_t >, std::vector< hid_t >, std::vector< hid_t > > | openObjects (hid_t fid) |
| list open objects | |
| std::string | path (const std::string &filename) |
| Return the path to the file. | |
| void | permissions (const std::string &filename, std::filesystem::perms mode) |
| Set the permissions for the file or directory. | |
| template<class T > | |
| std::unique_ptr< T > | readHDF5 (hid_t fid, const std::string &name, AMP_MPI comm=AMP_COMM_SELF) |
| Read a structure from HDF5. | |
| void | readHDF5 (hid_t fid, const std::string &name, size_t N_bytes, void *data) |
| Read data from HDF5. | |
| template<class T > | |
| void | readHDF5 (hid_t fid, const std::string &name, T &data) |
| Read a structure from HDF5. | |
| std::unique_ptr< HDF5data > | readHDF5 (hid_t fid, const std::string_view &name) |
| Read data from HDF5. | |
| void | recursiveMkdir (const std::string &, mode_t) |
| void | recursiveMkdir (const std::string &, mode_t, bool) |
| void | recursiveMkdir (const std::string &path) |
| void | rename (const std::string &old_filename, const std::string &new_filename) |
| Rename a file from old file name to new file name. | |
| void | renameFile (const std::string &old_filename, const std::string &new_filename) |
| template<class T > | |
| void | writeHDF5 (hid_t fid, const std::string &name, const T &data) |
| Write a structure to HDF5. | |
| void | writeHDF5 (hid_t fid, const std::string &name, size_t N_bytes, const void *data) |
| Write data to HDF5. | |
|
strong |
| void AMP::IO::closeDataset | ( | hid_t | fid | ) |
Close a dataset.
This function closes an HDF5 dataset
| [in] | fid | Dataset to close |
| void AMP::IO::closeDataspace | ( | hid_t | fid | ) |
Close a dataspace.
This function closes an HDF5 dataspace
| [in] | fid | closeDataspace to close |
| void AMP::IO::closeDatatype | ( | hid_t | fid | ) |
Close a datatype.
This function closes an HDF5 datatype
| [in] | fid | Datatype to close |
| void AMP::IO::closeGroup | ( | hid_t | fid | ) |
Close a group.
This function closes an HDF5 group
| [in] | fid | Group to close |
| void AMP::IO::closeHDF5 | ( | hid_t | fid, |
| bool | printLeaks = false |
||
| ) |
Open an HDF5 file.
This function opens and HDF5 file for reading/writing
| [in] | fid | File to open |
| [in] | printLeaks | Print the resource leaks |
| hid_t AMP::IO::createChunk | ( | AMP::ArraySize | dims, |
| Compression | compress, | ||
| size_t | objSize = 0 |
||
| ) |
Open an HDF5 file.
This function create a chunk for HDF5
| [in] | dims | Chunk size |
| [in] | compress | Compression to use |
| [in] | objSize | Optional number of bytes of an object |
Create a group.
This function creates a new HDF5 group
| [in] | fid | File or group to write to |
| [in] | name | The name of the group |
| Compression AMP::IO::defaultCompression | ( | hid_t | fid | ) |
Retrun the the default compression.
This function returns the default compression used when the file was created
| [in] | fid | File/Group id |
| void AMP::IO::deleteFile | ( | const std::string & | filename | ) |
Delete a file. If the file does not exist, nothing will happen.
| bool AMP::IO::exists | ( | const std::string & | filename | ) |
Check if a file exists and return true if it does.
| bool AMP::IO::fileExists | ( | const std::string & | ) |
| std::string AMP::IO::filename | ( | const std::string & | filename | ) |
Return the filename (strip the path)
| size_t AMP::IO::fileSize | ( | const std::string & | filename | ) |
Return the file size.
| hid_t AMP::IO::getHDF5datatype | ( | ) |
Get HDF5 data type.
This function returns the id of the data type
Get the type of a dataset.
This function returns the type of a dataset
| [in] | fid | File or group to write to |
| [in] | name | The name of the group |
| std::string AMP::IO::getSuffix | ( | const std::string & | filename | ) |
Get the lower case suffix for a file.
| bool AMP::IO::H5Dexists | ( | hid_t | fid, |
| const std::string & | name | ||
| ) |
Check if dataset exists.
This function checks if an HDF5 dataset exists in the file
| [in] | fid | File to open |
| [in] | name | The name of the dataset |
| bool AMP::IO::H5Gexists | ( | hid_t | fid, |
| const std::string & | name | ||
| ) |
Check if group exists.
This function checks if an HDF5 group exists in the file
| [in] | fid | ID of group or database to read |
| [in] | name | The name of the group |
| bool AMP::IO::HDF5enabled | ( | ) |
Is HDF5 enabled.
This function returns true if HDF5 support is enabled (AMP was compiled with HDF5)
Open a group.
This function opens an HDF5 group
| [in] | fid | File or group to write to |
| [in] | name | The name of the group |
| [in] | create | Create the group if it does not exist? |
| hid_t AMP::IO::openHDF5 | ( | const std::string & | filename, |
| const char * | mode, | ||
| Compression | compress = Compression::None |
||
| ) |
Open an HDF5 file.
This function opens and HDF5 file for reading/writing. Once complete, we must close the file using closeHDF5
| [in] | filename | File to open |
| [in] | mode | C string containing a file access mode. It can be: "r" read: Open file for input operations. The file must exist. "w" write: Create an empty file for output operations. If a file with the same name already exists, its contents are discarded and the file is treated as a new empty file. "rw" read+write: Open file for reading and writing. The file must exist. |
| [in] | compress | Default compression |
| std::tuple< std::vector< hid_t >, std::vector< hid_t >, std::vector< hid_t >, std::vector< hid_t >, std::vector< hid_t > > AMP::IO::openObjects | ( | hid_t | fid | ) |
list open objects
This function closes an HDF5 group
| [in] | fid | Group to close |
| std::string AMP::IO::path | ( | const std::string & | filename | ) |
Return the path to the file.
| void AMP::IO::permissions | ( | const std::string & | filename, |
| std::filesystem::perms | mode | ||
| ) |
Set the permissions for the file or directory.
| std::unique_ptr< T > AMP::IO::readHDF5 | ( | hid_t | fid, |
| const std::string & | name, | ||
| AMP_MPI | comm = AMP_COMM_SELF |
||
| ) |
Read a structure from HDF5.
This function reads a C++ class/struct from HDF5. This is a templated function and users can implement their own data types by creating explicit instantiations for a given type. There is no default instantiation except when compiled without HDF5 which is a no-op.
| [in] | fid | File or group to read from |
| [in] | name | The name of the variable |
| [in] | comm | The communicator of the object |
| void AMP::IO::readHDF5 | ( | hid_t | fid, |
| const std::string & | name, | ||
| size_t | N_bytes, | ||
| void * | data | ||
| ) |
Read data from HDF5.
This function reads a fixed number of bytes from HDF5.
| [in] | fid | File or group to write to |
| [in] | name | The name of the variable |
| [in] | N_bytes | The number of bytes to write |
| [out] | data | The data to read |
| void AMP::IO::readHDF5 | ( | hid_t | fid, |
| const std::string & | name, | ||
| T & | data | ||
| ) |
Read a structure from HDF5.
This function reads a C++ class/struct from HDF5. This is a templated function and users can implement their own data types by creating explicit instantiations for a given type. There is no default instantiation except when compiled without HDF5 which is a no-op.
| [in] | fid | File or group to read from |
| [in] | name | The name of the variable |
| [out] | data | The structure to read |
Read data from HDF5.
This function reads arbitrary from HDF5. The user then requests the individual data from the class.
| [in] | fid | File or group to read from |
| [in] | name | The name of the variable |
| void AMP::IO::recursiveMkdir | ( | const std::string & | , |
| mode_t | |||
| ) |
| void AMP::IO::recursiveMkdir | ( | const std::string & | , |
| mode_t | , | ||
| bool | |||
| ) |
| void AMP::IO::recursiveMkdir | ( | const std::string & | path | ) |
| void AMP::IO::rename | ( | const std::string & | old_filename, |
| const std::string & | new_filename | ||
| ) |
Rename a file from old file name to new file name.
| void AMP::IO::renameFile | ( | const std::string & | old_filename, |
| const std::string & | new_filename | ||
| ) |
| void AMP::IO::writeHDF5 | ( | hid_t | fid, |
| const std::string & | name, | ||
| const T & | data | ||
| ) |
Write a structure to HDF5.
This function writes a C++ class/struct to HDF5. This is a templated function and users can implement their own data types by creating explicit instantiations for a given type. There is no default instantiation except when compiled without HDF5 which is a no-op.
| [in] | fid | File or group to write to |
| [in] | name | The name of the variable |
| [in] | data | The structure to write |
| void AMP::IO::writeHDF5 | ( | hid_t | fid, |
| const std::string & | name, | ||
| size_t | N_bytes, | ||
| const void * | data | ||
| ) |
Write data to HDF5.
This function writes a fixed number of bytes from HDF5.
| [in] | fid | File or group to write to |
| [in] | name | The name of the variable |
| [in] | N_bytes | The number of bytes to write |
| [in] | data | The data to write |
|
Advanced Multi-Physics (AMP) Oak Ridge National Laboratory Idaho National Laboratory Los Alamos National Laboratory |
This page automatically produced from the source code by Last updated: Tue Mar 10 2026 13:06:42. Comments on this page |