Module containing types and interfaces for the container type
This module contains the container layer type which is a container for an individual layer.
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| type(read_layer_container), | public, | dimension(:), allocatable | :: | list_of_layer_types |
List of layer names and their associated read functions |
||
| type(onnx_expanded_gnn_create_layer_container), | public, | dimension(:), allocatable | :: | list_of_onnx_expanded_gnn_layer_creators |
List of expanded-ONNX GNN creators |
||
| type(onnx_expanded_nop_create_layer_container), | public, | dimension(:), allocatable | :: | list_of_onnx_expanded_nop_layer_creators |
List of expanded-ONNX NOP creators registered for pattern-matched ONNX import |
||
| type(onnx_create_layer_container), | public, | dimension(:), allocatable | :: | list_of_onnx_layer_creators |
List of layer names and their associated ONNX creation functions |
||
| type(onnx_meta_create_layer_container), | public, | dimension(:), allocatable | :: | list_of_onnx_meta_layer_creators |
List of metadata subtypes and their associated ONNX creation functions |
Allocate the list of layer types
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(read_layer_container), | intent(in), | optional, | dimension(:) | :: | addit_list |
Additional list of layer types |
Allocate the list of expanded-ONNX GNN layer creation procedures
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(onnx_expanded_gnn_create_layer_container), | intent(in), | optional, | dimension(:) | :: | addit_list |
Additional list of expanded-ONNX GNN layer creation procedures |
Allocate the list of expanded-ONNX NOP layer creation procedures
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(onnx_expanded_nop_create_layer_container), | intent(in), | optional, | dimension(:) | :: | addit_list |
Additional list of expanded-ONNX NOP layer creation procedures |
Allocate the list of ONNX layer creation procedures
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(onnx_create_layer_container), | intent(in), | optional, | dimension(:) | :: | addit_list |
Additional list of ONNX layer creation procedures |
Allocate the list of metadata-based ONNX layer creation procedures
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(onnx_meta_create_layer_container), | intent(in), | optional, | dimension(:) | :: | addit_list |
Additional list of metadata-based ONNX layer creation procedures |
Reduce two layers via summation
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(container_layer_type), | intent(inout) | :: | this |
Present layer container |
||
| class(container_layer_type), | intent(in) | :: | rhs |
Input layer container |
Create a layer from ONNX nodes and initialisers
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(onnx_node_type), | intent(in) | :: | nodes |
ONNX nodes |
||
| type(onnx_initialiser_type), | intent(in), | dimension(:) | :: | initialisers |
ONNX initialisers |
|
| type(onnx_tensor_type), | intent(in), | dimension(:) | :: | value_info |
ONNX value info |
|
| integer, | intent(in), | optional | :: | verbose |
Verbosity level |
Instance of a layer
Finalise the container layer
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(container_layer_type), | intent(inout) | :: | this |
Present layer container |
Read a layer from a file
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | unit |
Unit number |
||
| integer, | intent(in), | optional | :: | verbose |
Verbosity level |
Instance of a layer
Build one expanded-ONNX GNN layer from a node cluster.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | prefix |
Expanded-ONNX layer prefix (e.g. "node_2") |
||
| type(onnx_node_type), | intent(in) | :: | nodes(:) |
Parsed ONNX nodes |
||
| integer, | intent(in) | :: | num_nodes |
Number of valid node entries |
||
| type(onnx_initialiser_type), | intent(in) | :: | inits(:) |
Parsed ONNX initialisers |
||
| integer, | intent(in) | :: | num_inits |
Number of valid initialiser entries |
||
| type(onnx_tensor_type), | intent(in) | :: | inputs(:) |
Parsed ONNX graph input tensors |
||
| integer, | intent(in) | :: | num_inputs |
Number of valid graph input entries |
Constructed layer
Build one expanded-ONNX NOP layer from a node cluster.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | prefix |
Expanded-ONNX layer prefix (e.g. "layer1") |
||
| type(onnx_node_type), | intent(in) | :: | nodes(:) |
Parsed ONNX nodes |
||
| integer, | intent(in) | :: | num_nodes |
Number of valid node entries |
||
| type(onnx_initialiser_type), | intent(in) | :: | inits(:) |
Parsed ONNX initialisers |
||
| integer, | intent(in) | :: | num_inits |
Number of valid initialiser entries |
Constructed layer
Return true when this creator handles the given expanded-ONNX GNN prefix.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | prefix |
Expanded-ONNX layer prefix (e.g. "node_2") |
||
| type(onnx_node_type), | intent(in) | :: | nodes(:) |
Parsed ONNX nodes |
||
| integer, | intent(in) | :: | num_nodes |
Number of valid node entries |
Return true when this creator handles the given expanded-ONNX NOP prefix.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | prefix |
Expanded-ONNX layer prefix (e.g. "layer1") |
||
| type(onnx_node_type), | intent(in) | :: | nodes(:) |
Parsed ONNX nodes |
||
| integer, | intent(in) | :: | num_nodes |
Number of valid node entries |
Create a GNN layer from ONNX metadata and initialisers
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | meta_key |
GNN metadata key (e.g. "athena_gnn_node_1") |
||
| character(len=*), | intent(in) | :: | meta_value |
Semicolon-separated GNN metadata value string |
||
| type(onnx_initialiser_type), | intent(in), | dimension(:) | :: | inits |
ONNX initialisers (valid slice only) |
|
| integer, | intent(in), | optional | :: | verbose |
Verbosity level |
Constructed GNN layer
Container for a layer
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| class(base_layer_type), | public, | allocatable | :: | layer |
Layer |
| final :: finalise_container_layer | Finalise the container layer |
| procedure, public, pass(this) :: reduce => container_reduction | Reduce two layers via summation |
Type containing information needed to create a layer from ONNX
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| procedure(create_from_onnx_layer), | public, | nopass, pointer | :: | create_ptr | => | null() |
Pointer to the specific layer creation function from ONNX |
| character(len=20), | public | :: | op_type |
Name of the layer |
Registration entry for one expanded-ONNX GNN layer type
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| procedure(build_onnx_expanded_gnn_layer), | public, | nopass, pointer | :: | build_ptr | => | null() |
Pointer to the builder |
| procedure(classify_onnx_expanded_gnn_layer), | public, | nopass, pointer | :: | classify_ptr | => | null() |
Pointer to the classifier |
| character(len=30), | public | :: | gnn_subtype |
Subtype name (e.g. "kipf", "duvenaud") |
Registration entry for one expanded-ONNX NOP layer type
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| procedure(build_onnx_expanded_nop_layer), | public, | nopass, pointer | :: | build_ptr | => | null() |
Pointer to the builder that constructs the layer |
| procedure(classify_onnx_expanded_nop_layer), | public, | nopass, pointer | :: | classify_ptr | => | null() |
Pointer to the classifier that recognises this layer type |
| character(len=30), | public | :: | nop_subtype |
Subtype name used for diagnostics (e.g. "dynamic_lno") |
Type containing information needed to create a metadata layer from ONNX
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| procedure(create_gnn_from_onnx_layer), | public, | nopass, pointer | :: | create_ptr | => | null() |
Pointer to the metadata layer creation function |
| character(len=30), | public | :: | layer_subtype |
Metadata subtype name (e.g. "duvenaud", "dynamic_lno") |
Type containing information needed to read a layer
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| character(len=20), | public | :: | name |
Name of the layer |
|||
| procedure(read_layer), | public, | nopass, pointer | :: | read_ptr | => | null() |
Pointer to the specific layer read function |