Skip to main content

Dynamic image resizing tool

Project description

Imdix : Dynamic image file resizing tool

This tool automatically resizes the image file according to your needs, Let's say you have an image file of size 2 MB and you need to reduce size to 300 KB, use imdix

Install

pip install --upgrade imdix 

Usage

usage: dx [-h] --image IMAGE --size SIZE [--output OUTPUT] [--ext EXT]

Dynamic image file resizer

optional arguments:
  -h, --help            show this help message and exit
  --image IMAGE, -i IMAGE
                        Path to image file
  --size SIZE, -s SIZE  Target output size
  --output OUTPUT, -o OUTPUT
                        Output file name
  --ext EXT, -x EXT     Extension of output file

Example

Let's reduce this car image

by https://unsplash.com/@olav_tvedt @ https://unsplash.com/photos/6lSBynPRaAQ

dx --image images/car.jpg --size 5000 # all output sized must be in KBs
[ERROR] Target size(5000 KB) greater than file size(4210 KB)

Yes, we're going to reduce a 4 MB file. Let's reduce it to 200 KB

dx --image image/car.jpg --size 200

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

imdix-0.0.3.tar.gz (3.6 kB view hashes)

Uploaded Source

Built Distribution

imdix-0.0.3-py3-none-any.whl (4.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page