Skip to main content

ROS2-friendly function performance profiler

Project description

Pyros Performance

A high-performance Python library for benchmarking and profiling your code. it can be used for both ros2 functions and non-ros2 functions. project is part of the pyros library.

Installation

pip install pyros-performance

Quick Start

from pyros_performance import profiler

@profiler(log_in_console=True, log_in_ros=False)
def sum_numbers(*args, **kwargs):
    total = 0

    for value in args:
        total += value

    for value in kwargs.values():
        total += value

    return total

Example Output

Function Name: sum_numbers
Time Taken: 0.000008 sec
Current Memory: 0.00 MB
Peak Memory: 0.00 MB
CPU Usage: 0.00%

Features

  • Easy benchmarking - Simple API for measuring execution time
  • Memory profiling - Track memory usage during execution
  • Performance reports - Generate detailed performance metrics
  • Low overhead - Minimal impact on your code performance

Documentation

For detailed documentation, visit GitHub.

Requirements

  • Python 3.8+

License

MIT

Contributing

Contributions welcome! Please submit pull requests or issues on GitHub.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyros_performance-0.1.0.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyros_performance-0.1.0-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file pyros_performance-0.1.0.tar.gz.

File metadata

  • Download URL: pyros_performance-0.1.0.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for pyros_performance-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6a9c5d9a0036c9d9010affe549a9b4eef53e889081011d6ac6b2531101a17523
MD5 d3bd4e2287adc56110ba06efd52bde54
BLAKE2b-256 d2b35116251c71b5b6874dccbcd4c1a5f6102f7fb4829f8266153e659da8c67f

See more details on using hashes here.

File details

Details for the file pyros_performance-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for pyros_performance-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6e967c66dc67e6b770429a7d2d4531a64a7a357e00ce39c5ed28d109fad7edba
MD5 b5ce64f138d488321a5b49bcaec241b8
BLAKE2b-256 7c2800567fe7a7982e20801ae732ad5ab9d92ad08fa9a38897eaab40a09654d5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page