eprofiler


Nameeprofiler JSON
Version 0.0.5 PyPI version JSON
download
home_pagehttps://github.com/eyukselen/eprofiler
Summarya simple tool to monitor execution times of functions.
upload_time2024-03-04 01:48:39
maintainer
docs_urlNone
authoremre
requires_python
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # eprofiler

Execution profiler

a simple tool to monitor execution times of functions.  can be installed from pypi

```pip install eprofiler```  

https://pypi.org/project/eprofiler/  
https://github.com/eyukselen/eprofiler  

import `timeit` function and use as a decorator for the function you want to monitor
if you pass an empty dict to it as below, you can get the results and use it in code.
otherwise it will print duration.


## usage:
```
from eprofiler import timeit

print("without stats dict provided")


@timeit()
def my_func_to_test():
    for x in range(100000):
        y = x ^ 2


my_func_to_test()
stats = {}

print("without stats dict provided")


@timeit(stats)
def my_func_to_test_with_stats():
    for x in range(100000):
        y = x ^ 2


my_func_to_test_with_stats()
print(stats)
```




            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/eyukselen/eprofiler",
    "name": "eprofiler",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "",
    "author": "emre",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/20/fc/aa70ecb3ff171a1ff7c8705284733d8a4ffb191d40c5961e3bc7fe88ef4c/eprofiler-0.0.5.tar.gz",
    "platform": null,
    "description": "# eprofiler\n\nExecution profiler\n\na simple tool to monitor execution times of functions.  can be installed from pypi\n\n```pip install eprofiler```  \n\nhttps://pypi.org/project/eprofiler/  \nhttps://github.com/eyukselen/eprofiler  \n\nimport `timeit` function and use as a decorator for the function you want to monitor\nif you pass an empty dict to it as below, you can get the results and use it in code.\notherwise it will print duration.\n\n\n## usage:\n```\nfrom eprofiler import timeit\n\nprint(\"without stats dict provided\")\n\n\n@timeit()\ndef my_func_to_test():\n    for x in range(100000):\n        y = x ^ 2\n\n\nmy_func_to_test()\nstats = {}\n\nprint(\"without stats dict provided\")\n\n\n@timeit(stats)\ndef my_func_to_test_with_stats():\n    for x in range(100000):\n        y = x ^ 2\n\n\nmy_func_to_test_with_stats()\nprint(stats)\n```\n\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "a simple tool to monitor execution times of functions.",
    "version": "0.0.5",
    "project_urls": {
        "Documentation": "https://eprofiler.readthedocs.io/en/latest/index.html",
        "Homepage": "https://github.com/eyukselen",
        "Source": "https://github.com/eyukselen/eprofiler"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "29f9019c8be59286832dbb2c66ddc774688ee937da38fc1e2fc483e5d8600919",
                "md5": "b52103062ea9425b4fd29ddb4617b757",
                "sha256": "64a9e946a38bf2a8ab242d715ad0080efa35b1c0db3ae251c867f4ce1765df5e"
            },
            "downloads": -1,
            "filename": "eprofiler-0.0.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "b52103062ea9425b4fd29ddb4617b757",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 2898,
            "upload_time": "2024-03-04T01:48:37",
            "upload_time_iso_8601": "2024-03-04T01:48:37.722347Z",
            "url": "https://files.pythonhosted.org/packages/29/f9/019c8be59286832dbb2c66ddc774688ee937da38fc1e2fc483e5d8600919/eprofiler-0.0.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "20fcaa70ecb3ff171a1ff7c8705284733d8a4ffb191d40c5961e3bc7fe88ef4c",
                "md5": "a9c70aedbecbd45148153e5241c95551",
                "sha256": "2d407781b9d7de13de4bd00794332a7132d9fc83a4d153efa390571cbfb7f00c"
            },
            "downloads": -1,
            "filename": "eprofiler-0.0.5.tar.gz",
            "has_sig": false,
            "md5_digest": "a9c70aedbecbd45148153e5241c95551",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 2960,
            "upload_time": "2024-03-04T01:48:39",
            "upload_time_iso_8601": "2024-03-04T01:48:39.587909Z",
            "url": "https://files.pythonhosted.org/packages/20/fc/aa70ecb3ff171a1ff7c8705284733d8a4ffb191d40c5961e3bc7fe88ef4c/eprofiler-0.0.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-04 01:48:39",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "eyukselen",
    "github_project": "eprofiler",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "eprofiler"
}
        
Elapsed time: 0.21577s