Place in src/encoders/ for shared graph-based state representations.
-
Implement GAT encoder in encoders/gat_encoder.py per Reinforce-model-Paper.pdf Section V-A1. Input: node feats (coords, demands, types), edge dists. Embed to dx-dim, L GAT layers with edge-aware attention: alpha_ij = LeakyReLU(LeakyReLU(W[x_i||x_j||e_ij])). Aggregate neighbors, output node embeds + graph embed (mean pool). PyTorch Geometric. Configurable layers/heads. Test on synthetic EVRP instance from env.
-
Add simple MLP encoder baseline in encoders/mlp_encoder.py. Embed nodes independently (coords/demands/types), pool to graph embed. Compare to GAT in docstring. Make abstract Encoder base class with forward(graph) -> embeds.
Place in src/encoders/ for shared graph-based state representations.
Implement GAT encoder in encoders/gat_encoder.py per Reinforce-model-Paper.pdf Section V-A1. Input: node feats (coords, demands, types), edge dists. Embed to dx-dim, L GAT layers with edge-aware attention: alpha_ij = LeakyReLU(LeakyReLU(W[x_i||x_j||e_ij])). Aggregate neighbors, output node embeds + graph embed (mean pool). PyTorch Geometric. Configurable layers/heads. Test on synthetic EVRP instance from env.
Add simple MLP encoder baseline in encoders/mlp_encoder.py. Embed nodes independently (coords/demands/types), pool to graph embed. Compare to GAT in docstring. Make abstract Encoder base class with forward(graph) -> embeds.