.. _f-profiling: module ``pycode.profiling`` =========================== .. inheritance-diagram:: pyquickhelper.pycode.profiling Short summary +++++++++++++ module ``pyquickhelper.pycode.profiling`` Profiling helpers :githublink:`%|py|5` Classes +++++++ +-------------------------------------------------------------------+-------------------------------------------+ | class | truncated documentation | +===================================================================+===========================================+ | :class:`ProfileNode ` | Graph structure to represent a profiling. | +-------------------------------------------------------------------+-------------------------------------------+ | :class:`SortKey ` | | +-------------------------------------------------------------------+-------------------------------------------+ Functions +++++++++ +--------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ | function | truncated documentation | +==========================================================================+========================================================================================================================+ | :func:`_process_pstats ` | Converts class `Stats `_ into something readable for ... | +--------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ | :func:`profile ` | Profiles the execution of a function. | +--------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ | :func:`profile2df ` | Converts profiling statistics into a Dataframe. | +--------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ | :func:`profile2graph ` | Converts profiling statistics into a graphs. | +--------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ Properties ++++++++++ +--------------------------------------------------------------+-------------------------+ | property | truncated documentation | +==============================================================+=========================+ | :meth:`key ` | Returns `file:line`. | +--------------------------------------------------------------+-------------------------+ Static Methods ++++++++++++++ +--------------------------------------------------------------------------------+----------------------------------------------+ | staticmethod | truncated documentation | +================================================================================+==============================================+ | :py:meth:`_key ` | | +--------------------------------------------------------------------------------+----------------------------------------------+ | :meth:`filter_node_ ` | Filters out node to be displayed by default. | +--------------------------------------------------------------------------------+----------------------------------------------+ Methods +++++++ +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | method | truncated documentation | +==================================================================================+================================================================================================================+ | :py:meth:`__init__ ` | | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :py:meth:`__iter__ ` | Returns all nodes in the graph. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :py:meth:`__repr__ ` | usual | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :meth:`add_called_by ` | This function is called by these lines. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :meth:`add_calls_to ` | This function calls this node. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :meth:`as_dict ` | Renders the results of a profiling interpreted with function @fn profile2graph. It can then be loaded with ... | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :meth:`get_root ` | Returns the root of the graph. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :meth:`to_json ` | Renders the results of a profiling interpreted with function @fn profile2graph as :epkg:`JSON`. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ | :meth:`to_text ` | Prints the profiling to text. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------+ Documentation +++++++++++++ .. automodule:: pyquickhelper.pycode.profiling :members: :special-members: __init__ :show-inheritance: