1 | #pragma once |
2 | |
3 | #include <c10/macros/Export.h> |
4 | #include <string> |
5 | |
6 | namespace torch { |
7 | namespace profiler { |
8 | namespace impl { |
9 | |
10 | // Adds the execution graph observer as a global callback function, the data |
11 | // will be written to output file path. |
12 | TORCH_API bool addExecutionGraphObserver(const std::string& output_file_path); |
13 | |
14 | // Remove the execution graph observer from the global callback functions. |
15 | TORCH_API void removeExecutionGraphObserver(); |
16 | |
17 | // Enables execution graph observer. |
18 | TORCH_API void enableExecutionGraphObserver(); |
19 | |
20 | // Disables execution graph observer. |
21 | TORCH_API void disableExecutionGraphObserver(); |
22 | |
23 | } // namespace impl |
24 | } // namespace profiler |
25 | } // namespace torch |
26 | |