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
f568ca59
Unverified
Commit
f568ca59
authored
Feb 07, 2018
by
Neal Wu
Committed by
GitHub
Feb 07, 2018
Browse files
Merge pull request #3340 from tensorflow/convert_image_dtype-explanation
Add a note about tf.image.convert_image_dtype
parents
40d29d42
6eeec4e7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
official/resnet/imagenet_main.py
official/resnet/imagenet_main.py
+2
-0
No files found.
official/resnet/imagenet_main.py
View file @
f568ca59
...
...
@@ -82,6 +82,8 @@ def parse_record(raw_record, is_training):
image
=
tf
.
image
.
decode_image
(
tf
.
reshape
(
parsed
[
'image/encoded'
],
shape
=
[]),
_NUM_CHANNELS
)
# Note that tf.image.convert_image_dtype scales the image data to [0, 1).
image
=
tf
.
image
.
convert_image_dtype
(
image
,
dtype
=
tf
.
float32
)
image
=
vgg_preprocessing
.
preprocess_image
(
...
...
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