1 Star 0 Fork 0

w517424787 / angel

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
transfunc_on_angel.md 1.09 KB
一键复制 编辑 原始数据 按行查看 历史
rachelsun 提交于 2018-08-27 18:33 . modify typos

Angel中的传递函数

1. Angel中的传递函数有:

名称 表达式 说明
Sigmoid 将任意实数变成概率
tanh 将任意实数变成-1到1之间的数
relu 丢弃负的部分
dropout 随机置0
identity 原样输出

下图给出了一些常用的传递函数(部分Angel中没有提供): 传递函数

2. 传递函数的json表示

2.1 无参数的传递函数

"transfunc": "sigmoid",

"transfunc": {
    "type": "tanh"
}

2.2 有参数的传递函数

"transfunc": "dropout",

"transfunc": {
    "type": "dropout",
    "proba": 0.5,
    "actiontype": "train"
}

注: 由于dropout传递函数在训练与测试(预测)中计算方式不一样, 所以要用actiontype表明是哪种场景, train/inctrain, predict.

1
https://gitee.com/517424787/angel.git
git@gitee.com:517424787/angel.git
517424787
angel
angel
master

搜索帮助