[AAAI 2022] Sparse Structure Learning via Graph Neural Networks for Inductive Document Classification

Overview

Sparse Structure Learning via Graph Neural Networks for inductive document classification

Make graph dataset

  1. create co-occurrence graph for datasets.

    python ssl_make_graphs/create_cooc_document.py --raw_path SOURCEPATH --pre_path TARGETPATH --task DATASET --partition TRAINorTEST --window_size SIZE
    
  2. construct in memory graph datsets.

    python ssl_make_graphs/PygDocsGraphDatset.py --raw_path SOURCEPATH --task DATASET 
    

Reproduce

python ssl_graphmodels/pyg_models/train_docs.py
You might also like...
Source code for paper "Document-Level Relation Extraction with Adaptive Thresholding and Localized Context Pooling", AAAI 2021

ATLOP Code for AAAI 2021 paper Document-Level Relation Extraction with Adaptive Thresholding and Localized Context Pooling. If you make use of this co

Focal Sparse Convolutional Networks for 3D Object Detection (CVPR 2022, Oral)
Focal Sparse Convolutional Networks for 3D Object Detection (CVPR 2022, Oral)

Focal Sparse Convolutional Networks for 3D Object Detection (CVPR 2022, Oral) This is the official implementation of Focals Conv (CVPR 2022), a new sp

Study of human inductive biases in CNNs and Transformers.
Study of human inductive biases in CNNs and Transformers.

Are Convolutional Neural Networks or Transformers more like human vision? This repository contains the code and fine-tuned models of popular Convoluti

A Planar RGB-D SLAM which utilizes Manhattan World structure to provide optimal camera pose trajectory while also providing a sparse reconstruction containing points, lines and planes, and a dense surfel-based reconstruction.
A Planar RGB-D SLAM which utilizes Manhattan World structure to provide optimal camera pose trajectory while also providing a sparse reconstruction containing points, lines and planes, and a dense surfel-based reconstruction.

ManhattanSLAM Authors: Raza Yunus, Yanyan Li and Federico Tombari ManhattanSLAM is a real-time SLAM library for RGB-D cameras that computes the camera

Implementation for our AAAI2021 paper (Entity Structure Within and Throughout: Modeling Mention Dependencies for Document-Level Relation Extraction).
Implementation for our AAAI2021 paper (Entity Structure Within and Throughout: Modeling Mention Dependencies for Document-Level Relation Extraction).

