prunaai/p-image-edit-trainer
Fast LoRA trainer for p-image-edit, a super fast text-to-image model developed by Pruna AI. Use LoRAs here: https://replicate.com/prunaai/p-image-edit-lora. Find or contribute LoRAs here: https://huggingface.co/collections/PrunaAI/p-image-edit
Run prunaai/p-image-edit-trainer with an API
Use one of our client libraries to get started quickly. Clicking on a library will take you to the Playground tab where you can tweak different inputs, see the results, and copy the corresponding code to use in your own project.
Input schema
The fields you can use to run this model with an API. If you don't give a value for a field its default value will be used.
| Field | Type | Default value | Description |
|---|---|---|---|
| image_data |
string
|
Zip archive with pairs of images for edit training. Images should be named ROOT_start.EXT and ROOT_end.EXT (e.g., photo_start.jpg and photo_end.jpg). Can include multiple reference images: ROOT_start.EXT, ROOT_start2.EXT, ROOT_start3.EXT, ..., ROOT_end.EXT. Can also contain text files (ROOT.txt) to specify edit instructions for each image pair. You can also pass a URL pointing to the zip file instead of uploading a file directly.
|
|
| steps |
integer
|
1000
Min: 100 Max: 5000 |
Number of steps to train for
|
| learning_rate |
number
|
0.0001
Min: 0.00001 Max: 0.01 |
Learning rate for LoRA parameters
|
| default_caption |
string
|
Default caption to use when caption files are missing. If not provided and captions are missing, training will fail.
|
{
"type": "object",
"title": "Input",
"required": [
"image_data"
],
"properties": {
"steps": {
"type": "integer",
"title": "Steps",
"default": 1000,
"maximum": 5000,
"minimum": 100,
"x-order": 1,
"description": "Number of steps to train for"
},
"image_data": {
"type": "string",
"title": "Image Data",
"format": "uri",
"x-order": 0,
"description": "Zip archive with pairs of images for edit training. Images should be named ROOT_start.EXT and ROOT_end.EXT (e.g., photo_start.jpg and photo_end.jpg). Can include multiple reference images: ROOT_start.EXT, ROOT_start2.EXT, ROOT_start3.EXT, ..., ROOT_end.EXT. Can also contain text files (ROOT.txt) to specify edit instructions for each image pair. You can also pass a URL pointing to the zip file instead of uploading a file directly."
},
"learning_rate": {
"type": "number",
"title": "Learning Rate",
"default": 0.0001,
"maximum": 0.01,
"minimum": 1e-05,
"x-order": 2,
"description": "Learning rate for LoRA parameters"
},
"default_caption": {
"type": "string",
"title": "Default Caption",
"x-order": 3,
"nullable": true,
"description": "Default caption to use when caption files are missing. If not provided and captions are missing, training will fail."
}
}
}
Output schema
The shape of the response you’ll get when you run this model with an API.
{
"type": "string",
"title": "Output",
"format": "uri"
}