Get Started

Here we describe how to install RecStudio, train and evaluate models built into RecStudio.

Install RecStudio

Clone RecStudio

To use RecStudio, you are required to clone RecStudio source code from our repo.

 git clone https://github.com/ustcml/RecStudio.git

Configure the environment

Set up the environment required to run RecStudio.
Run the following code to set up the conda environment.

 conda env create -f environment.yml 

Run RecStudio

The following is an example of running a built-in model (BPR) of RecStudio.

Run in commond line

We provide the run.py script for users to quickly use the built-in models.
This case trains and evaluates the BPR model on the ml-100k dataset.

 python run.py -m=BPR -d=ml-100k

You can modify the parameters to choose different models and datasets. E.g:

 python run.py -m=FM -d=ml-1m

Run in .py file

You can use the quickstart module to run a built-in model:

 
from recstudio import quickstart
quickstart.run(model='LR', dataset='ml-100k')

Different models and datasets can be set by modifying the corresponding parameters:

 
from recstudio import quickstart
quickstart.run(model='BPR', dataset='ml-1m')