Safemotion Lib
Loading...
Searching...
No Matches
Classes | Functions | Variables
fastreid.utils.events Namespace Reference

Classes

class  CommonMetricPrinter
 
class  EventStorage
 
class  EventWriter
 
class  JSONWriter
 
class  TensorboardXWriter
 

Functions

 get_event_storage ()
 

Variables

list _CURRENT_STORAGE_STACK = []
 

Function Documentation

◆ get_event_storage()

fastreid.utils.events.get_event_storage ( )
Returns:
    The :class:`EventStorage` object that's currently being used.
    Throws an error if no :class:`EventStorage` is currently enabled.

Definition at line 24 of file events.py.

24def get_event_storage():
25 """
26 Returns:
27 The :class:`EventStorage` object that's currently being used.
28 Throws an error if no :class:`EventStorage` is currently enabled.
29 """
30 assert len(
31 _CURRENT_STORAGE_STACK
32 ), "get_event_storage() has to be called inside a 'with EventStorage(...)' context!"
33 return _CURRENT_STORAGE_STACK[-1]
34
35

Variable Documentation

◆ _CURRENT_STORAGE_STACK

list fastreid.utils.events._CURRENT_STORAGE_STACK = []
protected

Definition at line 21 of file events.py.