Coverage Control Library
Loading...
Searching...
No Matches
LPAC Class Reference

LPAC neural network architecture. More...

+ Inheritance diagram for LPAC:

Public Member Functions

 __init__ (self, in_config)
 
torch.Tensor forward (self, torch_geometric.data.Data data)
 Forward pass of the LPAC model.
 
None load_compiled_state_dict (self, str model_state_dict_path)
 
None load_model (self, str model_state_dict_path)
 Load the model from the state dict.
 
None load_model_state_dict (self, dict model_state_dict)
 Load the model from the state dict.
 
None load_cnn_backbone (self, str model_path)
 Load the CNN backbone from the model path.
 
None load_gnn_backbone (self, str model_path)
 Load the GNN backbone from the model path.
 
- Public Member Functions inherited from GNNConfigParser
None parse (self, dict config)
 Parse the configuration for the GNN model.
 

Public Attributes

 cnn_config = in_config["CNNBackBone"]
 
 cnn_backbone = CNNBackBone(self.cnn_config)
 
 gnn_backbone = GNNBackBone(self.config, self.cnn_backbone.latent_size + 2)
 
 gnn_mlp = MLP([self.latent_size, 32, 32])
 
 output_linear = torch.nn.Linear(32, self.output_dim)
 
 output_dim
 
- Public Attributes inherited from GNNConfigParser
 config = None
 
 input_dim = None
 
 output_dim = None
 
 num_hops = None
 
 num_layers = None
 
 latent_size = None
 

Detailed Description

LPAC neural network architecture.

Definition at line 40 of file lpac.py.

Constructor & Destructor Documentation

◆ __init__()

__init__ ( self,
in_config )

Reimplemented from GNNConfigParser.

Definition at line 41 of file lpac.py.

Member Function Documentation

◆ forward()

torch.Tensor forward ( self,
torch_geometric.data.Data data )

Forward pass of the LPAC model.

Definition at line 59 of file lpac.py.

◆ load_cnn_backbone()

None load_cnn_backbone ( self,
str model_path )

Load the CNN backbone from the model path.

Definition at line 106 of file lpac.py.

◆ load_compiled_state_dict()

None load_compiled_state_dict ( self,
str model_state_dict_path )

Definition at line 83 of file lpac.py.

◆ load_gnn_backbone()

None load_gnn_backbone ( self,
str model_path )

Load the GNN backbone from the model path.

Definition at line 112 of file lpac.py.

◆ load_model()

None load_model ( self,
str model_state_dict_path )

Load the model from the state dict.

Definition at line 94 of file lpac.py.

◆ load_model_state_dict()

None load_model_state_dict ( self,
dict model_state_dict )

Load the model from the state dict.

Definition at line 100 of file lpac.py.

Member Data Documentation

◆ cnn_backbone

cnn_backbone = CNNBackBone(self.cnn_config)

Definition at line 45 of file lpac.py.

◆ cnn_config

cnn_config = in_config["CNNBackBone"]

Definition at line 43 of file lpac.py.

◆ gnn_backbone

gnn_backbone = GNNBackBone(self.config, self.cnn_backbone.latent_size + 2)

Definition at line 46 of file lpac.py.

◆ gnn_mlp

gnn_mlp = MLP([self.latent_size, 32, 32])

Definition at line 50 of file lpac.py.

◆ output_dim

output_dim

Definition at line 53 of file lpac.py.

◆ output_linear

output_linear = torch.nn.Linear(32, self.output_dim)

Definition at line 51 of file lpac.py.