Code Monkey home page Code Monkey logo

graph-generation's People

Contributors

jiaxuanyou avatar rexying avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

graph-generation's Issues

The implemented baseline issues

Many thanks for releasing the code. I have some questions regarding the GraphVAE.

  • It seems that the encoder is not using the graph neural network, the GCN layers are commented at lines 113-118 of baselines/graphvae/model.py. Am I right?

  • The binary assignment matrix has not been used after matching graphs, since self.permute_adj is also commented. if that's the case, the model is a simple Variational Graph Auto-Encoders implemented by kipf.

  • I uncommented these parts and still did not get the reported result in the GrapgRNN paper. I am not sure what could be the problem. I was wondering if this implementation of the GrapgVAE model used in the paper.

Many thanks for your help and answer.

AttributeError: 'Graph' object has no attribute 'adj'

When run

def load_graph_list(fname,is_real=True):
    with open(fname, "rb") as f:
        graph_list = pickle.load(f)  # len=100
    for i in range(len(graph_list)):
        edges_with_selfloops = graph_list[i].selfloop_edges()
        if len(edges_with_selfloops)>0:
            graph_list[i].remove_edges_from(edges_with_selfloops)
        if is_real:
            graph_list[i] = max(nx.connected_component_subgraphs(graph_list[i]), key=len)
            graph_list[i] = nx.convert_node_labels_to_integers(graph_list[i])
        else:
            graph_list[i] = pick_connected_component_new(graph_list[i])
    return graph_list

The error occurs:

AttributeError: 'Graph' object has no attribute 'adj'

Dataset problem

Hello, why the number of gragh nodes is not compatible with x, tx, allx, I need the y value of all nodes in the graph, thank you

Covariate Adjustment + Single Graph + CPU Usage

I know how to convert these torch tensors to CPU, I am curious though why the user does not have the choice to run CUDA.

Also, I have a custom graph with some covariates, how can I train on these to compare to ERGM? Particularly, what would you recommend for using covariates for graphRNN generation?

I'm just having trouble locating where to input a single graph for this pipeline, as the paper said that single or multiple graphs can be used.

Visualizing the graphs during training?

What's the best way to visualize the quality of the generated graphs at each epoch? I expected /figures or /figures_prediction to have these images but didn't get anything after training finished.

Issue of generating reciprocal edges in directed graph

Hi, thanks for open source the code! The framework can learn and generate undirected graph with high quality. But when I train the model (modified based on the suggestion given in the appendix of the paper) with directed graph, I find it cannot generate similar amount of reciprocal edges compare to the training graph I have.

Specifically, The modification I have done is double the length of edge sequence of node i as (A_1i, A_i1, A_2i, A_i2 ...), where A is the adj matrix. I do know this leads to a sparser sequence.

The graph I'm training has around 200 nodes, 659 one sided directed edges and 58 reciprocal edges, while the generated graph in average has less than 520 directed edges and 15 to 20 reciprocal edges. So the model is generating sparser graph.

I wonder if anyone has experience using this framework with directed graph, and give any advise on dealing with my issue?

Thanks in advance.

Node label generation

Hello, thank you for this excellent codebase. I find that this repo is straightforward for use in structure generation, however is there some functionality of node-label (node class) generation already supported in the codebase even though it wasn't the focus of the paper? Thanks.

Error when executing main.py

Hello,

When I execute main.py. I had the following error.

Traceback (most recent call last):
File "main.py", line 1, in
from train import *
File "/home/Documents/DeepLearning/graph-generation/train.py", line 24, in
from utils import *
File "/home/Documents/DeepLearning/graph-generation/utils.py", line 17, in
import data
File "/home/Documents/DeepLearning/graph-generation/data.py", line 17, in
from model import *
File "/home/Documents/DeepLearning/graph-generation/model.py", line 989
prob = x_prev @ x_last.permute(0,2,1)
^
SyntaxError: invalid syntax

Error on running mmsb.py and evaluation.py

Hi, I tried to run the code, but it seems like something wrong with tensorflow version and python. I used python 3.6 and tensorflow 1.2.0. Could you please reply in case you can see my question.

run graph-generation on mac

If I run the code on mac, and my mac don't have GPU. Do I have to install CUDA?

I get an error for 'AssertionError: Torch not compiled with CUDA enabled'.

GraphRNN with node feature

Firstly, thanks a lot for your perfect work, especially the comprehensive baselines. However, as you mentioned in appendix A.6, GraphRNN can be used as a node and edge feature generation. I wonder if you have finished this part in this repository?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.