Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
wk1234123
Paddle
提交
b38c78c3
P
Paddle
项目概览
wk1234123
/
Paddle
与 Fork 源项目一致
Fork自
PaddlePaddle / Paddle
通知
4
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
b38c78c3
编写于
5月 30, 2018
作者:
Q
qiaolongfei
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'develop' of
https://github.com/PaddlePaddle/Paddle
into fix-compile-by-std-move
上级
06068182
c95cd474
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
8 addition
and
2 deletion
+8
-2
paddle/fluid/operators/cast_op.cc
paddle/fluid/operators/cast_op.cc
+1
-0
paddle/fluid/operators/cast_op.cu
paddle/fluid/operators/cast_op.cu
+1
-1
paddle/fluid/pybind/pybind.cc
paddle/fluid/pybind/pybind.cc
+3
-0
python/paddle/fluid/data_feeder.py
python/paddle/fluid/data_feeder.py
+3
-1
未找到文件。
paddle/fluid/operators/cast_op.cc
浏览文件 @
b38c78c3
...
...
@@ -89,4 +89,5 @@ REGISTER_OP_CPU_KERNEL(cast, ops::CastOpKernel<CPU, float>,
ops
::
CastOpKernel
<
CPU
,
int
>
,
ops
::
CastOpKernel
<
CPU
,
int64_t
>
,
ops
::
CastOpKernel
<
CPU
,
bool
>
,
ops
::
CastOpKernel
<
CPU
,
uint8_t
>
,
ops
::
CastOpKernel
<
CPU
,
paddle
::
platform
::
float16
>
);
paddle/fluid/operators/cast_op.cu
浏览文件 @
b38c78c3
...
...
@@ -21,5 +21,5 @@ using CastOpKernel =
REGISTER_OP_CUDA_KERNEL
(
cast
,
CastOpKernel
<
float
>
,
CastOpKernel
<
double
>
,
CastOpKernel
<
int
>
,
CastOpKernel
<
int64_t
>
,
CastOpKernel
<
bool
>
,
CastOpKernel
<
bool
>
,
CastOpKernel
<
uint8_t
>
,
CastOpKernel
<
paddle
::
platform
::
float16
>
);
paddle/fluid/pybind/pybind.cc
浏览文件 @
b38c78c3
...
...
@@ -117,6 +117,7 @@ PYBIND11_PLUGIN(core) {
.
def
(
"set"
,
PyCPUTensorSetFromArray
<
int64_t
>
)
.
def
(
"set"
,
PyCPUTensorSetFromArray
<
bool
>
)
.
def
(
"set"
,
PyCPUTensorSetFromArray
<
uint16_t
>
)
.
def
(
"set"
,
PyCPUTensorSetFromArray
<
uint8_t
>
)
#ifdef PADDLE_WITH_CUDA
.
def
(
"set"
,
PyCUDATensorSetFromArray
<
float
>
)
.
def
(
"set"
,
PyCUDATensorSetFromArray
<
int
>
)
...
...
@@ -124,12 +125,14 @@ PYBIND11_PLUGIN(core) {
.
def
(
"set"
,
PyCUDATensorSetFromArray
<
int64_t
>
)
.
def
(
"set"
,
PyCUDATensorSetFromArray
<
bool
>
)
.
def
(
"set"
,
PyCUDATensorSetFromArray
<
uint16_t
>
)
.
def
(
"set"
,
PyCUDATensorSetFromArray
<
uint8_t
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
float
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
int
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
double
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
int64_t
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
bool
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
uint16_t
>
)
.
def
(
"set"
,
PyCUDAPinnedTensorSetFromArray
<
uint8_t
>
)
#endif
.
def
(
"shape"
,
[](
Tensor
&
self
)
{
return
vectorize
(
self
.
dims
());
})
.
def
(
"set_float_element"
,
TensorSetElement
<
float
>
)
...
...
python/paddle/fluid/data_feeder.py
浏览文件 @
b38c78c3
...
...
@@ -36,9 +36,11 @@ class DataToLoDTensorConverter(object):
self
.
dtype
=
'float64'
elif
dtype
==
core
.
VarDesc
.
VarType
.
INT32
:
self
.
dtype
=
'int32'
elif
dtype
==
core
.
VarDesc
.
VarType
.
UINT8
:
self
.
dtype
=
'uint8'
else
:
raise
ValueError
(
"dtype must be any of [int32, float32, int64, "
"float64]"
)
"float64
, uint8
]"
)
self
.
data
=
[]
self
.
lod
=
[]
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录