Git Product home page Git Product logo

blurfaces's Introduction

blurfaces

Tool Description

Blurs faces in video.

sample mode=all, censor-type=gaussianblur
ross.mp4
out.mp4
mode=one, censor-type=pixelation mode=allexcept, censor-type=facemasking
out_one_pixelation_ross.mp4
out.mp4

Installation

  1. Make sure you have Python version 3.10.6 or greater installed

  2. Download the tool's repository using the command:

     git clone [email protected]:raviksharma/blurfaces.git
    
  3. Move to the tool's directory and install the tool

     cd blurfaces
     pip install -r requirements.txt
    

Usage

$ python3 blur_faces.py --help
Usage: blur_faces.py [OPTIONS] IN_VIDEO_FILE

Options:
  --mode [all|one|allexcept]
  --model [hog|cnn]
  --censor-type [gaussianblur|facemasking|pixelation]
  --count INTEGER                 How many times to upsample the image looking
                                  for faces. Higher numbers find smaller
                                  faces.

  --in-face-file TEXT
  --help                          Show this message and exit.

Example

python3 blur_faces.py media/friends.mp4 --mode allexcept --model cnn --censor-type facemasking --in-face-file media/Ross_Geller.jpg

Additional Information

  • originally developed for Bellingcat Oct 2022 Hackathon
  • uses face_recognition for face detection
  • uses ffmpeg for audio and video processing
  • tool is not perfect; should be used with other manual editing before final publish
  • next steps
    • smooth face_locations (fixes failure in detecting odd frames)
    • detect scene change and use it to reset face_locations[]
    • choose num_jitters

blurfaces's People

Contributors

raviksharma avatar dependabot[bot] 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.