Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

compress image without losing quality

Project description

Image compression using Python

Image compression is done to reduce the cost of storage and transmission Steps

  1. Open the file and read it
  2. Get the pixel values in RGB format
  3. Convert the tuples into one list
  4. Round the pixel values to nearest 10
  5. Regroup the pixel values into tuple of 3
  6. Create a new image from the tuple list where each pixel value in tuple indicate R,G,B value E.g. (42,34,67) indicates R=42,G=34,B=67
  7. Save the compressed image

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 image-compression, version 0.4
Filename, size File type Python version Upload date Hashes
Filename, size image-compression-0.4.tar.gz (1.9 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page