Metadata-Version: 2.1
Name: imgresizer
Version: 1.0.0
Summary: A package to re-size images
Home-page: https://github.com/UnboxingMinds/ImgReSizer
Author: Tumurtogtokh Davaakhuu
Author-email: tumurtogtokh@gmail.com
License: MIT
Platform: UNKNOWN
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Description-Content-Type: text/markdown
Requires-Dist: requests (>=2)
Requires-Dist: Pillow (>=5.4)
Requires-Dist: imagesize (>=1.1)

[![Coverage Status](https://coveralls.io/repos/github/UnboxingMinds/ImgReSizer/badge.svg?branch=master)](https://coveralls.io/github/UnboxingMinds/ImgReSizer?branch=master)

# 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:

```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/#)


