Fast Python Script Execution Timer
Project description
FFpy is a command-line tool that measures the execution time of Python scripts. It provides flexibility by allowing you to specify the time unit (milliseconds or seconds) and the number of runs for more accurate measurements.
Installation
Install FFpy using pip:
pip install ffpy
Alternatively, you can clone this repository:
git clone https://github.com/anxkhn/FFpy.git cd FFpy pip install .
Usage
After installation, you can use FFpy to measure the execution time of your Python scripts. Here’s the basic syntax:
ffpy <script_filename> [-ms | -s] [-n <num_runs>]
<script_filename>: Replace with the actual filename of your Python script.
-ms or -s: Optional flag to specify the time unit (milliseconds or seconds, default is milliseconds).
-n <num_runs>: Optional flag to specify the number of runs (default is 1).
Examples
Measure the execution time of a script in milliseconds:
ffpy my_script.py
Measure the execution time in seconds:
ffpy my_script.py -s
Run the script 10 times and measure the average execution time:
ffpy my_script.py -n 10
Contributing
If you’d like to contribute to FFpy, feel free to fork the repository and submit a pull request.
License
This project is licensed under the GPLv3 License - check out this website for more information.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.