Skip to main content

Model Meter

Project description

ModelMeter

ModelMeter

Unrestricted class structure compatibility and focused throughput assessment for your model's performance evaluation

Requirements

Python 3.8+

Installation

pip install model-meter

---> 100%

Example

Create it

  • Create a file main.py with:
from model_meter import ModelMeter
from ultralytics import YOLO

# Load the model
model = YOLO()

# Create the meter
meter = ModelMeter(model)

# Run the meter
throughput, avg_time_per_call = meter.measure(
    params=('./contents/dog.jpg',), 
    method_name="__call__",
)

print(f'Throughput: {throughput} images/second')
print(f'Avg time per call: {avg_time_per_call} seconds')

Run it

Run the script with:

$ python main.py

...

Throughput: 14.794271662158552 images/second
Avg time per call: 0.0675937297107937 seconds

License

This project is licensed under the terms of the MIT license.

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

model_meter-0.2.1.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

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

model_meter-0.2.1-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file model_meter-0.2.1.tar.gz.

File metadata

  • Download URL: model_meter-0.2.1.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.3

File hashes

Hashes for model_meter-0.2.1.tar.gz
Algorithm Hash digest
SHA256 44056142d91f6e2c048356b30e91ee8e9fbf3a5b5ec60e4fcade206540f24408
MD5 5ddd079a45d1a7cccd712e9f668d6202
BLAKE2b-256 6b6003ea9a2c1955b4345d05a59bbf8911f1f2f62a7fa9c7ac806fa1471c9da5

See more details on using hashes here.

File details

Details for the file model_meter-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: model_meter-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.3

File hashes

Hashes for model_meter-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6dc6121b39ac4d9518341e82e6d3e8e57ad0b5541588037c47049079403ec867
MD5 51fbe9ad3886f5897f4c086fc552c8d6
BLAKE2b-256 5d72953e5b2679fe1a4a9a905a768b7f0aad348f7c5d6550457da87553522539

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