Make videos shot in dark places clear and bright with a few lines of code in machine learning

MLBoy
3 min readJan 9, 2022

This is a way to brighten a video shot in a dark place.

It’s easy to run using a machine learning model.

We want to get information from a dark and unclear video

Not only personal smartphones, but also dark and unclear videos such as in-vehicle cameras and surveillance cameras at night, there are times when we want to get information from them.

The lightweight brightness-enhanced model Stable LLVE is amazing

The model announced in 2021 called StableLLVE is lightweight, fast, and brightens beautifully.

original and enhanced

Now you can process the video and you’ll get a clear video.

How to use for video

Let’s run it on an iPhone using the CoreML model.

Download the model from CoreML-Models .

Initialize.

Apply the model to the video with Semantic Image.

It can be processed in about 2 to 3 times the playback time of the video.

Since the processing is fast, you can also brighten it in real time by giving the model a smartphone camera feed.
This time we tried it on a smartphone, but of course you can also run the original model with Python and OpenCV.

Don’t miss the decisive moment

You can use it on your smartphone by using a mobile model, and since the model itself is lightweight, you can use it in various situations.
It would be nice to be able to get the moment you need without being disturbed by the darkness.

🐣

I’m a freelance engineer.
Work consultation
Please feel free to contact us with a brief development description.
rockyshikoku@gmail.com

I am making an app that uses Core ML and ARKit.
We send machine learning / AR related information.

GitHub

Twitter
Medium

--

--