Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ModelZoo
ResNet50_tensorflow
Commits
bd56a06d
Unverified
Commit
bd56a06d
authored
Jun 04, 2018
by
Jon Shlens
Committed by
GitHub
Jun 04, 2018
Browse files
Merge pull request #3639 from ppwwyyxx/patch-1
Fix build_imagenet_data.py for python2
parents
02571056
39b7dcf9
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
research/inception/inception/data/build_imagenet_data.py
research/inception/inception/data/build_imagenet_data.py
+1
-1
No files found.
research/inception/inception/data/build_imagenet_data.py
View file @
bd56a06d
...
@@ -171,7 +171,7 @@ def _float_feature(value):
...
@@ -171,7 +171,7 @@ def _float_feature(value):
def
_bytes_feature
(
value
):
def
_bytes_feature
(
value
):
"""Wrapper for inserting bytes features into Example proto."""
"""Wrapper for inserting bytes features into Example proto."""
if
isinstance
(
value
,
six
.
string
_type
s
):
if
six
.
PY3
and
isinstance
(
value
,
six
.
text
_type
):
value
=
six
.
binary_type
(
value
,
encoding
=
'utf-8'
)
value
=
six
.
binary_type
(
value
,
encoding
=
'utf-8'
)
return
tf
.
train
.
Feature
(
bytes_list
=
tf
.
train
.
BytesList
(
value
=
[
value
]))
return
tf
.
train
.
Feature
(
bytes_list
=
tf
.
train
.
BytesList
(
value
=
[
value
]))
...
...
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