BoxToolBox is a simple python application built around the openCV library

Overview

BoxToolBox

BoxToolBox is a simple python application built around the openCV library. It is not a full featured application to guide you through the whole process. It is a missing piece in your toolchain between Lightroom and Photoshop. You still need to take you box pictures as straight as possible with the same camera settings and pre-process them to match the lighting.

It will help you to

  • correct perspective of the source photos
  • quickly test the layout and arrangement
  • place photos to correct location
  • generate grid to recolor or use as mask to hide the seams

It will not

  • unify brightness and colors of source photos
  • magically correct photos taken from bad perspective
  • assemble final picture

How to install (Linux)

Just clone or download this repository and run the main script. You will also need opencv installed.

pip install opencv-python
git clone https://github.com/fhorinek/BoxToolBox.git
cd BoxToolBox
python BoxToolBox.py

How to install (Windows)

Just download and execute pre-built exe file

It will trigger Windows protection, you need to click on more info and run anyway

How to use it

Here is a quick start video on youtube

BoxToolBox quick tutorial

Perspective editor

One window acts as input for defining box corners and the second window shows transformation previu. Controls on the second window sets transformed image width and height. The resolution for the final picture will be Width * Grid W x Height * Grid H. Margin define how much of the image will be preserved around the defined box. Preview scale will define size of the temporary pictures used in layout editor. Smaller scale will make the editor go faster, larger scale will provide better quality.

norm

Controls:

  • Mouse wheel - zoom
  • Left button - Pan
  • Middle button - Select point
  • N key and M key - Open previous and next image
  • Q - Close editor

Normally you only need to define a transformation box for the first photo. The transformation will be applied to all following pictures. If you bump the camera during the session you can find the first image that is affected and redefine the transformation box. All following images will use that correction.

Layout editor

You can use this window to compose the final image. Here you can change geometry for the final image. Set scaling and spacing for the images. You can use Transparent spacer to define a very precise scale.

layout

If the settings window is not visible press Ctrl-P.

Controls:

  • Mouse wheel - zoom
  • Left button - Pan
  • Drag picture - Swap images
  • N key and M key - set previous and next image
  • E key - Open perspective editor for image
  • C key - Toggle Crop or Full flag for image
  • S key - Show full image with marker lines
  • Q key - Close editor
  • Render - Show final image in full resolution
  • Output - Render final image in layers

Use different slots to experiment with multiple layouts and geometries.

Output

Output for the image will consist of multiple images placed inside the directory slot_n. Photos in images will be placed to correct location on transparent background. You will also find the generated grid image. Import these images as layers to any photo editor to compose the final image.

gimp

Disclaimer

This tool is my hobby project, done in my free time for my personal use. However I think that other people might find it useful so I made extra steps to make it more friendly and easier to install. If you found a bug or want something to add, feel free to open an issue. Pull requests are also welcomed!

If you found it useful and want to thank me, you can buy me a bear :-)

Owner
František Horínek
František Horínek
Program created with opencv that allows you to automatically count your repetitions on several fitness exercises.

Virtual partner of gym Description Program created with opencv that allows you to automatically count your repetitions on several fitness exercises li

1 Jan 04, 2022
Deskewing images with slanted content

skew_correction De-skewing images with slanted content by finding the deviation using Canny Edge Detection. To Run: In python 3.6, from deskew import

13 Aug 27, 2022
Optical character recognition for Japanese text, with the main focus being Japanese manga

Manga OCR Optical character recognition for Japanese text, with the main focus being Japanese manga. It uses a custom end-to-end model built with Tran

Maciej Budyś 327 Jan 01, 2023
Textboxes_plusplus implementation with Tensorflow (python)

TextBoxes++-TensorFlow TextBoxes++ re-implementation using tensorflow. This project is greatly inspired by slim project And many functions are modifie

81 Dec 07, 2022
Histogram specification using openCV in python .

histogram specification using openCV in python . Have to input miu and sigma to draw gausssian distribution which will be used to map the input image . Example input can be miu = 128 sigma = 30

Tamzid hasan 6 Nov 17, 2021
A tool to make dumpy among us GIFS

Among Us Dumpy Gif Maker Made by ThatOneCalculator & Pixer415 With help from Telk, karl-police, and auguwu! Please credit this repository when you use

Kainoa Kanter 535 Jan 07, 2023
The official code for the ICCV-2021 paper "Speech Drives Templates: Co-Speech Gesture Synthesis with Learned Templates".

SpeechDrivesTemplates The official repo for the ICCV-2021 paper "Speech Drives Templates: Co-Speech Gesture Synthesis with Learned Templates". [arxiv

Qian Shenhan 53 Dec 23, 2022
OpenCVを用いたカメラキャリブレーションのサンプルです。2021/06/21時点でPython実装のある3種類(通常カメラ向け、魚眼レンズ向け(fisheyeモジュール)、全方位カメラ向け(omnidirモジュール))について用意しています。

OpenCV-CameraCalibration-Example FishEyeCameraCalibration.mp4 OpenCVを用いたカメラキャリブレーションのサンプルです 2021/06/21時点でPython実装のある以下3種類について用意しています。 通常カメラ向け 魚眼レンズ向け(

KazuhitoTakahashi 34 Nov 17, 2022
MXNet OCR implementation. Including text recognition and detection.

insightocr Text Recognition Accuracy on Chinese dataset by caffe-ocr Network LSTM 4x1 Pooling Gray Test Acc SimpleNet N Y Y 99.37% SE-ResNet34 N Y Y 9

Deep Insight 99 Nov 01, 2022
~1000 book pages + OpenCV + python = page regions identified as paragraphs, lines, images, captions, etc.

cosc428-structor I had an open-ended Computer Vision assignment to complete, and an out-of-copyright book that I wanted to turn into an ebook. Convent

Chad Oliver 45 Dec 06, 2022
A Screen Translator/OCR Translator made by using Python and Tesseract, the user interface are made using Tkinter. All code written in python.

About An OCR translator tool. Made by me by utilizing Tesseract, compiled to .exe using pyinstaller. I made this program to learn more about python. I

Fauzan F A 41 Dec 30, 2022
Slice a single image into multiple pieces and create a dataset from them

OpenCV Image to Dataset Converter Slice a single image of Persian digits into mu

Meysam Parvizi 14 Dec 29, 2022
Recognizing the text contents from a scanned visiting card

Recognizing the text contents from a scanned visiting card. The application which is used to recognize the text from scanned images,printeddocuments,r

Faizan Habib 1 Jan 28, 2022
Omdena-abuja-anpd - Automatic Number Plate Detection for the security of lives and properties using Computer Vision.

Omdena-abuja-anpd - Automatic Number Plate Detection for the security of lives and properties using Computer Vision.

Abdulazeez Jimoh 1 Jan 01, 2022
A synthetic data generator for text recognition

TextRecognitionDataGenerator A synthetic data generator for text recognition What is it for? Generating text image samples to train an OCR software. N

Edouard Belval 2.5k Jan 04, 2023
Source code of our TPAMI'21 paper Dual Encoding for Video Retrieval by Text and CVPR'19 paper Dual Encoding for Zero-Example Video Retrieval.

Dual Encoding for Video Retrieval by Text Source code of our TPAMI'21 paper Dual Encoding for Video Retrieval by Text and CVPR'19 paper Dual Encoding

81 Dec 01, 2022
The world's simplest facial recognition api for Python and the command line

Face Recognition You can also read a translated version of this file in Chinese 简体中文版 or in Korean 한국어 or in Japanese 日本語. Recognize and manipulate fa

Adam Geitgey 47k Jan 07, 2023
Text page dewarping using a "cubic sheet" model

page_dewarp Page dewarping and thresholding using a "cubic sheet" model - see full writeup at https://mzucker.github.io/2016/08/15/page-dewarping.html

Matt Zucker 1.2k Dec 29, 2022
Learning Camera Localization via Dense Scene Matching, CVPR2021

This repository contains code of our CVPR 2021 paper - "Learning Camera Localization via Dense Scene Matching" by Shitao Tang, Chengzhou Tang, Rui Hua

tangshitao 65 Dec 01, 2022
Controlling Volume by Hand Gestures

This program allows the user to control the volume of their device with specific hand gestures involving their thumb and index finger!

Riddhi Bajaj 1 Nov 11, 2021