MCPcopy Index your code
hub / github.com/pythonprofilers/memory_profiler / _count_ctxmgr

Method _count_ctxmgr

memory_profiler.py:741–746  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

739
740 @contextmanager
741 def _count_ctxmgr(self):
742 self.enable_by_count()
743 try:
744 yield
745 finally:
746 self.disable_by_count()
747
748 def wrap_function(self, func):
749 """ Wrap a function to profile it.

Callers 1

fMethod · 0.95

Calls 2

enable_by_countMethod · 0.95
disable_by_countMethod · 0.95

Tested by

no test coverage detected