Install FuxiCTR#

Note

The tutorial is for FuxiCTR v1.2.

FuxiCTR has the following requirements.

  • python 3.6

  • pytorch v1.0/v1.2

  • pyyaml >=5.1

  • scikit-learn

  • pandas

  • numpy

  • h5py

  • tqdm

For pytorch, you can download the appropriate whl file according to your CUDA version from https://download.pytorch.org/whl/torch_stable.html, and install offline. For eaxmple:

!pip install torch-1.0.1.post2-cp36-cp36m-linux_x86_64.whl

We recommend to install the above enviornment through Anaconda using Anaconda3-5.2.0-Linux-x86_64.sh. Then update the PyYAML version as follows.

!pip install --ignore-installed pyyaml==5.1

There are two ways to install FuxiCTR v1.2.x

Solution 1: pip install (note that all dependent requirements need to be installed accordingly.)

!pip install fuxictr==1.1.*

Solution 2: git clone or download the zip file: https://github.com/xue-pai/FuxiCTR/tags

If you download the source code, you need to add the fuxictr folder to the system path in your code.

import sys
sys.path.append('./YOUR_PATH_TO_FuxiCTR')

Check if fuxictr has been installed successfully.

import fuxictr
fuxictr.__version__

Run the tests:

!cd tests
!bash test_all.sh