Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
models
提交
f3042c58
M
models
项目概览
PaddlePaddle
/
models
1 年多 前同步成功
通知
222
Star
6828
Fork
2962
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
602
列表
看板
标记
里程碑
合并请求
255
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
models
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
602
Issue
602
列表
看板
标记
里程碑
合并请求
255
合并请求
255
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
f3042c58
编写于
1月 24, 2018
作者:
zhaoyijin666
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix bug
上级
30d49cd2
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
4 addition
and
2 deletion
+4
-2
youtube_recall/README.cn.md
youtube_recall/README.cn.md
+2
-0
youtube_recall/README.md
youtube_recall/README.md
+2
-1
youtube_recall/network_conf.py
youtube_recall/network_conf.py
+0
-1
未找到文件。
youtube_recall/README.cn.md
浏览文件 @
f3042c58
...
...
@@ -90,6 +90,7 @@ optional arguments:
例如可执行下列命令, 完成数据预处理:
```
shell
mkdir
output
python data_processor.py
--train_set_path
=
./data/train.txt
\
--output_dir
=
./output
\
--feat_appear_limit
=
20
...
...
@@ -255,6 +256,7 @@ reader = Reader(feature_dict, args.window_size)
```
接下去就可以开始训练了,可执行以下命令:
```
shell
mkdir
output/model
python train.py
--train_set_path
=
'./data/train.txt'
\
--test_set_path
=
'./data/test.txt'
\
--model_output_dir
=
'./output/model/'
\
...
...
youtube_recall/README.md
浏览文件 @
f3042c58
...
...
@@ -79,6 +79,7 @@ The fucntion of this script is as follows:
For example, run the following command to accomplish data pre-processing:
```
shell
mkdir output
python data_processor.py --train_set_path=./data/train.txt
\
--output_dir=./output
\
--feat_appear_limit=20
...
...
@@ -193,7 +194,6 @@ return paddle.layer.nce(
num_classes=len(self._feature_dict['history_clicked_items']),
param_attr=paddle.attr.Param(name="nce_w"),
bias_attr=paddle.attr.Param(name="nce_b"),
act=paddle.activation.Sigmoid(),
num_neg_samples=5,
neg_distribution=self._item_freq)
```
...
...
@@ -240,6 +240,7 @@ reader = Reader(feature_dict, args.window_size)
```
Then start training.
```
shell
mkdir
output/model
python train.py
--train_set_path
=
'./data/train.txt'
\
--test_set_path
=
'./data/test.txt'
\
--model_output_dir
=
'./output/model/'
\
...
...
youtube_recall/network_conf.py
浏览文件 @
f3042c58
...
...
@@ -147,7 +147,6 @@ class DNNmodel(object):
num_classes
=
len
(
self
.
_feature_dict
[
'history_clicked_items'
]),
param_attr
=
paddle
.
attr
.
Param
(
name
=
"nce_w"
),
bias_attr
=
paddle
.
attr
.
Param
(
name
=
"nce_b"
),
act
=
paddle
.
activation
.
Sigmoid
(),
num_neg_samples
=
5
,
neg_distribution
=
self
.
_item_freq
)
else
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录