GithubHelp home page GithubHelp logo

jamiemason / image-optimisation-tools-comparison Goto Github PK

View Code? Open in Web Editor NEW
28.0 4.0 1.0 48.12 MB

A Benchmarking Suite for popular Image Optimisation Tools

Home Page: https://foldleft.io/image-tools

License: MIT License

Shell 10.38% TypeScript 89.62%
image-optimisation imagemagick imagemin imageoptim codekit kraken photoshop tinypng jpegmini imagealpha

image-optimisation-tools-comparison's Introduction

image-optimisation-tools-comparison

A benchmarking suite for popular image optimisation tools.

NPM version NPM downloads Build Status Maintainability

Table of Contents

🌩 Installation

npm install image-optimisation-tools-comparison

πŸ•Ή Usage

There are no runtime dependencies, getResults() parses and returns results.json.

import { getResults } from "image-optimisation-tools-comparison";

const array = getResults();

βš™οΈ Contributing

The pyssim Python module is used to compute the Structural Similarity Image Metric (SSIM). It can be installed on Mac using brew install python then pip install pyssim.

The original, unoptimised images are located in /images/photoshop. Each time a tool is tested, its directory (eg. /images/codekit) is replaced with the original images from /images/photoshop, the tool is then run over the images to update the benchmark.

/images/worst is a copy of the original images at /images/photoshop which is then compressed to the worst possible image quality. This value lets us calculate the quality loss percentage for each image.

Each time the /images directory changes, /src/data/results.json needs to be updated using yarn update-results.

These images used are exported from a .psd kindly given to us by Daan Jobsis from his tests carried out for the article [Retina Revolution: Follow Up](http://blog.netvlies.nl/design-interactie /retina-revolutie-follow-up/), containing photographs of varying levels of detail, simple patterns, and logos.

The images are exported using "Save for Web" as;

  • GIF (+Interlaced).
  • JPEG (+Optimised, Progressive).
  • PNG 8 (+Interlaced).
  • PNG 24 (+Interlaced).

πŸšΆπŸ½β€β™€οΈ Manual Steps

πŸ™‹πŸΎβ€β™€οΈ Getting Help

Get help with issues by creating a Bug Report or discuss ideas by opening a Feature Request.

πŸ‘€ Other Projects

If you find my Open Source projects useful, please share them ❀️

πŸ€“ Author

I'm Jamie Mason from Leeds in England, I began Web Design and Development in 1999 and have been Contracting and offering Consultancy as Fold Left Ltd since 2012. Who I've worked with includes Sky Sports, Sky Bet, Sky Poker, The Premier League, William Hill, Shell, Betfair, and Football Clubs including Leeds United, Spurs, West Ham, Arsenal, and more.

Follow JamieMason on GitHubΒ Β Β Β Β Β Follow fold_left on Twitter

image-optimisation-tools-comparison's People

Contributors

jamiemason avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

toy

image-optimisation-tools-comparison's Issues

Include CSS Sprite sheets.

CSS Image Sprites are a really common use case for images that isn't tested currently by the comparison suite - add some to learn whether they have any characteristics that affect the performance of the various tools.

Cannot sort "Worst Quality" column

When pressing the "Worst Quality" column header

Uncaught TypeError: Cannot read property 'score' of undefined
    at Constructor.sortAsc (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:23943:62)
    at Constructor.sortDesc (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:23946:21)
    at Array.sort (native)
    at Constructor.getResults (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:23901:14)
    at Constructor.render (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:23923:95)
    at ReactCompositeComponentWrapper._renderValidatedComponentWithoutOwnerOrContext (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:10448:34)
    at ReactCompositeComponentWrapper._renderValidatedComponent (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:10468:32)
    at ReactCompositeComponentWrapper.wrapper [as _renderValidatedComponent] (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:16916:21)
    at ReactCompositeComponentWrapper._updateRenderedComponent (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:10421:36)
    at ReactCompositeComponentWrapper._performComponentUpdate (http://jamiemason.github.io/image-optimisation-tools-comparison/dist/app/index.js:10405:10)

Update the benchmarks

The tests were last run in January 2016 and new versions of each app have been released.

"Server render" the results

The table of results is currently generated on the client-side with React, include it in the original HTML.

Compare using SSIM instead of MSE

I remember @pornel mentioning this β€” currently we are using compare -metric MSE but should switch to SSIM for more credible data.

Find what tools will provide this data and switch to them.

Filter by platform

Allow toggling display of platforms each tool is available for (osx, linux, windows etc).

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.