If you're looking for an API, you can choose from your desired programming language.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import requests
api_key = "YOUR_API_KEY"
url = "https://api.segmind.com/v1/consistent-character"
# Prepare data and files
data = {}
files = {}
data['seed'] = 42
data['prompt'] = "a photo of a man at a beach, wearing hawaiian shirt, looking directly at the camera"
# For parameter "subject", you can send a raw file or a URI:
# files['subject'] = open('IMAGE_PATH', 'rb') # To send a file
# data['subject'] = 'IMAGE_URI' # To send a URI
data['output_format'] = "webp"
data['output_quality'] = 80
data['negative_prompt'] = "low quality,blur"
data['randomise_poses'] = True
data['number_of_outputs'] = 1
data['number_of_images_per_pose'] = 1
headers = {'x-api-key': api_key}
# If no files, send as JSON
if files:
response = requests.post(url, data=data, files=files, headers=headers)
else:
response = requests.post(url, json=data, headers=headers)
print(response.content) # The response is the generated image
Set a seed for reproducibility. Random by default.
Describe the subject. Include clothes and hairstyle for more consistency.
An image of a person. Best images are square close ups of a face, but they do not have to be.
An enumeration.
Allowed values:
Quality of the output images, from 0 to 100. 100 is best quality, 0 is lowest quality.
min : 0,
max : 100
Things you do not want to see in your image
Randomise the poses used.
The number of images to generate.
min : 1,
max : 20
The number of images to generate for each pose.
min : 1,
max : 4
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Consistent Character lets you generate new images of a specific person with remarkable consistency. It takes just one reference image and a text description of the desired pose variations. The magic lies in its ability to seamlessly transfer the person's unique characteristics onto a new body in a different pose. Unlike Insta Depth Model, this one doesn't rely on pre-defined poses. Instead, it cleverly generates a variety of poses on the fly, ensuring the character's identity remains constant while introducing exciting pose diversity. Under the hood of Consistent Character model is a combination of IP Adapter Face and instant id for image generation followed by upscaling.
SDXL Img2Img is used for text-guided image-to-image translation. This model uses the weights from Stable Diffusion to generate new images from an input image using StableDiffusionImg2ImgPipeline from diffusers
Best-in-class clothing virtual try on in the wild
This model is capable of generating photo-realistic images given any text input, with the extra capability of inpainting the pictures by using a mask
The most versatile photorealistic model that blends various models to achieve the amazing realistic images.