Git Product home page Git Product logo

cgnn's Introduction

Tensorflow Implementation of the CGNN

Code provided to reproduce the results from the article "Learning Functional Causal Models with Generative Neural Networks"

Requirements: numpy scipy scikit-learn tensorflow joblib pandas

In order to run the CGNN and launch the experiments:

  1. First install the CGNN package. Enter in the code directory. Run the command line "python setup.py install develop --user"

  2. Launch the example python script for pairwise inference: "python run_GNN_pairwise_inference.py"

  3. Launch the example python script for graph reconstruction from a skeleton: "python run_CGNN_graph.py"

  4. Launch the example python script for graph reconstruction in presence of hidden variables: "python run_CGNN_graph_hidden_variables.py"

  5. The complete datasets used in the article may be found at the following url:

Fast Pytorch implementation of CGNN available in the CDT

A faster implementation of CGNN in pytorch in available in the CausalDiscoveryToolBox (CDT)

https://github.com/Diviyan-Kalainathan/CausalDiscoveryToolbox

arXiv paper of the CDT: https://arxiv.org/abs/1903.02278

cgnn's People

Contributors

diviyank avatar goudetolivier 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cgnn's Issues

Python terminates on Importing CGNN

Dear Olivier,

I am studying your paper on causal generative neural networks, and am attempting implementation of a part of it.

This is regarding the CGNN code in your GitHub repository. I am facing an issue with the code.

I would be very grateful if you could reply and give me a bit of help.

I downloaded your CGNN repository. I followed the instructions, upgraded all packages in requirements.txt.

When I run
python setup.py install develop --user

It gives the following output
running install
running bdist_egg
running egg_info
writing cgnn.egg-info/PKG-INFO
error: [Errno 13] Permission denied: 'cgnn.egg-info/PKG-INFO'

So I installed ran the above command using sudo. The installation then goes through.

But, when I run
sudo python
>>import cgnn

The program terminates without any error.

Does this mean that the install develop step was not properly done?

Could you please help me with this issue?

If it helps,
I am using a virtual environment for python through Anaconda. Python 2.7 and Ubuntu 14.04.5 GNU/Linux 3.13.0

Please let me know if you want any more information from me.

Regards

error about implementing CGNN

Hi , dear doc, I want to know if the codes can run on tensorflow with only have CPU, since there are always some errors to imply the unsuccess of the codes, like 'Operation was explicitly assigned to /device:GPU:0 but available devices are [/job:localhost/replica:0/task:0/device:CPU:0]'
thanks!

Bugs in file CGNN.py

I find that in CGNN.py on line #292, the reverse_edge function need the parameters of the corresponding nodes of the edge. But nothing is provided in the file.

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.