diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2018-08-28 13:35:10 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-08-28 13:41:11 -0700 |
commit | eece29de7b888ccee3f758d2de0967ad674c87a3 (patch) | |
tree | fd74e39d4e6e47f1cc38cbff7307f8f312e9be50 /tensorflow/core/distributed_runtime | |
parent | 88ab8b0bd6ca4dba10a5ed8852e23eacfb0f888e (diff) |
Removed redundant std::string -> string conversions.
PiperOrigin-RevId: 210596417
Diffstat (limited to 'tensorflow/core/distributed_runtime')
-rw-r--r-- | tensorflow/core/distributed_runtime/master_session.cc | 6 | ||||
-rw-r--r-- | tensorflow/core/distributed_runtime/remote_device.cc | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tensorflow/core/distributed_runtime/master_session.cc b/tensorflow/core/distributed_runtime/master_session.cc index d34ca53f73..abd07e37b7 100644 --- a/tensorflow/core/distributed_runtime/master_session.cc +++ b/tensorflow/core/distributed_runtime/master_session.cc @@ -615,7 +615,7 @@ Status MasterSession::ReffedClientGraph::RunPartitionsHelper( // inadvertently slowing down the normal run path. if (is_partial_) { for (const auto& name_index : feeds) { - const auto iter = part.feed_key.find(std::string(name_index.first)); + const auto iter = part.feed_key.find(string(name_index.first)); if (iter == part.feed_key.end()) { // The provided feed must be for a different partition. continue; @@ -959,7 +959,7 @@ Status MasterSession::ReffedClientGraph::CheckFetches( // Skip if already fed. if (input.second) continue; TensorId id(ParseTensorName(input.first)); - const Node* n = execution_state->get_node_by_name(std::string(id.first)); + const Node* n = execution_state->get_node_by_name(string(id.first)); if (n == nullptr) { return errors::NotFound("Feed ", input.first, ": not found"); } @@ -975,7 +975,7 @@ Status MasterSession::ReffedClientGraph::CheckFetches( for (size_t i = 0; i < req.num_fetches(); ++i) { const string& fetch = req.fetch_name(i); const TensorId id(ParseTensorName(fetch)); - const Node* n = execution_state->get_node_by_name(std::string(id.first)); + const Node* n = execution_state->get_node_by_name(string(id.first)); if (n == nullptr) { return errors::NotFound("Fetch ", fetch, ": not found"); } diff --git a/tensorflow/core/distributed_runtime/remote_device.cc b/tensorflow/core/distributed_runtime/remote_device.cc index 15e5919c54..a043c5dee6 100644 --- a/tensorflow/core/distributed_runtime/remote_device.cc +++ b/tensorflow/core/distributed_runtime/remote_device.cc @@ -37,7 +37,7 @@ string GetLocalDeviceName(StringPiece fullname) { auto pos = fullname.rfind('/'); CHECK_NE(pos, StringPiece::npos); fullname.remove_prefix(pos + 1); - return std::string(fullname); + return string(fullname); } class RemoteDevice : public Device { |