Abstract base class for compression implementations abstract_compressor
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| type(dtfft_compression_mode_t), | public, | parameter | :: | DTFFT_COMPRESSION_MODE_LOSSLESS | = | dtfft_compression_mode_t(1) |
Lossless compression mode |
| type(dtfft_compression_mode_t), | public, | parameter | :: | DTFFT_COMPRESSION_MODE_FIXED_RATE | = | dtfft_compression_mode_t(2) |
Fixed rate compression mode |
| type(dtfft_compression_mode_t), | public, | parameter | :: | DTFFT_COMPRESSION_MODE_FIXED_PRECISION | = | dtfft_compression_mode_t(3) |
Fixed precision compression mode |
| type(dtfft_compression_mode_t), | public, | parameter | :: | DTFFT_COMPRESSION_MODE_FIXED_ACCURACY | = | dtfft_compression_mode_t(4) |
Fixed accuracy compression mode |
| type(dtfft_compression_lib_t), | public, | parameter | :: | DTFFT_COMPRESSION_LIB_ZFP | = | dtfft_compression_lib_t(11) |
ZFP compression library |
| type(dtfft_compression_config_t), | public, | parameter | :: | DEFAULT_COMPRESSION_CONFIG | = | dtfft_compression_config_t(DTFFT_COMPRESSION_LIB_ZFP, DTFFT_COMPRESSION_MODE_LOSSLESS, -1.0, -1, -1.0) |
Default compression configuration |
| type(dtfft_compression_mode_t), | private, | parameter | :: | VALID_COMPRESSION_MODES(*) | = | [DTFFT_COMPRESSION_MODE_LOSSLESS, DTFFT_COMPRESSION_MODE_FIXED_RATE, DTFFT_COMPRESSION_MODE_FIXED_PRECISION, DTFFT_COMPRESSION_MODE_FIXED_ACCURACY] | |
| type(dtfft_compression_lib_t), | private, | parameter | :: | VALID_COMPRESSION_LIBS(*) | = | [DTFFT_COMPRESSION_LIB_ZFP] |
List of valid compression libraries |
Type bound constuctor for dtfft_compression_config_t
Creates a compression configuration object
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | lib |
Compression library to use |
||
| type(dtfft_compression_mode_t), | intent(in) | :: | mode |
Compression mode |
||
| real(kind=c_double), | intent(in), | optional | :: | rate |
Compression rate (for fixed rate mode) |
|
| integer(kind=c_int32_t), | intent(in), | optional | :: | precision |
Precision (for fixed precision mode) |
|
| real(kind=c_double), | intent(in), | optional | :: | tolerance |
Tolerance (for fixed accuracy mode) |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_mode_t), | intent(in) | :: | left | |||
| type(dtfft_compression_mode_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | left | |||
| type(dtfft_compression_lib_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_mode_t), | intent(in) | :: | left | |||
| type(dtfft_compression_mode_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | left | |||
| type(dtfft_compression_lib_t), | intent(in) | :: | right |
Creates the compressor implementation
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
||
| type(dtfft_compression_config_t), | intent(in) | :: | config |
Compression configuration |
||
| type(dtfft_platform_t), | intent(in) | :: | platform |
Target platform |
||
| type(MPI_Datatype), | intent(in) | :: | base_type |
MPI data type |
Performs compression using the implementation
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
||
| integer(kind=int32), | intent(in) | :: | dims(:) |
Array dimensions |
||
| type(c_ptr), | intent(in) | :: | in |
Pointer to uncompressed data |
||
| type(c_ptr), | intent(in) | :: | out |
Pointer to compressed buffer |
||
| type(dtfft_stream_t), | intent(in) | :: | stream |
Stream handle |
Performs decompression using the implementation
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
||
| integer(kind=int32), | intent(in) | :: | dims(:) |
Array dimensions |
||
| type(c_ptr), | intent(in) | :: | in |
Pointer to compressed data |
||
| type(c_ptr), | intent(in) | :: | out |
Pointer to uncompressed buffer |
||
| type(dtfft_stream_t), | intent(in) | :: | stream |
Stream handle |
Destroys the compressor implementation
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Abstract kernel |
||
| type(dtfft_stream_t), | intent(in) | :: | stream |
Abstract base class for compression implementations
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer(kind=int8), | public | :: | ndims |
Number of dimensions |
|||
| integer(kind=int64), | public | :: | storage_size |
Size of storage per element |
|||
| real(kind=real64), | public | :: | compressed_rate |
Accumulated compression rate |
|||
| integer(kind=int64), | public | :: | execution_count |
Number of compression executions |
|||
| integer(kind=int32), | public | :: | dims_permutation |
Dimension permutation flag |
| procedure, public, non_overridable, pass(self) :: create | ../../ Initializes the compressor with given parameters |
| procedure, public, non_overridable, pass(self) :: compress | ../../ Compresses the input data and returns the compressed size |
| procedure, public, non_overridable, pass(self) :: decompress | ../../ Decompresses the input data into the output buffer |
| procedure, public, non_overridable, pass(self) :: get_average_rate | ../../ Returns the average compression rate over all executions |
| procedure(sync_interface), public, deferred, pass(self) :: pre_sync | |
| procedure(sync_interface), public, deferred, pass(self) :: post_sync | |
| procedure(sync_interface), public, deferred, pass(self) :: sync | |
| procedure(create_private_interface), public, deferred, pass(self) :: create_private | ../../ Creates the compressor implementation |
| procedure(compress_private_interface), public, deferred, pass(self) :: compress_private | ../../ Performs compression using the implementation |
| procedure(decompress_private_interface), public, deferred, pass(self) :: decompress_private | ../../ Performs decompression using the implementation |
| procedure(destroy_interface), public, deferred, pass(self) :: destroy | ../../ Destroys the compressor implementation |
Type that specifies compression mode
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer(kind=c_int32_t), | public | :: | val |
Internal value |
Type that specifies compression library
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer(kind=c_int32_t), | public | :: | val |
Internal value |
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | public | :: | compression_lib |
Library to use. Currently only support ZFP |
|||
| type(dtfft_compression_mode_t), | public | :: | compression_mode |
Compression mode to use |
|||
| real(kind=c_double), | public | :: | rate |
Rate for |
|||
| integer(kind=c_int32_t), | public | :: | precision |
Precision for |
|||
| real(kind=c_double), | public | :: | tolerance |
Tolerance for |
Type bound constuctor for dtfft_compression_config_t
| private pure function create_compression_config_t (lib, mode, rate, precision, tolerance) | Creates a compression configuration object |
Checks if the given compression configuration is valid
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_config_t), | intent(in) | :: | config |
Compression configuration to check |
Creates a compression configuration object
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | lib |
Compression library to use |
||
| type(dtfft_compression_mode_t), | intent(in) | :: | mode |
Compression mode |
||
| real(kind=c_double), | intent(in), | optional | :: | rate |
Compression rate (for fixed rate mode) |
|
| integer(kind=c_int32_t), | intent(in), | optional | :: | precision |
Precision (for fixed precision mode) |
|
| real(kind=c_double), | intent(in), | optional | :: | tolerance |
Tolerance (for fixed accuracy mode) |
Initializes the compressor with given parameters
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
||
| integer(kind=int8), | intent(in) | :: | ndims |
Number of dimensions |
||
| type(dtfft_compression_config_t), | intent(in) | :: | config |
Compression configuration |
||
| type(dtfft_platform_t), | intent(in) | :: | platform |
Target platform |
||
| type(MPI_Datatype), | intent(in) | :: | base_type |
MPI data type |
||
| integer(kind=int64), | intent(in) | :: | storage_size |
Storage size per element |
||
| integer(kind=int32), | intent(in) | :: | dims_permutation |
Dimension permutation flag |
Compresses the input data and returns the compressed size
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
||
| integer(kind=int32), | intent(in) | :: | dims(:) |
Array dimensions |
||
| integer(kind=int32), | intent(in) | :: | displ |
Displacement in arrays |
||
| type(c_ptr), | intent(in) | :: | in |
Pointer to uncompressed data |
||
| type(c_ptr), | intent(in) | :: | out |
Pointer to compressed buffer |
||
| type(dtfft_stream_t), | intent(in) | :: | stream |
Stream handle |
Returns the average compression rate over all executions
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(in) | :: | self |
Compressor instance |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_mode_t), | intent(in) | :: | left | |||
| type(dtfft_compression_mode_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_mode_t), | intent(in) | :: | left | |||
| type(dtfft_compression_mode_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | left | |||
| type(dtfft_compression_lib_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | left | |||
| type(dtfft_compression_lib_t), | intent(in) | :: | right |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_mode_t), | intent(in) | :: | param |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(dtfft_compression_lib_t), | intent(in) | :: | param |
Decompresses the input data into the output buffer
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(abstract_compressor), | intent(inout) | :: | self |
Compressor instance |
||
| integer(kind=int32), | intent(in) | :: | dims(:) |
Array dimensions |
||
| integer(kind=int32), | intent(in) | :: | displ |
Displacement in arrays |
||
| type(c_ptr), | intent(in) | :: | in |
Pointer to compressed data |
||
| type(c_ptr), | intent(in) | :: | out |
Pointer to uncompressed buffer |
||
| type(dtfft_stream_t), | intent(in) | :: | stream |
Stream handle |