Benchmark for image reading for different libraries.
Project description
I/O benchmark
I/O benchmark for different image processing python libraries.
The code is inspired by the work of Alex Parinov:
https://github.com/albu/albumentations/blob/master/benchmark/benchmark.py
The idea is inspired by the work of Roman Soloviov:
https://www.kaggle.com/zfturbo/benchmark-2019-speed-of-image-reading
Installation
sudo apt install libturbojpeg
You can use pip to install imread_benchmark
:
pip install imread_benchmark
If you want to get the latest version of the code before it is released on PyPI you can install the library from GitHub:
pip install -U git+https://github.com/ternaus/imread_benchmark
To calculate the I/O speed of your SSD/HDD in Linux
sudo apt-get install hdparm
sudo hdparm -Tt <disk_id>
where disk_id
is of the type /dev/sda
As a result you may expect something like:
/dev/sda:
Timing cached reads: 26114 MB in 1.99 seconds = 13122.03 MB/sec
Timing buffered disk reads: 1062 MB in 3.00 seconds = 353.70 MB/sec
To run the benchmark
To get the description of all input parameters
imread_benchmark -h
imread_benchmark -d <path to images> \
-i <number of images to use> \
-r <number of repeats>
Extra options:
-p
- to print benchmarked libraries versions
-s
- to shuffle images on every run
Libraries that are benchmarked:
- OpenCV
- pillow (PIL)
- jpeg4py
- scikit-image (skimage)
- imageio
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
imread_benchmark-0.0.3.tar.gz
(5.0 kB
view hashes)
Built Distribution
Close
Hashes for imread_benchmark-0.0.3-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 164177b8c87bc1aa25dea07c8d9d27fd4b64a2edd2a5f90fe1fd6b6c4b25d143 |
|
MD5 | 6109e39fae978bed8ae0512f01598663 |
|
BLAKE2b-256 | 90d40c7c6419c7ba4a12274f81f63d4afe493e66e7d04b1ec25ad260bc9324fd |