Graph Neural Network Tensorflow implementation
Project description
This repo contains a Tensorflow implementation of the Graph Neural Network model.
Website (including documentation): https://sailab.diism.unisi.it/gnn/index.html
Install
The GNN framework requires the packages tensorflow*, **numpy, scipy
To install the requirements you can use the following command:
pip install -U -r requirements.txt
Install the latest version of GNN:
$ pip install gnn
For additional details, please see INSTALL.rst.
Simple usage example
import gnn.gnn_utils as gnn_utils import gnn.GNN as GNN import Net as n
# Provide your own functions to generate input data inp, arcnode, nodegraph, labels = set_load()
# Create the state transition function, output function, loss function and metrics net = n.Net(input_dim, state_dim, output_dim)
# Create the graph neural network model g = GNN.GNN(net, input_dim, output_dim, state_dim)
#Training
- for j in range(0, num_epoch):
g.Train(inp, arcnode, labels, count, nodegraph)
# Validate print(g.Validate(inp_val, arcnode_val, labels_val, count, nodegraph_val))
License
Released under the 3-Clause BSD license (see LICENSE)
Copyright (C) 2004-2019 Matteo Tiezzi Matteo Tiezzi <mtiezzi@diism.unisi.it> Alberto Rossi <alrossi@unifi.it>
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file gnn-1.1.1.tar.gz
.
File metadata
- Download URL: gnn-1.1.1.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: Python-urllib/3.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 765fcb2eefb5f3708cf17755bb59a1164f388d47ff4737d1aef6a4d3ef7a3652 |
|
MD5 | d3c1ca39034480008b14bdbea8bb8166 |
|
BLAKE2b-256 | 488c0facfab8968c8a7662b8e6e9c3eb298ffa250389c3856af46d3a06b5cc04 |