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
fc6cd9ac
Commit
fc6cd9ac
authored
Jan 29, 2018
by
Jaikrishnan Menon
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into maxpool
parents
e2d175db
54c0a66b
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
2 deletions
+17
-2
serializer.cpp
src/ngraph/serializer.cpp
+0
-0
serialize.cpp
test/serialize.cpp
+17
-2
No files found.
src/ngraph/serializer.cpp
View file @
fc6cd9ac
This diff is collapsed.
Click to expand it.
test/serialize.cpp
View file @
fc6cd9ac
...
...
@@ -99,7 +99,22 @@ TEST(serialize, existing_models)
{
const
string
json_path
=
file_util
::
path_join
(
SERIALIZED_ZOO
,
model
);
const
string
json_string
=
file_util
::
read_file_to_string
(
json_path
);
stringstream
ss
(
json_string
);
shared_ptr
<
Function
>
f
=
ngraph
::
deserialize
(
ss
);
shared_ptr
<
Function
>
f
=
ngraph
::
deserialize
(
json_string
);
}
}
TEST
(
benchmark
,
serialize
)
{
stopwatch
timer
;
string
model
=
"mxnet/LSTM_backward.json"
;
const
string
json_path
=
file_util
::
path_join
(
SERIALIZED_ZOO
,
model
);
timer
.
start
();
const
string
json_string
=
file_util
::
read_file_to_string
(
json_path
);
timer
.
stop
();
cout
<<
"file read took "
<<
timer
.
get_milliseconds
()
<<
"ms
\n
"
;
timer
.
start
();
shared_ptr
<
Function
>
f
=
ngraph
::
deserialize
(
json_string
);
timer
.
stop
();
cout
<<
"deserialize took "
<<
timer
.
get_milliseconds
()
<<
"ms
\n
"
;
}
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