All Projects → benedekrozemberczki → Seal Ci

benedekrozemberczki / Seal Ci

Licence: gpl-3.0
A PyTorch implementation of "Semi-Supervised Graph Classification: A Hierarchical Graph Perspective" (WWW 2019)

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Seal Ci

Machine Learning Algorithms
A curated list of almost all machine learning algorithms and deep learning algorithms grouped by category.
Stars: ✭ 92 (-46.51%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
Machine Learning Notebooks
Machine Learning notebooks for refreshing concepts.
Stars: ✭ 222 (+29.07%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
Awesome Deep Learning And Machine Learning Questions
【不定期更新】收集整理的一些网站中(如知乎、Quora、Reddit、Stack Exchange等)与深度学习、机器学习、强化学习、数据科学相关的有价值的问题
Stars: ✭ 203 (+18.02%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
sia-cog
Various cognitive api for machine learning, vision, language intent alalysis. Covers traditional as well as deep learning model design and training.
Stars: ✭ 34 (-80.23%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
datascience-mashup
In this repo I will try to gather all of the projects related to data science with clean datasets and high accuracy models to solve real world problems.
Stars: ✭ 36 (-79.07%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
Mariana
The Cutest Deep Learning Framework which is also a wonderful Declarative Language
Stars: ✭ 151 (-12.21%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
deep-blueberry
If you've always wanted to learn about deep-learning but don't know where to start, then you might have stumbled upon the right place!
Stars: ✭ 17 (-90.12%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
Letslearnai.github.io
Lets Learn AI
Stars: ✭ 33 (-80.81%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
Echo
Python package containing all custom layers used in Neural Networks (Compatible with PyTorch, TensorFlow and MegEngine)
Stars: ✭ 126 (-26.74%)
Mutual labels:  machine-learning-algorithms, deep-learning-algorithms
Mlkit
A simple machine learning framework written in Swift 🤖
Stars: ✭ 144 (-16.28%)
Mutual labels:  machine-learning-algorithms
Machine Learning Workflow With Python
This is a comprehensive ML techniques with python: Define the Problem- Specify Inputs & Outputs- Data Collection- Exploratory data analysis -Data Preprocessing- Model Design- Training- Evaluation
Stars: ✭ 157 (-8.72%)
Mutual labels:  machine-learning-algorithms
Real Time Ml Project
A curated list of applied machine learning and data science notebooks and libraries across different industries.
Stars: ✭ 143 (-16.86%)
Mutual labels:  machine-learning-algorithms
Python Machine Learning Book
The "Python Machine Learning (1st edition)" book code repository and info resource
Stars: ✭ 11,428 (+6544.19%)
Mutual labels:  machine-learning-algorithms
C Plus Plus
Collection of various algorithms in mathematics, machine learning, computer science and physics implemented in C++ for educational purposes.
Stars: ✭ 17,151 (+9871.51%)
Mutual labels:  machine-learning-algorithms
Livianet
This repository contains the code of LiviaNET, a 3D fully convolutional neural network that was employed in our work: "3D fully convolutional networks for subcortical segmentation in MRI: A large-scale study"
Stars: ✭ 143 (-16.86%)
Mutual labels:  deep-learning-algorithms
Boostaroota
A fast xgboost feature selection algorithm
Stars: ✭ 165 (-4.07%)
Mutual labels:  machine-learning-algorithms
Awesome Quantum Machine Learning
Here you can get all the Quantum Machine learning Basics, Algorithms ,Study Materials ,Projects and the descriptions of the projects around the web
Stars: ✭ 1,940 (+1027.91%)
Mutual labels:  machine-learning-algorithms
Machine Learning Concepts
Machine Learning Concepts with Concepts
Stars: ✭ 134 (-22.09%)
Mutual labels:  machine-learning-algorithms
Numpydl
Deep Learning Library. For education. Based on pure Numpy. Support CNN, RNN, LSTM, GRU etc.
Stars: ✭ 169 (-1.74%)
Mutual labels:  deep-learning-algorithms
Machine learning
Estudo e implementação dos principais algoritmos de Machine Learning em Jupyter Notebooks.
Stars: ✭ 161 (-6.4%)
Mutual labels:  machine-learning-algorithms

SEAL

PWC codebeat badge repo sizebenedekrozemberczki⠀⠀

A PyTorch implementation of Semi-Supervised Graph Classification: A Hierarchical Graph Perspective (WWW 2019)

Abstract

Node classification and graph classification are two graph learning problems that predict the class label of a node and the class label of a graph respectively. A node of a graph usually represents a real-world entity, e.g., a user in a social network, or a protein in a protein-protein interaction network. In this work, we consider a more challenging but practically useful setting, in which a node itself is a graph instance. This leads to a hierarchical graph perspective which arises in many domains such as social network, biological network and document collection. For example, in a social network, a group of people with shared interests forms a user group, whereas a number of user groups are interconnected via interactions or common members. We study the node classification problem in the hierarchical graph where a `node' is a graph instance, e.g., a user group in the above example. As labels are usually limited in real-world data, we design two novel semi-supervised solutions named Semi-supervised graph classification via Cautious/Active Iteration (or SEAL-C/AI in short). SEAL-C/AI adopt an iterative framework that takes turns to build or update two classifiers, one working at the graph instance level and the other at the hierarchical graph level. To simplify the representation of the hierarchical graph, we propose a novel supervised, self-attentive graph embedding method called SAGE, which embeds graph instances of arbitrary size into fixed-length vectors. Through experiments on synthetic data and Tencent QQ group data, we demonstrate that SEAL-C/AI not only outperform competing methods by a significant margin in terms of accuracy/Macro-F1, but also generate meaningful interpretations of the learned representations.

This repository provides a PyTorch implementation of SEAL-CI as described in the paper:

Semi-Supervised Graph Classification: A Hierarchical Graph Perspective. Jia Li, Yu Rong, Hong Cheng, Helen Meng, Wenbing Huang, Junzhou Huang. WWW, 2019. [Paper]

A TensorFlow implementatio of the model is available [here].

Requirements

The codebase is implemented in Python 3.5.2. package versions used for development are just below.

networkx          2.4
tqdm              4.28.1
numpy             1.15.4
pandas            0.23.4
texttable         1.5.0
scipy             1.1.0
argparse          1.1.0
torch             1.1.0
torch-scatter     1.4.0
torch-sparse      0.4.3
torch-cluster     1.4.5
torch-geometric   1.3.2
torchvision       0.3.0

Datasets

Graphs

The code takes graphs for training from an input folder where each graph is stored as a JSON. Graphs used for testing are also stored as JSON files. Every node id and node label has to be indexed from 0. Keys of dictionaries are stored strings in order to make JSON serialization possible.

The graphs file has to be unzipped in the input folder.

Every JSON file has the following key-value structure:

{"edges": [[0, 1],[1, 2],[2, 3],[3, 4]],
 "features": {"0": ["A","B"], "1": ["B","K"], "2": ["C","F","A"], "3": ["A","B"], "4": ["B"]},
 "label": "A"}

The edges key has an edge list value which descibes the connectivity structure. The features key has features for each node which are stored as a dictionary -- within this nested dictionary features are list values, node identifiers are keys. The label key has a value which is the class membership.

Hierarchical graph

The hierarchical graph is stored as an edge list, where graph identifiers integers are the node identifiers. Finally, node pairs are separated by commas in the comma separated values file. This edge list file has a header.

Options

Training a SEAL-CI model is handled by the src/main.py script which provides the following command line arguments.

Input and output options

  --graphs                STR    Training graphs folder.      Default is `input/graphs/`.
  --hierarchical-graph    STR    Macro level graph.           Default is `input/synthetic_edges.csv`.

Model options

  --epochs                      INT     Number of epochs.                  Default is 10.
  --budget                      INT     Nodes to be added.                 Default is 20.
  --labeled-count               INT     Number of labeled instances.       Default is 100.
  --first-gcn-dimensions        INT     Graph level GCN 1st filters.       Default is 16.
  --second-gcn-dimensions       INT     Graph level GCN 2nd filters.       Default is 8.
  --first-dense-neurons         INT     SAGE aggregator neurons.           Default is 16.
  --second-dense-neurons        INT     SAGE attention neurons.            Default is 4.
  --macro-gcn-dimensions        INT     Macro level GCN neurons.           Default is 16.
  --weight-decay                FLOAT   Weight decay of Adam.              Defatul is 5*10^-5.
  --gamma                       FLOAT   Regularization parameter.          Default is 10^-5.
  --learning-rate               FLOAT   Adam learning rate.                Default is 0.01.

Examples

The following commands learn a model and score on the unlabaled instances. Training a model on the default dataset:

python src/main.py

Training each SEAL-CI model for a 100 epochs.

python src/main.py --epochs 100

Changing the budget size.

python src/main.py --budget 200
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].