• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* Copyright 2015 The TensorFlow Authors. All Rights Reserved.
2 
3 Licensed under the Apache License, Version 2.0 (the "License");
4 you may not use this file except in compliance with the License.
5 You may obtain a copy of the License at
6 
7     http://www.apache.org/licenses/LICENSE-2.0
8 
9 Unless required by applicable law or agreed to in writing, software
10 distributed under the License is distributed on an "AS IS" BASIS,
11 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 See the License for the specific language governing permissions and
13 limitations under the License.
14 ==============================================================================*/
15 #ifndef TENSORFLOW_CORE_COMMON_RUNTIME_PROPAGATOR_DEBUG_UTILS_H_
16 #define TENSORFLOW_CORE_COMMON_RUNTIME_PROPAGATOR_DEBUG_UTILS_H_
17 
18 namespace tensorflow {
19 
20 struct Entry;
21 struct NodeItem;
22 class Tensor;
23 
24 // Returns a pointer to the tensor in `input` if one exists, or `nullptr`.
25 const Tensor* GetTensorValueForDump(const Entry& input);
26 
27 // Writes a LOG(WARNING) message describing the state of the given pending node
28 // in the graph described by `immutable_state`.
29 void DumpPendingNodeState(const NodeItem& node_item, const Entry* input_vector,
30                           const bool show_nodes_with_no_ready_inputs);
31 
32 // Writes a LOG(WARNING) message describing the state of the given active node
33 // in the graph described by `immutable_state`.
34 void DumpActiveNodeState(const NodeItem& node_item, const Entry* input_vector);
35 
36 }  // namespace tensorflow
37 
38 #endif  // TENSORFLOW_CORE_COMMON_RUNTIME_PROPAGATOR_DEBUG_UTILS_H_
39