Giter Club home page Giter Club logo

pixelate-redactor's Introduction

pixelate-redactor

Redact images with pixels

Works with Python >= 2.6, Python >= 3.2.

Installation

pip install pixelate-redactor

Example

pixelate-redactor

pixelate-redactor \
  --input=img/example_img_original.png \
  --output=img/example_img_redacted.png \
  --pixel-size=10 \
  --start-x=90 \
  --start-y=180 \
  --size-x=150 \
  --size-y=150

pixelate-redactor-boxes

pixelate-redactor \
  --input=img/example_img_original.png \
  --output=img/example_img_redacted.png \
  --pixel-size=10 \
  --boxes=img/boxes.json

with img/boxes.json:

{
  "__box_name_1__": {
    "px": 90,
    "py": 180,
    "sx": 150,
    "sy": 150
  },
  "__box_name_2__": {
    "px": 90,
    "py": 180,
    "sx": 150,
    "sy": 150
  }
}

(the values are the same, to keep the same result from the single box example)

  • px -> Position X
  • py -> Position Y
  • sx -> Size X
  • sy -> Size Y

Results

From this:

original

To this:

redacted

pixelate-redactor's People

Contributors

bugov avatar eradash avatar gableroux avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

gableroux

pixelate-redactor's Issues

Add support for list of boxes to redact

I want to be able to send a list (like in a JSON or whatever format that would be easy to send in command line) of boxes to redact on an image.

Currently, the only way to redact multiple parts of an image, is using multiple time the command, which is not efficient nor elegant.

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.