Giter VIP home page Giter VIP logo

face-morphing's Introduction

Face-Morphing

Introduction

Here we are trying to apply morphing on two images, in particular, we want to map the changes from the source image to the destination image. On applying this we can see how pixel values are converting from source image to destination image. To get better results triangulation is used to do the region-wise mapping.

API and Language used

  1. Python 3.7
  2. Open-CV
  3. Numpy

How to install and Run

  1. Open terminal (CTRL+ALT+T)
  2. Install Python by the command “sudo apt-get install python”
  3. Run the command“python -m pip install requirements.txt”
  4. Change the path in the code for your input images.
  5. Run the command on the terminal - “python file_name.py”

What to do after running

  1. You will be prompt with image1
  2. Use mouse to mark 3 control points and press ‘q’
  3. You will be prompt with image2
  4. Use mouse to mark 3 control points and press ‘q’
  5. Now you can see 2 triangulated images
  6. Press q
  7. Now You can see intermediate triangles getting morphed
  8. The final Image along with two triangulated image will be shown as output.
  9. Images will be saved automatically in the working directory.

Program in Action(Video Demonstration!)

Check the following video to see what the program does! Watch the video here

Input Images

Source Image

Source Image

Destination Image

Destination Image

Triangulated Images

Source Triangulated Image

Triangulated Image Source

Destination Triangulated Image

Triangulated Image Destination

Result

Final Morphed Image

Morphed Image

face-morphing's People

Contributors

guptag911 avatar

Watchers

 avatar  avatar

Forkers

baselrafaat

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.