Module Expr Str ImportFrom alias ImportFrom alias ImportFrom alias Import alias Import alias FunctionDef arguments args NameParam defaults body With Call NameLoad NameStore body Expr Yield Expr Call NameLoad Call AttributeLoad Str attr NameLoad AttributeLoad NameLoad attr decorator_list AttributeLoad NameLoad attr FunctionDef arguments args defaults body Assign NameStore Call NameLoad Expr Call AttributeLoad NameLoad attr TryFinally body Expr Yield NameLoad finalbody Expr Call AttributeLoad NameLoad attr decorator_list AttributeLoad NameLoad attr ClassDef bases NameLoad body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assert CompareIsNot AttributeLoad NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Num If CompareIsNot AttributeLoad NameLoad attr NameLoad body Assign NameStore AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body If CompareIs AttributeLoad NameLoad attr NameLoad body Assert CompareIsNot AttributeLoad NameLoad attr NameLoad If CompareIs AttributeLoad NameLoad attr NameLoad body Assign NameStore BinOpSub Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Return NameLoad Assign AttributeStore NameLoad attr BinOpSub AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Return AttributeLoad NameLoad attr decorator_list NameLoad decorator_list
N/A N/A Determine the wall clock duration of events. __future__ absolute_import __future__ division __future__ print_function N/A contextlib N/A datetime print_duration_context N/A N/A name N/A N/A N/A N/A timer_context t N/A N/A N/A N/A N/A print N/A N/A {} took {} secs format name N/A t duration N/A N/A contextlib contextmanager timer_context N/A N/A N/A N/A N/A timer N/A Timer N/A N/A N/A timer start N/A N/A N/A N/A timer N/A N/A N/A N/A timer stop N/A N/A contextlib contextmanager Timer N/A object N/A __init__ N/A N/A self N/A N/A N/A N/A self _start None N/A N/A self _stop None N/A N/A self _duration None N/A start N/A N/A self N/A N/A N/A N/A self _start N/A N/A N/A datetime datetime utcnow N/A N/A self _stop None N/A N/A self _duration None N/A stop N/A N/A self N/A N/A N/A N/A N/A self _start None N/A N/A self _stop N/A N/A N/A datetime datetime utcnow N/A restart N/A N/A self N/A N/A N/A Start the timer, return the previous duration.

        If there is no previous duration then return 0.0.

        Usage example:
            >>> timer = Timer()
            >>> timer.restart() >= 0.0
            True
            >>> timer.restart() >= 0.0
            True

        :returns: a floating point number of seconds

         N/A duration 0.0 N/A N/A N/A self _start None N/A N/A duration N/A self duration N/A N/A N/A self start N/A duration N/A duration N/A N/A self N/A N/A N/A N/A N/A self _duration None N/A N/A N/A N/A self _start None N/A N/A N/A self _stop None N/A N/A duration N/A N/A N/A N/A datetime datetime utcnow N/A self _start N/A duration N/A N/A duration total_seconds N/A duration N/A N/A self _duration N/A N/A self _stop N/A self _start N/A N/A self _duration N/A N/A N/A self _duration total_seconds N/A N/A self _duration N/A property N/A