######### BSG Part!
z_unmask = self.encoder(x, masked_edges)
loss += alpha * F.mse_loss(z, z_unmask)
aggregated_message = self.mean_aggregator(z, edge_index=remaining_edges)
loss += beta * F.mse_loss(z, aggregated_message)
similarity_matrix_edge = self.cosine(z, aggregated_message)
loss += gamma * torch.mean(torch.relu(similarity_matrix_edge - margin))
#### We utilized the implementation of the baseline MaskGAE as our backbone structure.
Higher versions should also be available.
- numpy==1.26.3
- torch==2.1.2+cu121
- torch-cluster==1.6.3
- torch_geometric==2.4.0
- torch-scatter==2.1.2
- torch-sparse==0.6.18
- scipy==1.11.4
- texttable==1.7.0
- alpha =
$\lambda_2$ - beta =
$\lambda_1$ - gamma =
$\lambda_3$ - margin = margin
$m$
python train_link.py --dataset <dataset_name>
<dataset_name> = [Cora, Citeseer, Pubmed, Photo, Computers]
The image is the hyperparamter configuration, which corresponds to Table 6 in our paper.
example with Cora
python train_node.py --dataset Cora --alpha 0.0002 --beta 0.001 --gamma 0.0009 --margin -0.2