Readme
Resolutions (use lower resolution if you get a lot of mutations and stuff like that)
Face Portrait: 896x896 Portrait: 896x896, 768x1024 Half Body: 768x1024, 640x1152 Full Body: 896x896, 768x1024, 640x1152, 1024x768, 1152x640
pip install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run skytells-research/realvisxl-v2 using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"skytells-research/realvisxl-v2:4b02f0bf9f0163e012847d0abbf6ae7bec51389a568df558fb874db62dd300b2",
input={
"width": 1024,
"height": 1024,
"prompt": "A photo of TOK",
"refine": "no_refiner",
"scheduler": "DPMSolverMultistep",
"lora_scale": 0.6,
"num_outputs": 1,
"guidance_scale": 7.5,
"apply_watermark": True,
"high_noise_frac": 0.8,
"negative_prompt": "(worst quality, low quality, illustration, 3d, 2d, painting, cartoons, sketch), tooth, open mouth,bad hand, bad fingers, lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, normal quality, jpeg artifacts, signature, watermark, username, blurry, long neck, out of frame, extra fingers, mutated hands, monochrome, ((poorly drawn hands)), ((poorly drawn face)), (((mutation))), (((deformed))), ((ugly)), blurry, ((bad anatomy)), (((bad proportions))), ((extra limbs)), cloned face, glitchy, bokeh, (((long neck))), ((flat chested)), ((((visible hand)))), ((((ugly)))), (((duplicate))), ((morbid)), ((mutilated)), [out of frame], extra fingers, mutated hands, ((poorly drawn hands)), ((poorly drawn face)), (((mutation))), (((deformed))), ((ugly)), blurry, ((bad anatomy)), (((bad proportions))), ((extra limbs)), cloned face, (((disfigured))), out of frame, ugly, extra limbs, (bad anatomy), gross proportions, (malformed limbs), ((missing arms)), ((missing legs)), (((extra arms))), (((extra legs))), mutated hands, (fused fingers), (too many fingers), (((long neck))) red eyes, multiple subjects, extra heads",
"prompt_strength": 0.8,
"num_inference_steps": 50
}
)
# To access the file URL:
print(output[0].url())
#=> "http://example.com"
# To write the file to disk:
with open("my-image.png", "wb") as file:
file.write(output[0].read())
To learn more, take a look at the guide on getting started with Python.
No output yet! Press "Submit" to start a prediction.
This model runs on Nvidia A100 (80GB) GPU hardware. We don't yet have enough runs of this model to provide performance information.
Resolutions (use lower resolution if you get a lot of mutations and stuff like that)
Face Portrait: 896x896 Portrait: 896x896, 768x1024 Half Body: 768x1024, 640x1152 Full Body: 896x896, 768x1024, 640x1152, 1024x768, 1152x640