MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / GetEventCollector

Function GetEventCollector

tensorflow/core/platform/tracing.h:76–81  ·  view source on GitHub ↗

Returns the callback for RecordEvent and ScopedRegion of category if EventCollector::IsEnabled(), otherwise returns null.

Source from the content-addressed store, hash-verified

74// Returns the callback for RecordEvent and ScopedRegion of category if
75// EventCollector::IsEnabled(), otherwise returns null.
76inline const EventCollector* GetEventCollector(EventCategory category) {
77 if (EventCollector::IsEnabled()) {
78 return EventCollector::instances_[static_cast<unsigned>(category)];
79 }
80 return nullptr;
81}
82
83// Returns a unique id to pass to RecordEvent/ScopedRegion. Never returns zero.
84uint64 GetUniqueArg();

Callers 3

ExecutorStateMethod · 0.85
RecordEventFunction · 0.85
ScopedRegionMethod · 0.85

Calls 1

IsEnabledFunction · 0.85

Tested by

no test coverage detected