b52e083827ce7aefda75c4370db0ad6942e27dae,stellar/mapper/node_mappers.py,HinSAGENodeMapper,__getitem__,#HinSAGENodeMapper#Any#,355
Before Change
batch_targets = None
// Get sampling schema for head nodes
sampling_schema = self._sampling_schema
if sampling_schema is None:
head_node_types = set([self.schema.get_node_type(n) for n in head_nodes])
if len(head_node_types) > 1:
raise ValueError(
"Only a single head node type is currently supported for HinSAGE models"
)
After Change
]
// Resize features to (batch_size, n_neighbours, feature_size)
batch_feats = [
np.reshape(a, (len(head_nodes), -1 if np.size(a) > 0 else 0, a.shape[1]))
for a in batch_feats
]
return batch_feats, batch_targets
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 10
Instances
Project Name: stellargraph/stellargraph
Commit Name: b52e083827ce7aefda75c4370db0ad6942e27dae
Time: 2018-08-12
Author: docherty@gmail.com
File Name: stellar/mapper/node_mappers.py
Class Name: HinSAGENodeMapper
Method Name: __getitem__
Project Name: reinforceio/tensorforce
Commit Name: b0fd7d13ff1392c60dfef432bfea7a7dd035f71f
Time: 2017-07-29
Author: aok25@cl.cam.ac.uk
File Name: tensorforce/models/vpg_model.py
Class Name: VPGModel
Method Name: create_tf_operations
Project Name: reinforceio/tensorforce
Commit Name: b0fd7d13ff1392c60dfef432bfea7a7dd035f71f
Time: 2017-07-29
Author: aok25@cl.cam.ac.uk
File Name: tensorforce/models/dqfd_model.py
Class Name: DQFDModel
Method Name: create_tf_operations