
    `i                     R    d dl Zd dlmZ d dlmZ d dlmZ ej	        d             Z
dS )    N)runtime)	benchmark)
time_rangec               #      K   t          j                     	 dV  t          j                     dS # t          j                     w xY w)a  Enable CUDA profiling during with statement.

    This function enables profiling on entering a with statement, and disables
    profiling on leaving the statement.

    >>> with cupyx.profiler.profile():
    ...    # do something you want to measure
    ...    pass

    .. note::
        When starting ``nvprof`` from the command line, manually setting
        ``--profile-from-start off`` may be required for the desired behavior.
        Likewise, when using ``nsys profile`` setting ``-c cudaProfilerApi``
        may be required.

    .. seealso:: :func:`cupy.cuda.runtime.profilerStart`,
        :func:`cupy.cuda.runtime.profilerStop`
    N)_runtimeprofilerStartprofilerStop     k/home/jaya/work/projects/VOICE-AGENT/VIET/agent-env/lib/python3.11/site-packages/cupyx/profiler/__init__.pyprofiler      sO      (  s	   0 A)
contextlib_contextlib	cupy.cudar   r   cupyx.profiler._timer   cupyx.profiler._time_ranger   contextmanagerr   r
   r   r   <module>r      sp            ) ) ) ) ) ) * * * * * * 1 1 1 1 1 1          r   