SkillAgentSearch skills...

Pyprof

A simple python profiler

Install / Use

/learn @yotamraz/Pyprof
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

pyprof

Track your CPU/RAM/GPU(CUDA) utilization with an easy-to-use context wrapper

Install

~$ git clone https://github.com/yotamraz/pyprof.git

~$ cd pyprof

~$ pip install -r requirements.txt

Use

from pyprof.profiler import Profiler

with Profiler(output_file_path='./') as prof:
    funky_func()

Results

stdout:

########## CPU_utilization_% ##########
Peak: 74.425 %


########## total_RAM_memory_usage_MB ##########
Peak: 19519.48046875 MB


########## GPU_utilization_% ##########
Peak: 84.0 %


########## total_GPU_memory_usage_MB ##########
Peak: 7950.625 MB


########## total runtime ##########
0:00:04.035351

html:

example_plot.png

View on GitHub
GitHub Stars10
CategoryDevelopment
Updated1y ago
Forks0

Languages

Python

Security Score

75/100

Audited on May 5, 2024

No findings