Coder Social home page Coder Social logo

facemorph's Introduction

FaceMorph

Simple image morphing operation using OpenCV; copied, and pasted into one unified script for ease of operations

Installation

Clone the repository to your local machine:

git clone https://github.com/razyoboy/FaceMorph.git

Install the required Python packages:

pip install -r requirements.txt

Usage

To use FaceMorph, you'll need to navigate to the src directory within the project folder. Use the following command to change to the correct directory:

cd src

[!NOTE]
The project was developed using PyCharm, which has specific path configurations. It is essential to run the script from the src directory to avoid path-related issues.

Modes of Operation

The main.py script can operate in two modes: batch and non-batch. Here's how you can configure each mode:

Non-Batch Mode

In non-batch mode, you will specify two individual images to morph together. To use this mode, set the BATCH_MORPH variable to False and update the filename1 and filename2 variables with the paths to your chosen images.

BATCH_MORPH = False
filename1 = "path/to/your/image1.jpg"
filename2 = "path/to/your/image2.jpg"

Batch Mode

In batch mode, the script will morph together every possible pair of images in a specified folder, utilizing the combination formula to ensure each image has a unique set of outcomes. To use this mode, set the BATCH_MORPH variable to True and update the folder_path variable with the path to your folder containing the images.

BATCH_MORPH = True
folder_path = 'path/to/your/folder'

Then you can run the script using:

python main.py

facemorph's People

Contributors

razyoboy avatar

Watchers

 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.