Skip to content
forked from ColaLL/ABNE

The code and dataset for paper "ABNE: An Attention Based Network Embedding for User Alignment Across Social Networks"

Notifications You must be signed in to change notification settings

treenewbee0/ABNE

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ABNE

The code and dataset for paper "ABNE: An Attention Based Network Embedding for User Alignment Across Social Networks"

With the permission of sharing anonymous twitter_foursquare data from Prof.Jiawei Zhang, we share the anonymous data and code of IONE here. Note that the data and code only can be used for research purposes.

When running the code, firstly check the Vars.java to make sure that the path of the data is correct.

Description of Data directory

AcrossNetworkEmbeddingData

foursquare:

following.number: the relation file, "1 2" means user 1 is the follower of user 2.

embeddings directory for storing the embedding generated by ABNE model.

twitter:

the same as the foursquare fold

twitter_foursquare_groundtruth:

groundtruth.x.foldtrain.train.number, the traning anchors, which are the 0.x of all the anchors.

groundtruth.x.foldtrain.test.number, the testing anchors, which are the 1-0.x of all the anchors.

Note that users only appear in the "groundtruth.number" file are the training anchors (even there are some uses have same ids, they are not anchors)

Model Running

Run the ABNE.java for the embeddings. There are several parameters in the main function: attention_epoch for the Vanilla_Attn iteration, embedding_epoch for embedding algorithm iteration, total_iter for the outmost iteration, dimension for the dimensions, train_ratio for the training set ratio.

Generated Files

There are several file generated after runing the ABNE.java

Embedding files (in embeddings directory of twitter/foursquare):

twitter(foursquare).ABNE(Attn).embedding.$total_iter$_itercount.$train_ratio$.number.$dimension$_dim.$embedding_epoch$

is the ABNE(Attn) embedding file for twitter(foursquare). The exact filename is based on the parameter setttings.

For instance, twitter.Attn.embedding.2_itercount.9.number.100_dim.10000000

Besides, there are other attention relation files generated in the twitter/foursquare directory

following.number.$train_ratio$.attn

For instance, following.number.9.attn

based on the train_ratio parameter settings.

For evaluation

Run the getPrecision.java for evaluation, here we provide a sample for the ABEN model with dimension=100 and train_ratio=9. If you want to get results with other parameter settings, pls change the temp_string as the corresponding generated embedding file.

By the way, the you can find the IONE model at https://github.com/ColaLL/IONE which is used as one baseline in this paper

Feel free to contact me (Liu Li liuli0407@hotmail.com) when you have any problems about the paper or the code.

About

The code and dataset for paper "ABNE: An Attention Based Network Embedding for User Alignment Across Social Networks"

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%