Extreme-classification / GalaXC

Licence: MIT license
GalaXC: Graph Neural Networks with Labelwise Attention for Extreme Classification

Programming Languages

python
139335 projects - #7 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to GalaXC

DECAF
DECAF: Deep Extreme Classification with Label Features
Stars: ✭ 46 (+64.29%)
Mutual labels:  multi-label-classification, extreme-classification
napkinXC
Extremely simple and fast extreme multi-class and multi-label classifiers.
Stars: ✭ 38 (+35.71%)
Mutual labels:  multi-label-classification, extreme-classification
extremeText
Library for fast text representation and extreme classification.
Stars: ✭ 141 (+403.57%)
Mutual labels:  multi-label-classification, extreme-classification
omikuji
An efficient implementation of Partitioned Label Trees & its variations for extreme multi-label classification
Stars: ✭ 69 (+146.43%)
Mutual labels:  multi-label-classification, extreme-classification
3DInfomax
Making self-supervised learning work on molecules by using their 3D geometry to pre-train GNNs. Implemented in DGL and Pytorch Geometric.
Stars: ✭ 107 (+282.14%)
Mutual labels:  graph-neural-networks
multi-label-classification
machine-learning tensorflow multi-label-classification
Stars: ✭ 27 (-3.57%)
Mutual labels:  multi-label-classification
Caver
Caver: a toolkit for multilabel text classification.
Stars: ✭ 38 (+35.71%)
Mutual labels:  multi-label-classification
kaggle-human-protein-atlas-image-classification
Kaggle 2018 @ Human Protein Atlas Image Classification
Stars: ✭ 34 (+21.43%)
Mutual labels:  multi-label-classification
ntds 2019
Material for the EPFL master course "A Network Tour of Data Science", edition 2019.
Stars: ✭ 62 (+121.43%)
Mutual labels:  graph-neural-networks
grb
Graph Robustness Benchmark: A scalable, unified, modular, and reproducible benchmark for evaluating the adversarial robustness of Graph Machine Learning.
Stars: ✭ 70 (+150%)
Mutual labels:  graph-neural-networks
graph-neural-networks-for-drug-discovery
odr.chalmers.se/handle/20.500.12380/256629?locale=en
Stars: ✭ 78 (+178.57%)
Mutual labels:  graph-neural-networks
C-Tran
General Multi-label Image Classification with Transformers
Stars: ✭ 106 (+278.57%)
Mutual labels:  multi-label-classification
RioGNN
Reinforced Neighborhood Selection Guided Multi-Relational Graph Neural Networks
Stars: ✭ 46 (+64.29%)
Mutual labels:  graph-neural-networks
GNNLens2
Visualization tool for Graph Neural Networks
Stars: ✭ 155 (+453.57%)
Mutual labels:  graph-neural-networks
LR-GCCF
Revisiting Graph based Collaborative Filtering: A Linear Residual Graph Convolutional Network Approach, AAAI2020
Stars: ✭ 99 (+253.57%)
Mutual labels:  graph-neural-networks
demo-routenet
Demo of RouteNet in ACM SIGCOMM'19
Stars: ✭ 79 (+182.14%)
Mutual labels:  graph-neural-networks
zero-shot-indoor-localization-release
The official code and datasets for "Zero-Shot Multi-View Indoor Localization via Graph Location Networks" (ACMMM 2020)
Stars: ✭ 44 (+57.14%)
Mutual labels:  graph-neural-networks
Awesome Project Ideas
Curated list of Machine Learning, NLP, Vision, Recommender Systems Project Ideas
Stars: ✭ 6,114 (+21735.71%)
Mutual labels:  multi-label-classification
disentangled graph collaborative filtering
Disentagnled Graph Collaborative Filtering, SIGIR2020
Stars: ✭ 118 (+321.43%)
Mutual labels:  graph-neural-networks
SelfGNN
A PyTorch implementation of "SelfGNN: Self-supervised Graph Neural Networks without explicit negative sampling" paper, which appeared in The International Workshop on Self-Supervised Learning for the Web (SSL'21) @ the Web Conference 2021 (WWW'21).
Stars: ✭ 24 (-14.29%)
Mutual labels:  graph-neural-networks

GalaXC

GalaXC: Graph Neural Networks with Labelwise Attention for Extreme Classification

