Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
机器未来
Paddle
提交
7d247ca5
P
Paddle
项目概览
机器未来
/
Paddle
与 Fork 源项目一致
Fork自
PaddlePaddle / Paddle
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
7d247ca5
编写于
2月 23, 2018
作者:
Y
Yang Yang
浏览文件
操作
浏览文件
下载
差异文件
Merge remote-tracking branch 'upstream/develop' into feature/understand_sentimental_dynrnn_2
上级
71053063
7a9098a6
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
41 addition
and
7 deletion
+41
-7
benchmark/cluster/vgg16/README.md
benchmark/cluster/vgg16/README.md
+5
-4
paddle/fluid/framework/channel.h
paddle/fluid/framework/channel.h
+2
-3
paddle/fluid/framework/channel_test.cc
paddle/fluid/framework/channel_test.cc
+34
-0
未找到文件。
benchmark/cluster/vgg16/README.md
浏览文件 @
7d247ca5
...
@@ -8,23 +8,24 @@
...
@@ -8,23 +8,24 @@
-
cpu MHz : 2101.000
-
cpu MHz : 2101.000
-
cache size : 20480 KB
-
cache size : 20480 KB
### Blas settings
Setting environment variable:
`MKL_NUM_THREADS=1`
.
### Single Node Single Thread
### Single Node Single Thread
-
PServer Count: 10
-
Trainer Count: 20
-
Metrics: samples / sec
-
Metrics: samples / sec
| Batch Size | 32 | 64 | 128 | 256 |
| Batch Size | 32 | 64 | 128 | 256 |
| -- | -- | -- | -- | -- |
| -- | -- | -- | -- | -- |
| PaddlePaddle Fluid | 15.44 | 16.32 | 16.74 | 16.79 |
| PaddlePaddle Fluid | 15.44 | 16.32 | 16.74 | 16.79 |
| PaddlePaddle v2 | 15.97 | 17.04 | 17.60 | 17.83 |
| PaddlePaddle v2 | 15.97 | 17.04 | 17.60 | 17.83 |
| TensorFlow |
- | - | - | -
|
| TensorFlow |
9.09 | 9.10 | 9.24 | 8.66
|
### Different Batch Size
### Different Batch Size
-
PServer Count: 10
-
PServer Count: 10
-
Trainer Count: 20
-
Trainer Count: 20
-
Per trainer CPU Core: 1
-
Metrics: samples / sec
-
Metrics: samples / sec
| Batch Size | 32 | 64 | 128 | 256 |
| Batch Size | 32 | 64 | 128 | 256 |
...
...
paddle/fluid/framework/channel.h
浏览文件 @
7d247ca5
...
@@ -100,8 +100,7 @@ class ChannelHolder {
...
@@ -100,8 +100,7 @@ class ChannelHolder {
virtual
~
Placeholder
()
{}
virtual
~
Placeholder
()
{}
virtual
const
std
::
type_index
Type
()
const
=
0
;
virtual
const
std
::
type_index
Type
()
const
=
0
;
virtual
void
*
Ptr
()
const
=
0
;
virtual
void
*
Ptr
()
const
=
0
;
virtual
void
Close
()
const
=
0
;
virtual
void
Close
()
=
0
;
std
::
type_info
type_
;
};
};
template
<
typename
T
>
template
<
typename
T
>
...
@@ -116,7 +115,7 @@ class ChannelHolder {
...
@@ -116,7 +115,7 @@ class ChannelHolder {
if
(
channel_
)
channel_
->
Close
();
if
(
channel_
)
channel_
->
Close
();
}
}
std
::
unique_ptr
<
Channel
<
T
>
*
>
channel_
;
std
::
unique_ptr
<
Channel
<
T
>>
channel_
;
const
std
::
type_index
type_
;
const
std
::
type_index
type_
;
};
};
...
...
paddle/fluid/framework/channel_test.cc
浏览文件 @
7d247ca5
...
@@ -20,6 +20,7 @@ limitations under the License. */
...
@@ -20,6 +20,7 @@ limitations under the License. */
#include "gtest/gtest.h"
#include "gtest/gtest.h"
using
paddle
::
framework
::
Channel
;
using
paddle
::
framework
::
Channel
;
using
paddle
::
framework
::
ChannelHolder
;
using
paddle
::
framework
::
MakeChannel
;
using
paddle
::
framework
::
MakeChannel
;
using
paddle
::
framework
::
CloseChannel
;
using
paddle
::
framework
::
CloseChannel
;
using
paddle
::
framework
::
details
::
Buffered
;
using
paddle
::
framework
::
details
::
Buffered
;
...
@@ -508,3 +509,36 @@ TEST(Channel, UnbufferedChannelDestroyUnblocksSendersTest) {
...
@@ -508,3 +509,36 @@ TEST(Channel, UnbufferedChannelDestroyUnblocksSendersTest) {
auto
ch
=
MakeChannel
<
int
>
(
0
);
auto
ch
=
MakeChannel
<
int
>
(
0
);
ChannelDestroyUnblockSenders
(
ch
);
ChannelDestroyUnblockSenders
(
ch
);
}
}
void
ChannelHolderSendReceive
(
ChannelHolder
*
ch
)
{
unsigned
sum_send
=
0
;
std
::
thread
t
([
&
]()
{
for
(
int
i
=
0
;
i
<
5
;
i
++
)
{
EXPECT_EQ
(
ch
->
Send
(
&
i
),
true
);
sum_send
+=
i
;
}
});
for
(
int
i
=
0
;
i
<
5
;
i
++
)
{
int
recv
;
EXPECT_EQ
(
ch
->
Receive
(
&
recv
),
true
);
EXPECT_EQ
(
recv
,
i
);
}
ch
->
close
();
t
.
join
();
EXPECT_EQ
(
sum_send
,
10U
);
}
TEST
(
ChannelHolder
,
ChannelHolderBufferedSendReceiveTest
)
{
ChannelHolder
*
ch
=
new
ChannelHolder
();
ch
->
Reset
<
int
>
(
10
);
ChannelHolderSendReceive
(
ch
);
delete
ch
;
}
TEST
(
ChannelHolder
,
ChannelHolderUnBufferedSendReceiveTest
)
{
ChannelHolder
*
ch
=
new
ChannelHolder
();
ch
->
Reset
<
int
>
(
0
);
ChannelHolderSendReceive
(
ch
);
delete
ch
;
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录