SIGIR'24 Paper: Modeling User Fatigue for Sequential Recommendation
This project is based on Microsoft Recommender and was originally designed for TensorFlow 2.1.
However, to run the model on modern hardware (e.g., RTX 30xx GPUs), we recommend upgrading to TensorFlow 2.4.1 due to compatibility with CUDA 11.0 and cuDNN 8.x.
Download from: https://www.python.org/downloads/release/python-3810/
& "C:\Users\<your_username>\AppData\Local\Programs\Python\Python38\python.exe" -m venv frec-tf24-env
.frec-tf24-env\Scripts\activateCreate a file requirements_tf24.txt with:
numpy
pandas
scikit-learn
PyYAML
tqdm
absl-py~=0.10
setproctitle==1.1.10
tensorflow==2.4.1
protobuf==3.19.6
retrying==1.3.3
Then run:
pip install -r requirements_tf24.txt
⚠️ Make sure you have installed CUDA 11.0 and cuDNN 8.x.
python run.py --model model --name trialOther baselines:
python run.py --model clsr --name trial
python run.py --model slirec --name trialIf you see ModuleNotFoundError: No module named 'sli_rec', add this at the top of run.py:
import sys, os
sys.path.append(os.path.dirname(os.path.abspath(__file__)))To run on CPU only:
import os
os.environ["CUDA_VISIBLE_DEVICES"] = "-1"To deactivate:
deactivateTo delete the virtual environment (PowerShell):
Remove-Item -Recurse -Force .\frec-tf24-envOr manually delete the folder frec-tf24-env from File Explorer.
We provide a processed Taobao dataset. To extract:
unzip data.zipData format follows standard sequential input from the Microsoft Recommender.
num_cross_layers: number of cross layersrecent_k: truncated sequence lengthnum_interests: number of latent interestsk_size: convolutional kernel sizealpha: contrastive learning weight