database_client_interface module reference
Data Types
Dummy type for dataset |
|
Stores all data and methods associated with the communication client that is used to communicate with the database |
Functions/Subroutines
Decode a response code from an API function |
|
Initializes a new instance of a communication client |
|
Check whether the client has been initialized |
|
A destructor for the communication client |
|
Put a 32-bit real 1d tensor into the database |
|
Put a 32-bit real 2d tensor into the database |
|
Put a 32-bit real 3d tensor into the database |
|
Put a 32-bit real 4d tensor into the database |
|
Put a 64-bit real 1d tensor into the database |
|
Put a 64-bit real 2d tensor into the database |
|
Put a 64-bit real 3d tensor into the database |
|
Put a 64-bit real 4d tensor into the database |
|
Put a 32-bit integer 1d tensor into the database |
|
Put a 32-bit integer 2d tensor into the database |
|
Put a 32-bit integer 3d tensor into the database |
|
Put a 32-bit integer 4d tensor into the database |
|
Unpack a 32-bit real 1d tensor from the database |
|
Unpack a 32-bit real 2d tensor from the database |
|
Unpack a 32-bit real 3d tensor from the database |
|
Unpack a 32-bit real 4d tensor from the database |
|
Unpack a 64-bit real 1d tensor from the database |
|
Unpack a 64-bit real 2d tensor from the database |
|
Unpack a 64-bit real 3d tensor from the database |
|
Unpack a 64-bit real 4d tensor from the database |
|
Unpack a 32-bit integer 1d tensor from the database |
|
Unpack a 32-bit integer 2d tensor from the database |
|
Unpack a 32-bit integer 3d tensor from the database |
|
Unpack a 32-bit integer 4d tensor from the database |
|
Move a tensor to a new name |
|
Delete a tensor |
|
Copy a tensor to the destination name |
|
Retrieve the model from the database |
|
Load the machine learning model from a file and set the configuration |
|
Load the machine learning model from a file and set the configuration for use in multi-GPU systems |
|
Establish a model to run |
|
Set a model from a byte string to run on a system with multiple GPUs |
|
Run a model in the database using the specified input and output tensors |
|
Run a model in the database using the specified input and output tensors in a multi-GPU system |
|
Remove a model from the database |
|
Remove a model from the database |
|
Retrieve the script from the database |
|
Set a script (from file) in the database for future execution |
|
Set a script (from file) in the database for future execution in a multi-GPU system |
|
Set a script (from buffer) in the database for future execution |
|
Set a script (from buffer) in the database for future execution in a multi-GPU system |
|
Remove a script from the database |
|
Remove a script_multigpu from the database |
|
Store a dataset in the database |
|
Retrieve a dataset from the database |
|
Rename a dataset stored in the database |
|
Copy a dataset within the database to a new name |
|
Delete a dataset stored within a database |
|
Appends a dataset to the aggregation list When appending a dataset to an aggregation list, the list will automatically be created if it does not exist (i.e. this is the first entry in the list). Aggregation lists work by referencing the dataset by storing its key, so appending a dataset to an aggregation list does not create a copy of the dataset. Also, for this reason, the dataset must have been previously placed into the database with a separate call to put_dataset(). |
|
Delete an aggregation list |
|
Copy an aggregation list |
|
Rename an aggregation list |
Type Documentation
- type, public :: dataset_type
Dummy type for dataset
- type, public :: dbclient_type
Stores all data and methods associated with the communication client that is used to communicate with the database
Functions/Subroutine Documentation
- function SR_error_parser(self, response_code) result(is_error)
Decode a response code from an API function
- Parameters
self [in]
Receives the initialized client
response_code [in]
The response code to decode
is_error
Indicates whether this is an error response
- function initialize_client(self, cluster)
Initializes a new instance of a communication client
- Parameters
self [inout]
Receives the initialized client
cluster [in]
If true, client uses a database cluster (Default: .false.)
- logical function isinitialized(this)
Check whether the client has been initialized
- function destructor(self)
A destructor for the communication client
- function put_tensor_float_1d(self, name, data, dims) result(code)
Put a 32-bit real 1d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_float_2d(self, name, data, dims) result(code)
Put a 32-bit real 2d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_float_3d(self, name, data, dims) result(code)
Put a 32-bit real 3d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_float_4d(self, name, data, dims) result(code)
Put a 32-bit real 4d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_double_1d(self, name, data, dims) result(code)
Put a 64-bit real 1d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_double_2d(self, name, data, dims) result(code)
Put a 64-bit real 2d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_double_3d(self, name, data, dims) result(code)
Put a 64-bit real 3d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_double_4d(self, name, data, dims) result(code)
Put a 64-bit real 4d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_int32_1d(self, name, data, dims) result(code)
Put a 32-bit integer 1d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_int32_2d(self, name, data, dims) result(code)
Put a 32-bit integer 2d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_int32_3d(self, name, data, dims) result(code)
Put a 32-bit integer 3d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function put_tensor_int32_4d(self, name, data, dims) result(code)
Put a 32-bit integer 4d tensor into the database
- Parameters
data [in]
Data to be sent
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_float_1d(self, name, data, dims) result(code)
Unpack a 32-bit real 1d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_float_2d(self, name, data, dims) result(code)
Unpack a 32-bit real 2d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_float_3d(self, name, data, dims) result(code)
Unpack a 32-bit real 3d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_float_4d(self, name, data, dims) result(code)
Unpack a 32-bit real 4d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_double_1d(self, name, data, dims) result(code)
Unpack a 64-bit real 1d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_double_2d(self, name, data, dims) result(code)
Unpack a 64-bit real 2d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_double_3d(self, name, data, dims) result(code)
Unpack a 64-bit real 3d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_double_4d(self, name, data, dims) result(code)
Unpack a 64-bit real 4d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_int32_1d(self, name, data, dims) result(code)
Unpack a 32-bit integer 1d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_int32_2d(self, name, data, dims) result(code)
Unpack a 32-bit integer 2d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_int32_3d(self, name, data, dims) result(code)
Unpack a 32-bit integer 3d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function unpack_tensor_int32_4d(self, name, data, dims) result(code)
Unpack a 32-bit integer 4d tensor from the database
- Parameters
data [out]
Data to be received
self [in]
Fortran communication client
name [in]
The unique name used to store in the database
dims [in]
The length of each dimension
- function rename_tensor(self, old_name, new_name) result(code)
Move a tensor to a new name
- Parameters
self [in]
The initialized Fortran communication client
old_name [in]
The current name for the tensor excluding null terminating character
new_name [in]
The new tensor name
- function delete_tensor(self, name) result(code)
Delete a tensor
- Parameters
self [in]
The initialized Fortran communication client
name [in]
The name associated with the tensor
- function copy_tensor(self, src_name, dest_name) result(code)
Copy a tensor to the destination name
- Parameters
self [in]
The initialized Fortran communication client
src_name [in]
The name associated with the tensor excluding null terminating character
dest_name [in]
The new tensor name
- function get_model(self, name, model) result(code)
Retrieve the model from the database
- Parameters
self [in]
An initialized communication client
name [in]
The name associated with the model
model [out]
The model as a continuous buffer
- function set_model_from_file(self, name, model_file, backend, device, batch_size, min_batch_size, tag, inputs, outputs) result(code)
Load the machine learning model from a file and set the configuration
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the model
model_file [in]
The file storing the model
backend [in]
The name of the backend (TF, TFLITE, TORCH, ONNX)
device [in]
The name of the device (CPU, GPU, GPU:0, GPU:1...)
batch_size [in]
The batch size for model execution
min_batch_size [in]
The minimum batch size for model execution
tag [in]
A tag to attach to the model for information purposes
inputs [in]
One or more names of model input nodes (TF models)
outputs [in]
One or more names of model output nodes (TF models)
- function set_model_from_file_multigpu(self, name, model_file, backend, first_gpu, num_gpus, batch_size, min_batch_size, tag, inputs, outputs) result(code)
Load the machine learning model from a file and set the configuration for use in multi-GPU systems
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the model
model_file [in]
The file storing the model
backend [in]
The name of the backend (TF, TFLITE, TORCH, ONNX)
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
batch_size [in]
The batch size for model execution
min_batch_size [in]
The minimum batch size for model execution
tag [in]
A tag to attach to the model for information purposes
inputs [in]
One or more names of model input nodes (TF models)
outputs [in]
One or more names of model output nodes (TF models)
- function set_model(self, name, model, backend, device, batch_size, min_batch_size, tag, inputs, outputs) result(code)
Establish a model to run
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the model
model [in]
The binary representation of the model
backend [in]
The name of the backend (TF, TFLITE, TORCH, ONNX)
device [in]
The name of the device (CPU, GPU, GPU:0, GPU:1...)
batch_size [in]
The batch size for model execution
min_batch_size [in]
The minimum batch size for model execution
tag [in]
A tag to attach to the model for information purposes
inputs [in]
One or more names of model input nodes (TF models)
outputs [in]
One or more names of model output nodes (TF models)
- function set_model_multigpu(self, name, model, backend, first_gpu, num_gpus, batch_size, min_batch_size, tag, inputs, outputs) result(code)
Set a model from a byte string to run on a system with multiple GPUs
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the model
model [in]
The binary representation of the model
backend [in]
The name of the backend (TF, TFLITE, TORCH, ONNX)
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
batch_size [in]
The batch size for model execution
min_batch_size [in]
The minimum batch size for model execution
tag [in]
A tag to attach to the model for information purposes
inputs [in]
One or more names of model input nodes (TF models)
outputs [in]
One or more names of model output nodes (TF models)
- function run_model(self, name, inputs, outputs) result(code)
Run a model in the database using the specified input and output tensors
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the model
inputs [in]
One or more names of model input nodes (TF models)
outputs [in]
One or more names of model output nodes (TF models)
- function run_model_multigpu(self, name, inputs, outputs, offset, first_gpu, num_gpus) result(code)
Run a model in the database using the specified input and output tensors in a multi-GPU system
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the model
inputs [in]
One or more names of model input nodes (TF models)
outputs [in]
One or more names of model output nodes (TF models)
offset [in]
Index of the current image, such as a processor ID or MPI rank
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
- function delete_model(self, name) result(code)
Remove a model from the database
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to remove the model
- function delete_model_multigpu(self, name, first_gpu, num_gpus) result(code)
Remove a model from the database
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to remove the model
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
- function get_script(self, name, script) result(code)
Retrieve the script from the database
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
script [out]
The script as a continuous buffer
- function set_script_from_file(self, name, device, script_file) result(code)
Set a script (from file) in the database for future execution
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
device [in]
The name of the device (CPU, GPU, GPU:0, GPU:1...)
script_file [in]
The file storing the script
- function set_script_from_file_multigpu(self, name, script_file, first_gpu, num_gpus) result(code)
Set a script (from file) in the database for future execution in a multi-GPU system
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
script_file [in]
The file storing the script
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
- function set_script(self, name, device, script) result(code)
Set a script (from buffer) in the database for future execution
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
device [in]
The name of the device (CPU, GPU, GPU:0, GPU:1...)
script [in]
The file storing the script
- function set_script_multigpu(self, name, script, first_gpu, num_gpus) result(code)
Set a script (from buffer) in the database for future execution in a multi-GPU system
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
script [in]
The file storing the script
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
function run_script(self, name, func, inputs, outputs) result(code)
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
func [in]
The name of the function in the script to call
inputs [in]
One or more names of script input nodes (TF scripts)
outputs [in]
One or more names of script output nodes (TF scripts)
function run_script_multigpu(self, name, func, inputs, outputs, offset, first_gpu, num_gpus) result(code)
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to place the script
func [in]
The name of the function in the script to call
inputs [in]
One or more names of script input nodes (TF scripts)
outputs [in]
One or more names of script output nodes (TF scripts)
offset [in]
Index of the current image, such as a processor ID or MPI rank
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
- function delete_script(self, name) result(code)
Remove a script from the database
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to delete the script
- function delete_script_multigpu(self, name, first_gpu, num_gpus) result(code)
Remove a script_multigpu from the database
- Parameters
self [in]
An initialized communication client
name [in]
The name to use to delete the script_multigpu
first_gpu [in]
The first GPU (zero-based) to use with the model
num_gpus [in]
The number of GPUs to use with the model
- function put_dataset(self, dataset) result(code)
Store a dataset in the database
- Parameters
self [in]
An initialized communication client
dataset [in]
Dataset to store in the dataset
- function get_dataset(self, name, dataset) result(code)
Retrieve a dataset from the database
- Parameters
self [in]
An initialized communication client
name [in]
Name of the dataset to get
dataset [out]
receives the dataset
- function rename_dataset(self, name, new_name) result(code)
Rename a dataset stored in the database
- Parameters
self [in]
An initialized communication client
name [in]
Original name of the dataset
new_name [in]
New name of the dataset
- function copy_dataset(self, name, new_name) result(code)
Copy a dataset within the database to a new name
- Parameters
self [in]
An initialized communication client
name [in]
Source name of the dataset
new_name [in]
Name of the new dataset
- function delete_dataset(self, name) result(code)
Delete a dataset stored within a database
- Parameters
self [in]
An initialized communication client
name [in]
Name of the dataset to delete
- function append_to_list(self, list_name, dataset) result(code)
Appends a dataset to the aggregation list When appending a dataset to an aggregation list, the list will automatically be created if it does not exist (i.e. this is the first entry in the list). Aggregation lists work by referencing the dataset by storing its key, so appending a dataset to an aggregation list does not create a copy of the dataset. Also, for this reason, the dataset must have been previously placed into the database with a separate call to put_dataset().
- Parameters
self [in]
An initialized communication client
list_name [in]
Name of the dataset to get
dataset [in]
Dataset to append to the list
- function delete_list(self, list_name) result(code)
Delete an aggregation list
- Parameters
self [in]
An initialized communication client
list_name [in]
Name of the aggregated dataset list to delete
- function copy_list(self, src_name, dest_name) result(code)
Copy an aggregation list
- Parameters
self [in]
An initialized communication client
src_name [in]
Name of the dataset to copy
dest_name [in]
The new list name
- function rename_list(self, src_name, dest_name) result(code)
Rename an aggregation list
- Parameters
self [in]
An initialized communication client
src_name [in]
Name of the dataset to rename
dest_name [in]
The new list name