Face Swapping Mastery with Midjourney: Unleashing Creative Potential

The ongoing advancement of the metaverse and artificial intelligence has led to an increasingly indistinct line between the real and virtual worlds.

This article will explain how to create realistic face-swapping effects using Midjourney and a third-party plugin called InsightFace, focusing on the technology and methods behind them.

Introduction to InsightFace

InsightFace is a 2D and 3D deep face recognition framework that’s open source. Developed by researchers at the Chinese Academy of Sciences, it utilizes AI to measure and sketch images of faces. By using only photos, it matches identities based on unique facial characteristics. This technology powers many face recognition products and services.

Among these is Midjourney, which permits users to replace faces in images with great precision, yielding highly realistic results.

There’s no need for Photoshop or uploading numerous photos to Midjourney; you can easily create the face-swap effect in just a few steps with this combination.

How to Do A Face Swap

Create a Discord and Midjourney Account

Midjourney is an intelligent image generation tool, operating on the Discord chat platform. Joining Midjourney’s community on Discord lets you view others’ creations as they happen. Paid subscribers have the option to create a private server, allowing for uninhibited creation without the concern of being observed.

Create A Private Server

1/ Click on the plus button in the left column.

create a private server for midjourney

2/ Choose “Create My Own” from the popup menu to initiate your server.

create server menu midjourney

3/ Generally, opt to create a server for yourself and friends.

select server type midjourney

4/ Name the server.

name your server midjourney

Add Midjourney and InsightFace Bots to Your Private Server

1/ Locate the Midjourney bot in Discord’s left sidebar, and click it.

locate midjourney bot in discord

2/ Click the Midjourney bot’s name within the chat window.

click midjourney bot in the message window

3/ Select “Add to Server” in the popup.

add midjourney bot to server

4/ Pick the private server you just crafted from the “ADD TO SERVER” dropdown and press “Continue.”

add midjourney bot to my server

5/ In the following window, click “Authorize” to give access to the Midjourney bot on your server.

authorize midjourney bot for private server

6/ Following that, open InsightFace’s authorization link in your browser.

add insightface to midjourney private server

7/ Complete the authorization similarly to the Midjourney bot above.

Register the Face – “/saveid”

Upon adding Midjourney and InsightFace bots to your server, you can upload an image to register a face’s identity. This registration translates into an ID used for face swapping and editing.

Note that for better results, please upload a high-resolution photo of your face without glasses or heavy bangs.

1/ Enter “saveid” and press enter, revealing a dotted box for image uploading.

image upload area of insightface

2/ Assign the image a name, consisting of letters and numbers, within 10 characters.

upload image to insightface midjourney private server

3/ (Optional) Use “listid” to view all the IDs.

Uploading or Creating a Portrait

With the IDs established, upload or generate a photo for face application. I initially used Midjourney’s “imagine” command to generate Captain Jack’s portrait.

four images of captain jack sparrow generated by midjourney

Then I selected “U1” to upscale the first one as I preferred it.

upscale image of captain jack sparrow generated by midjourney

Face swap

Now, the exciting part. Right-click the Captain Jack image and choose Apps -> INSwapper.

midjourney with insightface result 1

Let’s have another picture—Claude’s version (Final Fantasy) of Mask:

midjourney with insightface result 2

Other commands for face swapping

Apart from using Midjourney’s generated image, you can upload a native one with the command “/swapid.”

swap id command of insightface

Follow by filling the ID and uploading the picture.

swap id command of insightface with uploaded image

Soon, the local image will be face-swapped.

midjourney with insightface result

Additional commands include:

  • /setid: Assigns a face ID to InsightFace.
  • /listid: Lists registered identity names.
  • /delid: Removes a specific identity name.
  • /delall: Deletes all registered names.

Some limitations and Issues

While InsightFace and Midjourney offer vast creative possibilities, there are limitations:

  • A large difference in facial features may hinder face swapping.
  • The new version supports ID photos with glasses; clarity ensures better results.
  • Free users are limited to 50 commands per day; paid users have more access and other benefits.

Caution must also be exercised, as face-swapping technology bears potential risks:

  • Privacy: Unauthorized face usage may breach privacy rights.
  • Deception: The technology may be employed to fabricate misleading content.
  • Copyright: Unauthorized use of faces may infringe on legal and copyright rights.

Thus, when using this technology, it is imperative to adhere to ethical guidelines. Utilize it for research or legitimate creativity, and refrain from illegal or unethical practices.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *