hwwang55 / GraphGAN

A tensorflow implementation of GraphGAN (Graph Representation Learning with Generative Adversarial Nets)
MIT License
531 stars 161 forks source link
generative-adversarial-net graph-representation-learning

GraphGAN

GraphGAN unifies two schools of graph representation learning methodologies: generative methods and discriminative methods, via adversarial training in a minimax game. The generator is guided by the signals from the discriminator and improves its generating performance, while the discriminator is pushed by the generator to better distinguish ground truth from generated samples.

Files in the folder

Requirements

The code has been tested running under Python 3.6.5, with the following packages installed (along with their dependencies):

Input format

The input data should be an undirected graph in which node IDs start from 0 to N-1 (N is the number of nodes in the graph). Each line contains two node IDs indicating an edge in the graph.

txt file sample

0 1
3 2
...

Basic usage

mkdir cache
cd src/GraphGAN
python graph_gan.py