Skip to content

Install

Morphace is a Python package that provides the morphace command-line tool for preparing images and creating face-morphing videos.

The morphace command provides three subcommands:

CommandPurpose
morphace downloadDownloads Morphace’s required model file.
morphace prepPrepares aligned square PNG face crops from raw images.
morphace morphGenerates an MP4 face-morphing video from two source images.

To install and run Morphace, your system needs:

  • Python 3.12 or newer.
  • FFmpeg installed and available on PATH.

The required Python dependencies are declared by the package and are installed automatically.

Morphace also requires the dlib shape_predictor_68_face_landmarks_GTX.dat landmark model when running the morph and prep commands. You do not need to download this model before installing Morphace. The recommended setup is to install Morphace first, then run morphace download.

Install the Morphace package with pip:

Terminal window
pip install morphace

After installing Morphace, download the required landmark model using the morphace download command:

Terminal window
morphace download

This saves the model to Morphace’s Default Model Directory.

For most users, this is all the model setup you need.

After installing Morphace and downloading the landmark model, use the morphace morph command to create a face morph:

Terminal window
morphace morph \
first_image.png \
second_image.png

Morphace creates a new video file in the current directory called morph.mp4.