You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/source/index.rst
+8
Original file line number
Diff line number
Diff line change
@@ -169,3 +169,11 @@ experiment with PyTorch.
169
169
170
170
`GO TO EXAMPLE <https://github.com/pytorch/examples/tree/main/mnist_forward_forward>`__ :opticon:`link-external`
171
171
172
+
---
173
+
174
+
Graph Convolutional Network
175
+
^^^^^^^^^^^^^^^^^^^^^^^^^^^
176
+
177
+
This example implements the `Semi-Supervised Classification with Graph Convolutional Networks <https://arxiv.org/pdf/1609.02907.pdf>`__ paper on the CORA database.
178
+
179
+
`GO TO EXAMPLE <https://github.com/pytorch/examples/blob/main/gcn>`__ :opticon:`link-external`
This repository contains an implementation of Graph Convolutional Networks (GCN) based on the paper "Semi-Supervised Classification with Graph Convolutional Networks" by Thomas N. Kipf and Max Welling.
4
+
5
+
## Overview
6
+
This project implements the GCN model proposed in the paper for semi-supervised node classification on graph-structured data. GCN leverages graph convolutions to aggregate information from neighboring nodes and learn node representations for downstream tasks. The implementation provides a flexible and efficient GCN model for graph-based machine learning tasks.
7
+
8
+
# Requirements
9
+
- Python 3.7 or higher
10
+
- PyTorch 2.0 or higher
11
+
- Requests 2.31 or higher
12
+
- NumPy 1.24 or higher
13
+
14
+
15
+
# Installation
16
+
```bash
17
+
pip install -r requirements.txt
18
+
python main.py
19
+
```
20
+
21
+
# Dataset
22
+
The implementation includes support for the Cora dataset, a standard benchmark dataset for graph-based machine learning tasks. The Cora dataset consists of scientific publications, where nodes represent papers and edges represent citation relationships. Each paper is associated with a binary label indicating one of seven classes. The dataset is downloaded, preprocessed and ready to use.
23
+
24
+
## Model Architecture
25
+
The GCN model architecture follows the details provided in the paper. It consists of multiple graph convolutional layers with ReLU activation, followed by a final softmax layer for classification. The implementation supports customizable hyperparameters such as the number of hidden units, the number of layers, and dropout rate.
26
+
27
+
## Usage
28
+
To train and evaluate the GCN model on the Cora dataset, use the following command:
The model achieves a classification accuracy of 82.5% on the test set of the Cora dataset after 200 epochs of training. This result is comparable to the performance reported in the original paper. However, the results can vary due to the randomness of the train/val/test split.
35
+
36
+
References
37
+
Thomas N. Kipf and Max Welling. "Semi-Supervised Classification with Graph Convolutional Networks." Link to the paper
38
+
39
+
Original paper repository: [https://github.com/tkipf/gcn](https://github.com/tkipf/gcn)
0 commit comments