Skip to main content

A package to re-size images

Project description

Coverage Status

Image ReSizer

This simple package re-sizes images from a given list of urls.

Installation

pip install imgresizer

Usage

It expects you to pass ita configuration as command line parameter.
imgresizer -c <path/to/conf_json>

A sample json:

{
    "targets": [
        400,
        200,
        100
    ],
    "data": "data",
    "num_threads": 8,
    "input_dir": "incoming",
    "output_dir" : "outgoing",
    "image_urls" : "/path/to/urls.txt"
}

Firstly, it downloads them and stores them inside data/input_dir directory. Then it starts processing images to re-size and store re-sized image to data/output_dir with its new size added to its name.

Additionally, you can pass -l true so that it logs the process.

Issues

Nothing yet. But it will need to speed up.

Tasks

  • [ ] Implement thread pooling
  • [ ] Make it re-size local images

License

ImgReSizer is released under the [MIT license] (https://choosealicense.com/licenses/mit/#)

Project details


Download files

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

Files for imgresizer, version 1.0.0
Filename, size File type Python version Upload date Hashes
Filename, size imgresizer-1.0.0-py3-none-any.whl (8.9 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size imgresizer-1.0.0.tar.gz (5.6 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page