Skip to content

About

Code and data to reproduce the results of the Digraphwave paper.

Resources

Stars

1 star

Watchers

1 watching

Forks

Repository files navigation

Digraphwave Experiments

A repo containing the experiments for the Digraphwave preprint https://arxiv.org/abs/2207.10149. Please use the citation below if you use this code for your research.

Citation (bibtex):

@misc{ceylan2022digraphwave,
      title={Digraphwave: Scalable Extraction of Structural Node Embeddings via Diffusion on Directed Graphs}, 
      author={Ciwan Ceylan and Kambiz Ghoorchian and Danica Kragic},
      year={2022},
      eprint={2207.10149},
      archivePrefix={arXiv},
      primaryClass={cs.SI},
      doi={https://doi.org/10.48550/arXiv.2207.10149}
}

Setup

Prepare environments

Two different experiment environments are used. A python2 environment for Graphwave and EMBER, and a python3 environment for the other methods. There is also an extra environment used for some visualisations (digraphwave_python3_with_full_gt_env).

Create all the environments so that they are available.

conda env create --file conda_env_files/digraphwave_experiment_python2_env.yml
conda env create --file conda_env_files/digraphwave_experiment_python3_env.yml
codda env create --file conda_env_files/digraphwave_python3_with_full_gt_env.yml

Install Digraphwave and ReFeX in the python3 environment

conda activate digraphwave_experiment_python3_env
pip install ./algorithms/rolx-refex
pip install ./algorithms/digraphwave

Experiments

All experiments restuls are available in ./results. To rerun the experiments, first create a new results folder.

mkdir ./new_results

Then use the commands below to rerun all the experiments. Note that default parameter may expect certain hardware to be available, e.g., 3 GPUs for the Enron experiments.

Scalability experiment

conda activate digraphwave_experiment_python3_env
python python scalability_benchmarks.py algs -w ./new_results

Ablation

conda activate digraphwave_experiment_python3_env
python synthetic_data_benchmarks.py ablation -w ./new_results

Quality comparison on synthetic data

conda activate digraphwave_experiment_python3_env
python synthetic_data_benchmarks.py algs -w ./new_results

Enron node classification

conda activate digraphwave_experiment_python3_env
python enron_node_classification.py 128 --weighted --simplified -w ./new_results
python enron_node_classification.py 128 --simplified -w ./new_results
python enron_node_classification.py 128 --weighted --undirected --simplified -w ./new_results
python enron_node_classification.py 128 --undirected --simplified -w ./new_results

Network alignment

python alignment_experiments.py $experiment $weighted $undirected -w $RESULTS_ROOT

conda activate digraphwave_experiment_python3_env
python alignment_experiments.py enron_all_internal --weighted -w ./new_results
python alignment_experiments.py enron_all_internal -w ./new_results
python alignment_experiments.py enron_all_internal --weighted --undirected -w ./new_results
python alignment_experiments.py enron_all_internal --undirected -w ./new_results
python alignment_experiments.py arxiv --undirected -w ./new_results

Datasets

Synthetic dataset

The synthetic dataset is found in ./data/synthetic. The folders contain the edge list and automorphic identity labels for each graph. Moreover, ./data/synthetic/composed contains the composed graphs (circular and attached synthetic graphs) used for the experiments.

The file ./data/synthetic/create_synthetic_data.py can be used to create the synthetic dataset from scratch:

conda activate digraphwave_python3_with_full_gt_env
cd ./some/workdir
python ./data/synthetic/create_synthetic_data.py

And the file The file ./src/utils/synthetic_dataset.py can be used generate composed graphs.

About

Code and data to reproduce the results of the Digraphwave paper.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages