The implementation of our CIKM 2021 paper titled as: "Cross-Market Product Recommendation"

Related tags

Deep Learning FOREC
Overview

FOREC: A Cross-Market Recommendation System

This repository provides the implementation of our CIKM 2021 paper titled as "Cross-Market Product Recommendation". Please consider citing our paper if you find the code and XMarket dataset useful in your research.

The general schema of our FOREC recommendation system is shown below. For a pair of markets, the middle part shows the market-agnostic model that we pre-train, and then fork and fine-tune for each market shown in the left and right. Note that FOREC is capable of working with any desired number of target markets. However, for simplicity, we only experiment with pairs of markets for the experiments. For further details, please refer to our paper.

Requirements:

We use conda for our experimentations. Please refer to the requirements.txt for the list of libraries we use for our implementation. After setting up your environment, you can simply run this command pip install -r requirements.txt.

DATA

The DATA folder in this repository contains the cleaned and proccessed data that we use for our experiments. Please note that we made a few changes with releasing the data, and you might see slightly different numbers compared to the reported numbers in the paper.

If you wish to repeat the process on other categories of data or change the data preprocessing steps, prepare_data.ipynb provides the code for downloading and preprocessing data. Please refer to that jupyter notebook for further details. Don't hesitate to contact us in case of any problem.

Train the baseline and FOREC models (with Evaluations):

We provide three training scripts, for training baselines (single market, GMF, MLP, NMF++ and MAML) as well as FOREC model. Here are the list of models that for training and evaluating with the scripts provided:

  • train_base.py for GMF, MLP, NMF and their ++ versions as cross-market models
  • train_maml.py for training our MAML baseline
  • train_forec.py for trainig our proposed FOREC model

Note that since MAML and FOREC works on NMF architecture, you need to have same setting NMF++ model trained before proceeding with the MAML and FOREC training scripts. In addition, NMF requires that GMF and MLP models are trained, as it combines these two models into the architecture with some additional layers. See the middle part of the FOREC schema above.

In order to faciliate this, we provide a jupyter notebook (train_all.ipynb) that generates correct commands for all these trainings on any desired target market and augmenting source market pairs. Please follow the notebook for the training. For our trainings, we use slurm job management system on our server. However, you can still use/change the bash script generating part in the notebook to fit your own setup. These scripts are written into scripts folder created by the notebook. The logging of the training is alos in this directory under log sub-directory.

Note that for each of these, the train script evaluates on validation and test data (leave-one-out procedure for splitting---see data.py). The detailed evaluation results are dumped into EVAL folder as json files. Our trained checkpoints and an aggregator of evaluation json files will be provided shortly.

Citation

If you use this dataset, please refer to our CIKM’21 paper:

@inproceedings{bonab2021crossmarket,
    author = {Bonab, Hamed and Aliannejadi, Mohammad and Vardasbi, Ali and Kanoulas, Evangelos and Allan, James},
    booktitle = {Proceedings of the 30th ACM International Conference on Information \& Knowledge Management},
    publisher = {ACM},
    title = {Cross-Market Product Recommendation},
    year = {2021}}

Please feel free to either open an issue or contacting me at bonab [AT] cs.umass.edu

Comments
  • freeze_model function issue

    freeze_model function issue

    Dear authors, According to your paper, you should freeze the fc_layers rather than the mh_layers. But in the freeze_model() function from train_forec.py: for allowed_fc_layer in allowed_fc_layers: model.fc_layers[allowed_fc_layer].weight.requires_grad = True model.fc_layers[allowed_fc_layer].bias.requires_grad = True You freeze the mh_layers and unfreeze the buttom which I think is wrong.

    opened by laowangzi 0
  • when does the version used in paper of your dataset come out?

    when does the version used in paper of your dataset come out?

    Hi, thanks to your great dataset and work, I am so interested in your work, but i can't reproduce result of paper, when does the version used in paper of your dataset come out?

    opened by Ljwccc 0
  • GPU memory keeps increasing during training FORCE

    GPU memory keeps increasing during training FORCE

    Hi, first of all I am very thankful for you to provide such an interesting dataset. However, I ran into an out of memory problem during the training FORCE phase. I monitored GPU usage while training, and it keeps increasing until overflow.

    opened by ChenMetanoia 0
  • Some questions about the performance in the paper and training details.

    Some questions about the performance in the paper and training details.

    Hi, thank you for open source! I executed train_base.py and have some questions as follows:

    1. The performance on de dataset. I paste the results in the paper and highlight the values that correspond to train_base.py

    image

    I executed train_base.py and record the results as follows: image

    I noticed my GMF's NDCG@10 is far higher than that in the paper, and the rest 5 values are far lower. I did not change the content in train_base.py, what should I do to reproduce the models in the paper.

    1. Whether the results in the paper are taken from the validation or the test? I set num_epoch as 175 and I found some metrics in the validation set are much higher than that in the paper, but the results of the test set are still lower.
    2. If the results in the paper are taken from the test set, how did you set up the early stopping strategy? (i.e., the value of patience)
    3. I did not find the description of the batch size in the paper, but it is 1024 in the file. Is the batch size in the paper 1024?

    I hope you can reply to these questions that puzzle me when you have time, thank you very much!

    opened by sdfsfdx 3
  • `fast_lr`

    `fast_lr`

    I'm trying to run the scripts produced by the train_all notebook. The first two work (train_base & train_maml ) work fine, but I get this error when trying to run train_forec.py:

    $ python train_forec.py --aug_src_market us --num_epoch 25 --tgt_market uk --batch_size 20 --fast_lr 0.1 --exp_output EVAL/forec-train_all_equal_uk_us_full_aug_ftgt1_fsrc1_shots20.json --data_dir DATA/ --exp_name train_all_equal_uk_us_full_aug_ftgt1_fsrc1 --tgt_fraction 1 --src_fraction 1 --cuda --data_sampling_method equal
    usage: FOREC_NeuMF_Engine [-h] [--num_epoch NUM_EPOCH]
                              [--batch_size BATCH_SIZE] [--num_neg NUM_NEG]
                              [--cuda] [--seed SEED] [--exp_name EXP_NAME]
                              [--exp_output EXP_OUTPUT] [--data_dir DATA_DIR]
                              [--tgt_market TGT_MARKET]
                              [--aug_src_market AUG_SRC_MARKET]
                              [--data_sampling_method DATA_SAMPLING_METHOD]
                              [--tgt_fraction TGT_FRACTION]
                              [--src_fraction SRC_FRACTION]
    FOREC_NeuMF_Engine: error: unrecognized arguments: --fast_lr 0.1
    

    I'd appreciate any help fixing this!

    Thanks!

    opened by samarthbhargav 1
Owner
Hamed Bonab
PhD Candidate at UMass Amherst
Hamed Bonab
Code for reproducing our analysis in the paper titled: Image Cropping on Twitter: Fairness Metrics, their Limitations, and the Importance of Representation, Design, and Agency

Image Crop Analysis This is a repo for the code used for reproducing our Image Crop Analysis paper as shared on our blog post. If you plan to use this

Twitter Research 239 Jan 2, 2023
Source code for CIKM 2021 paper for Relation-aware Heterogeneous Graph for User Profiling

RHGN Source code for CIKM 2021 paper for Relation-aware Heterogeneous Graph for User Profiling Dependencies torch==1.6.0 torchvision==0.7.0 dgl==0.7.1

Big Data and Multi-modal Computing Group, CRIPAC 6 Nov 29, 2022
null 190 Jan 3, 2023
Pre-trained BERT Models for Ancient and Medieval Greek, and associated code for LaTeCH 2021 paper titled - "A Pilot Study for BERT Language Modelling and Morphological Analysis for Ancient and Medieval Greek"

Ancient Greek BERT The first and only available Ancient Greek sub-word BERT model! State-of-the-art post fine-tuning on Part-of-Speech Tagging and Mor

Pranaydeep Singh 22 Dec 8, 2022
G-NIA model from "Single Node Injection Attack against Graph Neural Networks" (CIKM 2021)

Single Node Injection Attack against Graph Neural Networks This repository is our Pytorch implementation of our paper: Single Node Injection Attack ag

Shuchang Tao 18 Nov 21, 2022
Code for the CIKM 2019 paper "DSANet: Dual Self-Attention Network for Multivariate Time Series Forecasting".

Dual Self-Attention Network for Multivariate Time Series Forecasting 20.10.26 Update: Due to the difficulty of installation and code maintenance cause

Kyon Huang 223 Dec 16, 2022
Codes for CIKM'21 paper 'Self-Supervised Graph Co-Training for Session-based Recommendation'.

COTREC Codes for CIKM'21 paper 'Self-Supervised Graph Co-Training for Session-based Recommendation'. Requirements: Python 3.7, Pytorch 1.6.0 Best Hype

Xin Xia 42 Dec 9, 2022
A PyTorch implementation of "ANEMONE: Graph Anomaly Detection with Multi-Scale Contrastive Learning", CIKM-21

ANEMONE A PyTorch implementation of "ANEMONE: Graph Anomaly Detection with Multi-Scale Contrastive Learning", CIKM-21 Dependencies python==3.6.1 dgl==

Graph Analysis & Deep Learning Laboratory, GRAND 30 Dec 14, 2022
Little Ball of Fur - A graph sampling extension library for NetworKit and NetworkX (CIKM 2020)

Little Ball of Fur is a graph sampling extension library for Python. Please look at the Documentation, relevant Paper, Promo video and External Resour

Benedek Rozemberczki 619 Dec 14, 2022
Karate Club: An API Oriented Open-source Python Framework for Unsupervised Learning on Graphs (CIKM 2020)

Karate Club is an unsupervised machine learning extension library for NetworkX. Please look at the Documentation, relevant Paper, Promo Video, and Ext

Benedek Rozemberczki 1.8k Jan 7, 2023
[CIKM 2019] Code and dataset for "Fi-GNN: Modeling Feature Interactions via Graph Neural Networks for CTR Prediction"

FiGNN for CTR prediction The code and data for our paper in CIKM2019: Fi-GNN: Modeling Feature Interactions via Graph Neural Networks for CTR Predicti

Big Data and Multi-modal Computing Group, CRIPAC 75 Dec 30, 2022
PyTorch implementation of our Adam-NSCL algorithm from our CVPR2021 (oral) paper "Training Networks in Null Space for Continual Learning"

Adam-NSCL This is a PyTorch implementation of Adam-NSCL algorithm for continual learning from our CVPR2021 (oral) paper: Title: Training Networks in N

Shipeng Wang 34 Dec 21, 2022
Official repo for the work titled "SharinGAN: Combining Synthetic and Real Data for Unsupervised GeometryEstimation"

SharinGAN Official repo for the work titled "SharinGAN: Combining Synthetic and Real Data for Unsupervised GeometryEstimation" The official project we

Koutilya PNVR 23 Oct 19, 2022
This project is the official implementation of our accepted ICLR 2021 paper BiPointNet: Binary Neural Network for Point Clouds.

BiPointNet: Binary Neural Network for Point Clouds Created by Haotong Qin, Zhongang Cai, Mingyuan Zhang, Yifu Ding, Haiyu Zhao, Shuai Yi, Xianglong Li

Haotong Qin 59 Dec 17, 2022
This is an official implementation of our CVPR 2021 paper "Bottom-Up Human Pose Estimation Via Disentangled Keypoint Regression" (https://arxiv.org/abs/2104.02300)

Bottom-Up Human Pose Estimation Via Disentangled Keypoint Regression Introduction In this paper, we are interested in the bottom-up paradigm of estima

HRNet 367 Dec 27, 2022
The official implementation of our CVPR 2021 paper - Hybrid Rotation Averaging: A Fast and Robust Rotation Averaging Approach

Graph Optimizer This repo contains the official implementation of our CVPR 2021 paper - Hybrid Rotation Averaging: A Fast and Robust Rotation Averagin

Chenyu 109 Dec 23, 2022
Implementation for our ICCV 2021 paper: Dual-Camera Super-Resolution with Aligned Attention Modules

DCSR: Dual Camera Super-Resolution Implementation for our ICCV 2021 oral paper: Dual-Camera Super-Resolution with Aligned Attention Modules paper | pr

Tengfei Wang 110 Dec 20, 2022
Implementation for our ICCV 2021 paper: Dual-Camera Super-Resolution with Aligned Attention Modules

DCSR: Dual Camera Super-Resolution Implementation for our ICCV 2021 oral paper: Dual-Camera Super-Resolution with Aligned Attention Modules paper | pr

Tengfei Wang 110 Dec 20, 2022
Pytorch implementation for our ICCV 2021 paper "TRAR: Routing the Attention Spans in Transformers for Visual Question Answering".

TRAnsformer Routing Networks (TRAR) This is an official implementation for ICCV 2021 paper "TRAR: Routing the Attention Spans in Transformers for Visu

Ren Tianhe 49 Nov 10, 2022