@InProceedings{Saini21,
	author       = {Saini, D. and Jain, A.K. and Dave, K. and Jiao, J. and Singh, A. and Zhang, R. and Varma, M.},
	title        = {GalaXC: Graph Neural Networks with Labelwise Attention for Extreme Classification},
	booktitle    = {Proceedings of The Web Conference},
	month = "April",
	year = "2021",
	}

Setup GalaXC

git clone https://github.com/Extreme-classification/GalaXC.git
conda env create -f GalaXC/environment.yml
conda activate galaxc
pip install hnswlib
git clone https://github.com/kunaldahiya/pyxclib.git
cd pyxclib
python setup.py install
cd ../GalaXC

Dataset Structure

Your dataset should have the following structure:

DatasetName (e.g. LF-AmazonTitles-131K)
│   trn_X.txt   (text for trn documents, one text in each line)
|   tst_X.tst   (text for tst documents, one text in each line)
|   Y.txt       (text for labels, one text in each line)
│   trn_X_Y.txt (trn labels in spmat format)
|   tst_X_Y.txt (tst labels in spmat format)
|   filter_labels_test.txt (filter labels where label and test documents are same)
│
└───XXCondensedData (embeddings for tst, trn documents and labels, for benchmark datasets, XX=DX[Astec])
    │   trn_point_embs.npy (2D numpy matrix for trn document embeddings)
    │   tst_point_embs.npy (2D numpy matrix for tst document embeddings)
    |   label_embs.npy     (2D numpy matrix for label embeddings)

We have provided the DX(embeddings from Module 1 of Astec) embeddings for public benchmark datasets for ease of use. Got better(higher recall) embeddings from somewhere? Just plug the new ones and GalaXC will have better preformance, no need to make any code change! These files for LF-AmazonTitles-131K, LF-WikiSeeAlsoTitles-320K and LF-AmazonTitles-1.3M can be found here. Except the files in DXCondensedData, all other files are copy of the datasets from The Extreme Classification Repository.

Sample Runs

To reproduce the numbers on public benchmark datasets reported in the paper, the sample runs are

LF-AmazonTitles-131K

python -u -W ignore train_main.py --dataset /your/path/to/data/LF-AmazonTitles-131K --save-model 0  --devices cuda:0  --num-epochs 30  --num-HN-epochs 0  --batch-size 256  --lr 0.001  --attention-lr 0.001 --adjust-lr 5,10,15,20,25,28  --dlr-factor 0.5  --mpt 0  --restrict-edges-num -1  --restrict-edges-head-threshold 20  --num-random-samples 30000  --random-shuffle-nbrs 0  --fanouts 4,3,2  --num-HN-shortlist 500   --embedding-type DX  --run-type NR  --num-validation 25000  --validation-freq -1  --num-shortlist 500 --predict-ova 0  --A 0.6  --B 2.6

LF-WikiSeeAlsoTitles-320K

python -u -W ignore train_main.py --dataset /your/path/to/data/LF-WikiSeeAlsoTitles-320K --save-model 0  --devices cuda:0  --num-epochs 30  --num-HN-epochs 0  --batch-size 256  --lr 0.001  --attention-lr 0.05 --adjust-lr 5,10,15,20,25,28  --dlr-factor 0.5  --mpt 0  --restrict-edges-num -1  --restrict-edges-head-threshold 20  --num-random-samples 32000  --random-shuffle-nbrs 0  --fanouts 4,3,2  --num-HN-shortlist 500  --repo 1  --embedding-type DX --run-type NR  --num-validation 25000  --validation-freq -1  --num-shortlist 500  --predict-ova 0  --A 0.55  --B 1.5

LF-AmazonTitles-1.3M

python -u -W ignore train_main.py --dataset /your/path/to/data/LF-AmazonTitles-1.3M --save-model 0  --devices cuda:0  --num-epochs 24  --num-HN-epochs 15  --batch-size 512  --lr 0.001  --attention-lr 0.05 --adjust-lr 4,8,12,16,18,20,22  --dlr-factor 0.5  --mpt 0  --restrict-edges-num 5  --restrict-edges-head-threshold 20  --num-random-samples 100000  --random-shuffle-nbrs 1  --fanouts 3,3,3  --num-HN-shortlist 500   --embedding-type DX  --run-type NR  --num-validation 25000  --validation-freq -1  --num-shortlist 500 --predict-ova 0  --A 0.6  --B 2.6

YOU MAY ALSO LIKE

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].