Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
N
ngraph
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ngraph
Commits
29014bab
Unverified
Commit
29014bab
authored
Feb 22, 2018
by
Adam Procter
Committed by
GitHub
Feb 22, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow use of MKLDNN backprop when pointer to forward-prop op is missing (#523)
parent
84d236ad
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
6 deletions
+5
-6
cpu_emitter.cpp
src/ngraph/runtime/cpu/cpu_emitter.cpp
+5
-6
No files found.
src/ngraph/runtime/cpu/cpu_emitter.cpp
View file @
29014bab
...
@@ -2682,14 +2682,13 @@ namespace ngraph
...
@@ -2682,14 +2682,13 @@ namespace ngraph
void
CPU_Emitter
::
EMITTER_DECL
(
ngraph
::
op
::
MaxPoolBackprop
)
void
CPU_Emitter
::
EMITTER_DECL
(
ngraph
::
op
::
MaxPoolBackprop
)
{
{
auto
mpb
=
static_cast
<
const
ngraph
::
op
::
MaxPoolBackprop
*>
(
node
);
auto
mpb
=
static_cast
<
const
ngraph
::
op
::
MaxPoolBackprop
*>
(
node
);
auto
max_pool_fprop_op
=
mpb
->
get_forward_op
();
auto
delta_shape
=
args
[
1
].
get_shape
();
auto
delta_shape
=
args
[
1
].
get_shape
();
auto
delta_rank
=
delta_shape
.
size
();
auto
delta_rank
=
delta_shape
.
size
();
auto
out_shape
=
out
[
0
].
get_shape
();
auto
out_shape
=
out
[
0
].
get_shape
();
if
(
delta_rank
==
4
&&
mpb
->
get_window_shape
().
size
()
==
2
&&
if
(
delta_rank
==
4
&&
mpb
->
get_window_shape
().
size
()
==
2
&&
args
[
0
].
get_element_type
()
==
element
::
f32
&&
max_pool_fprop_op
!=
nullptr
)
args
[
0
].
get_element_type
()
==
element
::
f32
)
{
{
const
string
&
et
=
const
string
&
et
=
get_mkldnn_data_type
(
args
[
1
].
get_element_type
().
c_type_string
());
get_mkldnn_data_type
(
args
[
1
].
get_element_type
().
c_type_string
());
...
@@ -2725,10 +2724,10 @@ namespace ngraph
...
@@ -2725,10 +2724,10 @@ namespace ngraph
"pooling_forward::primitive_desc("
"pooling_forward::primitive_desc("
<<
"{prop_kind::forward, algorithm::pooling_max, "
<<
"{prop_kind::forward, algorithm::pooling_max, "
<<
"max_pool_input_desc, max_pool_result_desc, {"
<<
"max_pool_input_desc, max_pool_result_desc, {"
<<
join
(
m
ax_pool_fprop_op
->
get_window_movement_strides
())
<<
"}, {"
<<
join
(
m
pb
->
get_window_movement_strides
())
<<
"}, {"
<<
join
(
m
ax_pool_fprop_op
->
get_window_shape
())
<<
"}, "
<<
join
(
m
pb
->
get_window_shape
())
<<
"}, "
<<
"{"
<<
join
(
m
ax_pool_fprop_op
->
get_padding_below
())
<<
"}, "
<<
"{"
<<
join
(
m
pb
->
get_padding_below
())
<<
"}, "
<<
"{"
<<
join
(
m
ax_pool_fprop_op
->
get_padding_above
())
<<
"}, "
<<
"{"
<<
join
(
m
pb
->
get_padding_above
())
<<
"}, "
<<
"padding_kind::zero}, cpu_engine);
\n
"
;
<<
"padding_kind::zero}, cpu_engine);
\n
"
;
// query the workspace from the forward primitive desc and allocates memory
// query the workspace from the forward primitive desc and allocates memory
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment