How you can Blur Faces in a Video from Command Line


Privateness is at all times extremely necessary, particularly with visible media the place you might not have the permission of people within the video. If you happen to’re filming one thing in public, it is probably you may catch somebody’s face who merely would not need or must be recognized. This lately acquired me to pondering: what is the best solution to blur faces in a video by way of command line?

The most effective open supply utility I discovered for blurring faces in a video was deface. Let’s take a look at how you should use deface to blur faces in movies!

Begin by downloading Python-based by way of pip:

python3 -m pip set up deface

With deface put in, merely present the video title and get the output file with blurred faces:

sudo deface ./sample-4k-faces-video.mp4
Enter:  ./sample-4k-faces-video.mp4
Output: ./sample-4k-faces-video_anonymized.mp4
100%|█████████████████████████████

The ensuing video does a formidable job of blurring out faces of individuals strolling by within the unique recording:

View the ensuing video of individuals strolling down the streets of New York:

The default threshold for face recognition works very effectively, even on transferring topics. You’ll be able to experiment with thresholds with the thresh argument, and even draw the thresholds out whereas debugging:

I downloaded a handful of YouTube movies utilizing my favourite YouTube downloading utility youtube-dl and I used to be amazed at how effectively deface did on quite a lot of visible environments. Faces had been recognized at a dependable stage even at default threshold!

  • Serving Fonts from CDN

    For optimum efficiency, everyone knows we should put our belongings on CDN (one other area).  Together with these belongings are customized internet fonts.  Sadly customized internet fonts by way of CDN (or any cross-domain font request) do not work in Firefox or Web Explorer (accurately so, by spec) although…

  • Regular Expressions for the Rest of Us

    In the end you may run throughout an everyday expression. With their cryptic syntax, complicated documentation and large studying curve, most builders accept copying and pasting them from StackOverflow and hoping they work. However what when you may decode common expressions and harness their energy? In…

  • MooTools Flashlight Effect
  • :valid, :invalid, and :required CSS Pseudo Classes

    Let’s be trustworthy, kind validation with JavaScript is usually a actual bitch.  On an actual primary stage, nevertheless, it is not that unhealthy.  HTML5 has jumped in to some extent, offering just a few attributes to permit us to mark fields as required or solely legitimate if matching…


Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles