Simple and Flexible Deep Recommenders in PyTorch
==============================
![profile](https://i.imgur.com/MWSyBfS.png)
Simple but flexible Deep Recommenders in PyTorch.
Plese review the deck to see the accompanying written & visual content. ![deck](https://i.imgur.com/VqmfR4H.png)
[View the deck here](https://docs.google.com/presentation/d/1gv7osHoSX8CHf0uzKSqOlxmmAvPPdmstL0nrZHWiHQM/edit#slide=id.p)
Check out the notebooks within to step through variations of matrix factorization models. Here's what we'll cover:
0. [Step 0] Introduction to autograd & deep learning using PyTorch, the Ignite library, and recommendation engines.
1. [Step 1] Build a simple matrix-factorization model in PyTorch. These models are a fundamental core to Netflix's, Pandora's, Stitch Fix's and Amazon's recommendations engines.
2. [Step 2] We'll expand on that model to include biases for extra predictive power
4. [Step 3] Add in "side" features, especially useful in coldstart cases
5. [Step 4] Model temporal effects which can track seasonal and periodic changes.
3. [Step 5] We'll take detour and see how word2vec is mathematically identical to recommendation engines
6. [Step 6] Upgrade the core of matrix factorization to Factorization Machines, which enables a huge number of interactions while keeping computation under control.
8. [Step 7] We'll wrap up with Bayesian Deep Learning applied to rec engines. This Variational Matrix Factorization is a great way to dip your toes into explore & exploit problems.
8. [Step 8] We'll build a real-time recommender using Transformers to read in an input ratings stream and generate recommendations.
# To get started.
If at all possible, please check out and pre-install the environment.
```
git clone https://github.com/cemoody/simple_mf.git
cd simple_mf
```
## 1. Create environment.
Create the environment by following the steps below. If you choose to use your own environment, you'll need access to have the Python packages in `requirements.txt` installed.
Make sure you you have pytorch installed; if not, follow the instructions [here](https://pytorch.org/get-started/locally/)
```
pip install pytorch-lightning optuna
```
Follow the directions the above command spits out.
## 2. Setup W & B account
You'll be creating using a (free) weights & biases account to track model metrics and performance over time. TO kickstart that process:
```
pip install wandb
wandb login
```
Setup your W&B account, then go to the W&B authorization page: https://app.wandb.ai/authorize and copy the auth code into your terminal when prompted by `wandb login`
## 3. Download and preprocess data:
This will download and preprocess the MovieLens 1M dataset. We'll use this canonical dataset to test drive our code.
```
# required. will download the movielens 1M dataset.
python src/download.py
# optional! this is a bigger dataset we'll use for more
# advanced models.
python src/download_ml20.py
# optional too. This is used for word2vec notebook.
python src/skipgram.py
```
## 4. Does it work?
Open up and execute every line within the `01 MF model.ipynb` notebook. If it works, you're golden.
没有合适的资源?快使用搜索试试~ 我知道了~
PyTorch中简单但灵活的推荐引擎_Jupyter Notebook_Python_下载.zip
共33个文件
ipynb:16个
py:8个
yml:1个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 111 浏览量
2023-04-23
00:17:47
上传
评论
收藏 247KB ZIP 举报
温馨提示
PyTorch中简单但灵活的推荐引擎_Jupyter Notebook_Python_下载.zip
资源推荐
资源详情
资源评论
收起资源包目录
PyTorch中简单但灵活的推荐引擎_Jupyter Notebook_Python_下载.zip (33个子文件)
simple_mf-master
abstract_model.py 2KB
_config.yml 27B
setup.py 240B
Makefile 4KB
src
download_ml20.py 3KB
download.py 3KB
skipgram.py 5KB
LICENSE 1KB
.notes 2KB
tox.ini 50B
requirements.txt 124B
.gitignore 957B
test_environment.py 632B
README.md 3KB
notebooks
loader.py 1014B
abstract_model.py 2KB
00C Exercise.ipynb 116KB
10 Autoregressive MF Multioutput.ipynb 13KB
07 MF variational.ipynb 14KB
04 MF model plus temporal-features.ipynb 70KB
06 MF model with hashed features.ipynb 31KB
02A Bug hunt 1.ipynb 64KB
08 FM model.ipynb 24KB
02C Bug hunt 3.ipynb 54KB
09 Autoregressive MF.ipynb 58KB
01 MF model.ipynb 64KB
00B Intro to PT Lightning.ipynb 35KB
.gitkeep 0B
03 MF model with side-features.ipynb 119KB
05 MF model as word2vec.ipynb 18KB
02B Bug hunt 2.ipynb 24KB
00A Intro PyTorch.ipynb 96KB
02 MF model with biases.ipynb 45KB
共 33 条
- 1
资源评论
快撑死的鱼
- 粉丝: 1w+
- 资源: 9154
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功