OpenViSTAI · Agents · Blockchain · Crypto
Menu
Image & Video AI

Magictailor

MagicTailor is a Python research implementation for training text-to-image diffusion models to personalize a visual concept while controlling a selected component, such as changing a person's hair.

Independent OpenViST project profile, based on linked sources.

Magictailor — OpenViST project profile in Image & Video AI.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use MagicTailor when you want to work with a local research workflow for personalized text-to-image generation that distinguishes a concept from a component to be reconfigured.

Who it is for

  • Researchers studying personalization and controllability in text-to-image diffusion models.
  • Developers who want to experiment with component-specific personalization using reference images.

Documented uses

  • Train a personalized concept from reference images while separately specifying a component.
  • Generate images using learned concept and component placeholder tokens.
  • Modify a research implementation for further experimentation.
Before you choose

Requirements & limits

The public GitHub repository is licensed under Apache-2.0. Its documented workflow is run locally from the repository.

  • The full setup includes Grounded-SAM; the README says it can be omitted for a quick try with supplied examples.
  • The documented example installation uses PyTorch 1.13.1 and torchvision 0.14.1 with CUDA 11.6.
  • Training uses generated masks, and the README recommends checking their quality.
  • The project warns that GPU memory limits may require reducing reference images or moving the momentum denoising U-Net to another GPU where applicable.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Train and generate with a concept–component pair

Prepare reference images, train a MagicTailor model, and use its concept and component tokens in an image-generation prompt.

Before you start

  • MagicTailor repository and its Conda environment.
  • PyTorch 1.13.1 and torchvision 0.14.1 with CUDA 11.6 are provided as an installation example.
  • Grounded-SAM installation for the full setup; it may be skipped for a quick try with the supplied example images.
  • Reference images for a concept and a component, or the repository's example images.

Steps

  1. Create a folder named in the {CONCEPT}_{ID}+{COMPONENT}_{ID} pattern and place the reference images inside, naming concept files 0_{CONCEPT}_{ID}.jpg and component files 1_{COMPONENT}_{ID}.jpg.

  2. Install the Conda environment from environment.yml; install the indicated PyTorch and torchvision packages, then set up Grounded-SAM if using the full workflow.

  3. Run the command below and check the quality of the Grounded-SAM masks.

    Documented command
    python train.py --instance_data_dir {PATH-TO-PREPARED-DATA}
  4. Use the saved model in outputs/magictailor with the command below.

    Documented command
    python inference.py --model_path "outputs/magictailor" --prompt " with " --output_path "outputs/inference/result.jpg"

Expected outcome

A trained model saved under `outputs/magictailor` and an inference image written to the specified output path.

Guide limitations

  • The README warns that GPU memory limits may require fewer reference images or moving the momentum denoising U-Net to another GPU where applicable.
  • Hyperparameter adjustments may be needed to balance text alignment and identity fidelity.
  • The README asks users to inspect Grounded-SAM masks; this recipe does not establish that any particular run will succeed.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
12 October 2026
Original website title
Correr-Zhou/MagicTailor · Official homepage title · retained in its source language