Code Monkey home page Code Monkey logo

helpyourself's Introduction

HelpYourself

Mixed set of things that can help accomplish certain specific tasks.

Contents

Image compression

  1. 'imgCompression.py' -- Compress JPEG files by utilizing python's Pillow library.
  • Assuming python3 and Pillow is already installed, copy file to folder containing images.
  • Edit 'quality' parameter to the level of compression needed. Ideal value between 65 to 80 is fine.
  • Run the script.
  • Compressed images are stored in a folder called 'compressedImages' in the same folder where the script is present. NOTE: A line with reference to PNG is present. It's only to handle incase files with PNG format are encountered in the folder while running the script.
  1. 'tinify.py' -- Compress PNG/JPEG files using tinify API. The optimization is done automatically by the API.
  • With python3 installed, run pip install tinify
  • Place your API key inside the file. (Go to https://tinypng.com/developers. Key will be sent to your email.)
  • Make sure the path your image folder is provided correctly. Also the folder should contain only JPEG/PNG as any other format would result in an error.
  • Run the script. NOTE: For free users, the number of images you can upload for compression is limited(500/month at the time of writing this.)

helpyourself's People

Contributors

mohdizzy avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.