.. _f-optopk: module ``onnxrt.ops_cpu.op_topk`` ================================= .. inheritance-diagram:: mlprodict.onnxrt.ops_cpu.op_topk Short summary +++++++++++++ module ``mlprodict.onnxrt.ops_cpu.op_topk`` Runtime operator. :githublink:`%|py|7` Classes +++++++ +---------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------+ | class | truncated documentation | +=====================================================================+============================================================================================================================+ | :class:`_CommonTopK ` | Ths class hides a parameter used as a threshold above which the parallelisation is started: ``th_para``. | +---------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------+ | :class:`TopK_1 ` | | +---------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------+ | :class:`TopK_10 ` | | +---------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------+ | :class:`TopK_11 ` | TopK ==== Retrieve the top-K largest or smallest elements along a specified axis. Given an input tensor of shape [a_1, ... | +---------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------+ | :class:`TopK_11 ` | TopK ==== Retrieve the top-K largest or smallest elements along a specified axis. Given an input tensor of shape [a_1, ... | +---------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------+ Functions +++++++++ +----------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+ | function | truncated documentation | +==========================================================================================================+======================================================================================================================+ | :func:`topk_sorted_implementation ` | Retrieves the top-k elements. | +----------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+ | :func:`topk_sorted_implementation_cpp ` | Retrieves the top-k elements using a C++ implementation when the axis is the last dimension, otherwise, it falls ... | +----------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+ Properties ++++++++++ +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | property | truncated documentation | +====================================================================================================+=======================================================================================================================+ | :meth:`args_default ` | Returns the list of arguments as well as the list of parameters with the default values (close to the signature). ... | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default ` | Returns the list of arguments as well as the list of parameters with the default values (close to the signature). ... | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default ` | Returns the list of arguments as well as the list of parameters with the default values (close to the signature). ... | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default ` | Returns the list of arguments as well as the list of parameters with the default values (close to the signature). ... | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default ` | Returns the list of arguments as well as the list of parameters with the default values (close to the signature). ... | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default_modified ` | Returns the list of modified parameters. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default_modified ` | Returns the list of modified parameters. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default_modified ` | Returns the list of modified parameters. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default_modified ` | Returns the list of modified parameters. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_default_modified ` | Returns the list of modified parameters. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_mandatory ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_mandatory ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_mandatory ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_mandatory ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_mandatory ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_optional ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_optional ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_optional ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_optional ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`args_optional ` | Returns the list of optional arguments. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`atts_value ` | Returns all parameters in a dictionary. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`atts_value ` | Returns all parameters in a dictionary. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`atts_value ` | Returns all parameters in a dictionary. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`atts_value ` | Returns all parameters in a dictionary. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ | :meth:`atts_value ` | Returns all parameters in a dictionary. | +----------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+ Methods +++++++ +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | method | truncated documentation | +===================================================================================+====================================================================================================================+ | :py:meth:`__init__ ` | | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`__init__ ` | | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`__init__ ` | | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`__init__ ` | | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`__init__ ` | | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_common_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_common_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_common_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_common_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_common_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :py:meth:`_run ` | Runtime for operator *TopK*. The implementation is not the most efficient as it sorts everything then extracts ... | +-----------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------+ Documentation +++++++++++++ .. automodule:: mlprodict.onnxrt.ops_cpu.op_topk :members: :special-members: __init__ :show-inheritance: