AnyText2

repository·main·Indexed 42 days ago

https://github.com/tyxsspa/anytext2

A visual text generation and editing framework for precise control over multilingual text attributes, such as font and color, in natural scene images. It utilizes a WriteNet+AttnX architecture to integrate text rendering capabilities into pre-trained Text-to-Image models.

Tokens
603
Snippets
3
Records
4
Agent score
3%

What's inside AnyText2

  1. Install AnyText2

    main

    To install AnyText2, you need to download the model checkpoints via ModelScope, clone the repository, and set up a Conda environment.

    1. Download Checkpoints: Use modelscope to download the iic/cv_anytext2 model.
    2. Setup Repository: Clone the AnyText2 repository and move the downloaded checkpoints into a models directory within the project root.
    3. Environment Setup: Create a new Conda environment using the provided environment.yaml file.
    # 1. Download checkpoint (requires pip install modelscope first)
    python -c "from modelscope import snapshot_download; print(snapshot_download('iic/cv_anytext2'))"
    
    # 2. Clone anytext code and move checkpoint
    git clone https://github.com/tyxsspa/AnyText2.git
    cd AnyText2 && mkdir -p models && mv /path/to/your_downloaded_dir/* models
    
    # 3. Create a new environment and install packages
    conda env create -f environment.yaml
    conda activate anytext2