https://github.com/qengineering/ncnn-colorization_raspberry-pi-4
Colorization with ncnn on a bare Raspberry Pi
https://github.com/qengineering/ncnn-colorization_raspberry-pi-4
aarch64 colorization deep-learning ncnn ncnn-framework ncnn-model raspberry-pi-4 raspberry-pi-64-os siggraph
Last synced: 12 months ago
JSON representation
Colorization with ncnn on a bare Raspberry Pi
- Host: GitHub
- URL: https://github.com/qengineering/ncnn-colorization_raspberry-pi-4
- Owner: Qengineering
- License: bsd-3-clause
- Created: 2022-12-10T11:30:20.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-11-08T09:23:44.000Z (over 1 year ago)
- Last Synced: 2025-03-27T09:22:59.542Z (about 1 year ago)
- Topics: aarch64, colorization, deep-learning, ncnn, ncnn-framework, ncnn-model, raspberry-pi-4, raspberry-pi-64-os, siggraph
- Language: C++
- Homepage: https://qengineering.eu/deep-learning-examples-on-raspberry-32-64-os.html
- Size: 2.08 MB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Colorization on a Raspberry Pi

## Colorization with the ncnn framework.
[](https://opensource.org/licenses/BSD-3-Clause)
Paper: https://arxiv.org/pdf/1603.08511.pdf
Special made for a bare Raspberry Pi 4, see [Q-engineering deep learning examples](https://qengineering.eu/deep-learning-examples-on-raspberry-32-64-os.html)
------------
## Dependencies.
To run the application, you have to:
- A raspberry Pi 4 with a 32 or 64-bit operating system. It can be the Raspberry 64-bit OS, or Ubuntu 18.04 / 20.04. [Install 64-bit OS](https://qengineering.eu/install-raspberry-64-os.html)
- The Tencent ncnn framework installed. [Install ncnn](https://qengineering.eu/install-ncnn-on-raspberry-pi-4.html)
- OpenCV 64 bit installed. [Install OpenCV 4.5](https://qengineering.eu/install-opencv-4.5-on-raspberry-64-os.html)
- Code::Blocks installed. (```$ sudo apt-get install codeblocks```)
------------
## Installing the app.
To extract and run the network in Code::Blocks
$ mkdir *MyDir*
$ cd *MyDir*
$ wget https://github.com/Qengineering/ncnn-Colorization_Raspberry-Pi-4/archive/refs/heads/main.zip
$ unzip -j master.zip
Remove master.zip, LICENSE and README.md as they are no longer needed.
$ rm master.zip
$ rm LICENSE
$ rm README.md
Your *MyDir* folder must now look like this:
15.jpg
17.jpg
Julia.jpg
Colorization.cpb
main.cpp
Sig17Slice.h
siggraph17_color_sim.param
------------
## Download the model weights
Before you can run the app, you have to download the model weights. The file is too large (125 MB) to be stored on GitHub (limited to 100 MB). Download location of `siggraph17_color_sim.bin` at [GDrive](https://drive.google.com/file/d/1wdlu9IpbIPeeWdkOouGcwUttKtjK9fW8/view?usp=sharing).
------------
## Running the app.
To run the application load the project file Colorization.cbp in Code::Blocks.
The app takes the b/w input file and the output file name as command line arguments.
You may find the hint at [Hands-On](https://qengineering.eu/deep-learning-examples-on-raspberry-32-64-os.html#HandsOn) handy.
Do note the application takes about 10 Sec to process a single picture.
------------
### Thanks.
A more than special thanks to [***magicse***](https://github.com/magicse), who adapted the ncnn framework for this colorization app.
------------
### More info.
Colorful Image Colorization [magicse](https://github.com/magicse/ncnn-colorization-siggraph17)
Colorful Image Colorization [richzhang/colorization](https://github.com/richzhang/colorization)
Colorful Image Colorization [Project Page](http://richzhang.github.io/colorization/) by Richard Zhang, Phillip Isola, Alexei A. Efros.
------------

[](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=CPZTM5BB3FCYL)