aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/core/grappler/costs/op_level_cost_estimator.h
diff options
context:
space:
mode:
authorGravatar Max Galkin <maxgalkin@google.com>2017-12-01 14:48:56 -0800
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-12-01 14:52:24 -0800
commitd0ae1064ed0bb4bd1aed00afd4235f4dd5c853f0 (patch)
treeb077af5e338ac90aa8d10046e188943c049b24b0 /tensorflow/core/grappler/costs/op_level_cost_estimator.h
parent10f77231b005c76b5a771243e18384b4b66be325 (diff)
Prefix inaccurate costs with "~" in VirtualScheduler verbose log.
Fix some inaccurate estimates exposed by this approach: - propagate the inaccuracy flag when merging device stats; - estimate Const as no-op; - estimate RandomUniform, Relu and Softmax as element-wise; - consider estimates accurate for known element-wise ops in op_level_cost_estimator. PiperOrigin-RevId: 177643976
Diffstat (limited to 'tensorflow/core/grappler/costs/op_level_cost_estimator.h')
-rw-r--r--tensorflow/core/grappler/costs/op_level_cost_estimator.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/tensorflow/core/grappler/costs/op_level_cost_estimator.h b/tensorflow/core/grappler/costs/op_level_cost_estimator.h
index 3a8385dd73..c6f23ee0aa 100644
--- a/tensorflow/core/grappler/costs/op_level_cost_estimator.h
+++ b/tensorflow/core/grappler/costs/op_level_cost_estimator.h
@@ -45,11 +45,11 @@ class OpLevelCostEstimator {
// Returns basic device performance info.
virtual DeviceInfo GetDeviceInfo(const DeviceProperties& device) const;
- // For operations for which we haven't yet built estimates, returns a dummy
- // value based on input size.
- Costs DummyExecutionTime(const OpContext& op_context) const;
+ // Predict cost of an op for which no accurate estimator is defined.
+ Costs PredictCostOfAnUnknownOp(const OpContext& op_context) const;
- // Naive cost estimate based on operations divided by device ops/sec.
+ // Naive cost estimate based on operations divided by device ops/sec,
+ // and input/output tensor sizes.
Costs PredictOpCountBasedCost(double operations,
const OpInfo& op_features) const;