SSAN Introduction This is the pytorch implementation of the SSAN model (see our AAAI2021 paper: Entity Structure Within and Throughout: Modeling Menti

Some tentative models that incorporate label propagation to graph neural networks for graph representation learning in nodes, links or graphs.

Some tentative models that incorporate label propagation to graph neural networks for graph representation learning in nodes, links or graphs.

Code for One-shot Talking Face Generation from Single-speaker Audio-Visual Correlation Learning (AAAI 2022)

One-shot Talking Face Generation from Single-speaker Audio-Visual Correlation Learning (AAAI 2022) Paper | Demo Requirements Python = 3.6 , Pytorch

Imposter-detector-2022 - HackED 2022 Team 3IQ - 2022 Imposter Detector
Imposter-detector-2022 - HackED 2022 Team 3IQ - 2022 Imposter Detector

HackED 2022 Team 3IQ - 2022 Imposter Detector By Aneeljyot Alagh, Curtis Kan, Jo

Comments
  • TypeError: __inc__() takes 3 positional arguments but 4 were given

    TypeError: __inc__() takes 3 positional arguments but 4 were given

    When run python ssl_graphmodels/pyg_models/train_docs.py --name R8

    building gnn_note_attn_gumbel model... train and validate: 0/200 | | Traceback (most recent call last): File "D:\Code\TextSSL\ssl_graphmodels\pyg_models\train_docs.py", line 126, in best_model, best_epoch, test_results, all_results, best_preds, labels = train_main(train_loader, val_loader, test_loader, params['patience']) File "D:\Code\TextSSL\ssl_graphmodels\pyg_models\train_docs.py", line 70, in train_main train_loss = train(train_loader, training=True) File "D:\Code\TextSSL\ssl_graphmodels\pyg_models\train_docs.py", line 22, in train for index, data in enumerate(loader): File "D:\Anaconda\envs\pytorch\lib\site-packages\torch\utils\data\dataloader.py", line 521, in next data = self._next_data() File "D:\Anaconda\envs\pytorch\lib\site-packages\torch\utils\data\dataloader.py", line 561, in _next_data data = self._dataset_fetcher.fetch(index) # may raise StopIteration File "D:\Anaconda\envs\pytorch\lib\site-packages\torch\utils\data_utils\fetch.py", line 52, in fetch return self.collate_fn(data) File "D:\Anaconda\envs\pytorch\lib\site-packages\torch_geometric\loader\dataloader.py", line 19, in call return Batch.from_data_list(batch, self.follow_batch, File "D:\Anaconda\envs\pytorch\lib\site-packages\torch_geometric\data\batch.py", line 68, in from_data_list batch, slice_dict, inc_dict = collate( File "D:\Anaconda\envs\pytorch\lib\site-packages\torch_geometric\data\collate.py", line 84, in collate value, slices, incs = _collate(attr, values, data_list, stores, File "D:\Anaconda\envs\pytorch\lib\site-packages\torch_geometric\data\collate.py", line 133, in _collate incs = get_incs(key, values, data_list, stores) File "D:\Anaconda\envs\pytorch\lib\site-packages\torch_geometric\data\collate.py", line 223, in get_incs repeats = [ File "D:\Anaconda\envs\pytorch\lib\site-packages\torch_geometric\data\collate.py", line 224, in data.inc(key, value, store) TypeError: inc() takes 3 positional arguments but 4 were given

    My env shows below: PyG:2.0.4 Pytorch:1.10 CUDA:11.3 OS:Win10

    opened by EldenRingChen 1
  • RuntimeError: start (0) + length (278) exceeds dimension size (2).

    RuntimeError: start (0) + length (278) exceeds dimension size (2).

    Could you tell me which version of pyg you use? when i run train_docs.py, there is an error:

    .........., line 65, in _separate value = value.narrow(cat_dim or 0, start, end - start)

    "RuntimeError: start (0) + length (278) exceeds dimension size (2)."

    opened by shawn-dm 1
Owner
null
Code for the AAAI 2022 paper "Zero-Shot Cross-Lingual Machine Reading Comprehension via Inter-Sentence Dependency Graph".

multilingual-mrc-isdg Code for the AAAI 2022 paper "Zero-Shot Cross-Lingual Machine Reading Comprehension via Inter-Sentence Dependency Graph". This r

Liyan 5 Dec 7, 2022
An official source code for paper Deep Graph Clustering via Dual Correlation Reduction, accepted by AAAI 2022

Dual Correlation Reduction Network An official source code for paper Deep Graph Clustering via Dual Correlation Reduction, accepted by AAAI 2022. Any

yueliu1999 109 Dec 23, 2022
Towards Open-World Feature Extrapolation: An Inductive Graph Learning Approach

This repository holds the implementation for paper Towards Open-World Feature Extrapolation: An Inductive Graph Learning Approach Download our preproc

Qitian Wu 42 Dec 27, 2022
This is the repository for the AAAI 21 paper [Contrastive and Generative Graph Convolutional Networks for Graph-based Semi-Supervised Learning].

CG3 This is the repository for the AAAI 21 paper [Contrastive and Generative Graph Convolutional Networks for Graph-based Semi-Supervised Learning]. R

null 12 Oct 28, 2022
Neural Logic Inductive Learning

Neural Logic Inductive Learning This is the implementation of the Neural Logic Inductive Learning model (NLIL) proposed in the ICLR 2020 paper: Learn

null 36 Nov 28, 2022
"Inductive Entity Representations from Text via Link Prediction" @ The Web Conference 2021

Inductive entity representations from text via link prediction This repository contains the code used for the experiments in the paper "Inductive enti

Daniel Daza 45 Jan 9, 2023
On Size-Oriented Long-Tailed Graph Classification of Graph Neural Networks

On Size-Oriented Long-Tailed Graph Classification of Graph Neural Networks We provide the code (in PyTorch) and datasets for our paper "On Size-Orient

Zemin Liu 4 Jun 18, 2022
Code for the AAAI-2022 paper: Imagine by Reasoning: A Reasoning-Based Implicit Semantic Data Augmentation for Long-Tailed Classification

Imagine by Reasoning: A Reasoning-Based Implicit Semantic Data Augmentation for Long-Tailed Classification (AAAI 2022) Prerequisite PyTorch >= 1.2.0 P

null 16 Dec 14, 2022
Pytorch implementation of the AAAI 2022 paper "Cross-Domain Empirical Risk Minimization for Unbiased Long-tailed Classification"

[AAAI22] Cross-Domain Empirical Risk Minimization for Unbiased Long-tailed Classification We point out the overlooked unbiasedness in long-tailed clas

PatatiPatata 28 Oct 18, 2022
Official implementation of the ICCV 2021 paper "Joint Inductive and Transductive Learning for Video Object Segmentation"

JOINT This is the official implementation of Joint Inductive and Transductive learning for Video Object Segmentation, to appear in ICCV 2021. @inproce

Yunyao 35 Oct 16, 2022