Coder Social home page Coder Social logo

xovee / cassampling Goto Github PK

View Code? Open in Web Editor NEW

This project forked from gration-cheng/cassampling

1.0 0.0 0.0 20 KB

[ECML/PKDD 2023] This is the Pytorch code for our paper "CasSampling: Exploring Efficient Cascade Graph Learning for Popularity Prediction".

Python 100.00%

cassampling's Introduction

CasSampling

This repo provides a implementation of CasSampling as described in the paper:

CasSampling: Exploring Efficient Cascade Graph Learning for Popularity Prediction

Basic Usage

Requirements

The code was tested with python 3.9, torch 1.11.0, cudatoolkit 11.3, and cudnn 8.2.0. Install the dependencies via Anaconda:

# create virtual environment
conda create --name CasSampling python=3.9 

# activate environment
conda activate CasSampling

# install torch and other requirements
conda install pytorch torchvision torchaudio pytorch-cuda=11.3 -c pytorch -c nvidia
pip install -r requirements.txt

Run the code

cd ./preprocessing

##Preprocessing the data, Then transform the datasets to the format of ".pkl" command:
python utils.py
python preprocess_graph.py
#you can change the dataset, observation time, and parameter in config.py

# run CasSampling model
cd ./CasSampling_model
python run_CasSampling.py

Datasets

See some sample cascades in ./data/twitter/dataset.txt.

Weibo or Twitter Datasets download link: Google Drive

The datasets we used in the paper are come from:

cassampling's People

Contributors

gration-cheng avatar

Stargazers

Zhangtao Cheng avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.