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
75c0b4cc
Commit
75c0b4cc
authored
May 27, 2019
by
Adam Rogowiec
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix CentOS bugs.
parent
9042e7db
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
16 deletions
+14
-16
lstm.cpp
src/ngraph/frontend/onnx_import/op/lstm.cpp
+11
-13
rnn_cell_base.hpp
src/ngraph/op/fused/rnn_cell_base.hpp
+3
-3
No files found.
src/ngraph/frontend/onnx_import/op/lstm.cpp
View file @
75c0b4cc
...
...
@@ -241,14 +241,14 @@ namespace ngraph
const
LSTMAttributes
&
attributes
)
:
m_X
{
X
}
// Since we have forward LSTM we can squeeze `num_directions` axis from inputs.
,
m_W
{
reshape
::
squeeze
(
W
)}
,
m_R
{
reshape
::
squeeze
(
R
)}
,
m_B
{
reshape
::
squeeze
(
B
)}
,
m_P
{
reshape
::
squeeze
(
P
)}
,
m_initial_h
{
reshape
::
squeeze
(
initial_h
)}
,
m_initial_c
{
reshape
::
squeeze
(
initial_c
)}
,
m_seq_lengths
{
seq_lengths
}
,
m_attributes
{
attributes
}
,
m_W
(
reshape
::
squeeze
(
W
))
,
m_R
(
reshape
::
squeeze
(
R
))
,
m_B
(
reshape
::
squeeze
(
B
))
,
m_P
(
reshape
::
squeeze
(
P
))
,
m_initial_h
(
reshape
::
squeeze
(
initial_h
))
,
m_initial_c
(
reshape
::
squeeze
(
initial_c
))
,
m_seq_lengths
(
seq_lengths
)
,
m_attributes
(
attributes
)
{
}
...
...
@@ -302,7 +302,7 @@ namespace ngraph
std
::
int32_t
time_step
{
1
};
for
(
const
auto
&
in_x
:
in_seqs
)
{
const
std
::
shared_ptr
<
ngraph
::
Node
>&
lstm_cell
=
std
::
shared_ptr
<
ngraph
::
Node
>
lstm_cell
=
std
::
make_shared
<
ngraph
::
op
::
LSTMCell
>
(
in_x
,
m_W
,
...
...
@@ -318,10 +318,8 @@ namespace ngraph
m_attributes
.
m_clip_threshold
,
m_attributes
.
m_input_forget
);
const
std
::
shared_ptr
<
ngraph
::
Node
>&
H
=
get_output_element
(
lstm_cell
,
0
);
const
std
::
shared_ptr
<
ngraph
::
Node
>&
C
=
get_output_element
(
lstm_cell
,
1
);
std
::
shared_ptr
<
ngraph
::
Node
>
H
=
get_output_element
(
lstm_cell
,
0
);
std
::
shared_ptr
<
ngraph
::
Node
>
C
=
get_output_element
(
lstm_cell
,
1
);
// Expand tensors with empty outermost dim, so we can later concatenate
// them.
...
...
src/ngraph/op/fused/rnn_cell_base.hpp
View file @
75c0b4cc
...
...
@@ -70,9 +70,9 @@ namespace ngraph
private
:
std
::
size_t
m_hidden_size
=
0.
f
;
float
m_clip
=
0.
f
;
std
::
vector
<
std
::
string
>
m_activations
;
std
::
vector
<
float
>
m_activation_alpha
;
std
::
vector
<
float
>
m_activation_beta
;
const
std
::
vector
<
std
::
string
>
m_activations
;
const
std
::
vector
<
float
>
m_activation_alpha
;
const
std
::
vector
<
float
>
m_activation_beta
;
};
}
}
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