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
6f8012b7
Commit
6f8012b7
authored
Sep 25, 2018
by
Aman Gupta
Browse files
Removing export_outputs value from TPUEstimator. This is not required with TPUEstimators
parent
dfe2a43f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
5 deletions
+2
-5
official/mnist/mnist_tpu.py
official/mnist/mnist_tpu.py
+2
-5
No files found.
official/mnist/mnist_tpu.py
View file @
6f8012b7
...
@@ -96,10 +96,7 @@ def model_fn(features, labels, mode, params):
...
@@ -96,10 +96,7 @@ def model_fn(features, labels, mode, params):
'probabilities'
:
tf
.
nn
.
softmax
(
logits
),
'probabilities'
:
tf
.
nn
.
softmax
(
logits
),
'label'
:
labels
,
'label'
:
labels
,
}
}
return
tf
.
contrib
.
tpu
.
TPUEstimatorSpec
(
mode
,
predictions
=
predictions
,
return
tf
.
contrib
.
tpu
.
TPUEstimatorSpec
(
mode
,
predictions
=
predictions
)
export_outputs
=
{
'classify'
:
tf
.
estimator
.
export
.
PredictOutput
(
predictions
)
})
logits
=
model
(
image
,
training
=
(
mode
==
tf
.
estimator
.
ModeKeys
.
TRAIN
))
logits
=
model
(
image
,
training
=
(
mode
==
tf
.
estimator
.
ModeKeys
.
TRAIN
))
loss
=
tf
.
losses
.
sparse_softmax_cross_entropy
(
labels
=
labels
,
logits
=
logits
)
loss
=
tf
.
losses
.
sparse_softmax_cross_entropy
(
labels
=
labels
,
logits
=
logits
)
...
...
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