skeleton for LR encoding ED model with extension of estimator #44
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Added estimators that yield neighbrouhood tensors of features and avoid using the full adjacency matrix, this can be used for single layer embeddings and breaks the scaling of attention coefficient computation with number of nodes in graph.
The core design feature of the models contributed here is that the models receive two feature input tensors
(batch, target nodes, features), (batch, target nodes, neighbors, features)
, where neighbors is padded to be constant (the max neighborhood size in data set). The adjacency matrix is then just a padding indicator(batch, target nodes, neighbors)
. Forneighbors << max nodes
this can result in desirable reduction in data communitcation to GPU and desirable intermediate tensor sizes before masking is applied via the adjacenc matrix, e.g. for attention. This only works fo rmodels with a single graph embedding layer. This implementation can be kept in parallel to the more general implementation that we already have. I recreated the Max and Gcn model layers for this type of input..set_input_features