Igarashi Rika/五十嵐梨花 | Wan2.1 & 2.2 14B T2V
세부 정보
파일 다운로드
이 버전에 대해
모델 설명
Wan2.1:
이 LoRA는 Nijisanji의 캐릭터 이가라시 리카(五十嵐梨花)를 묘사합니다.
트리거 단어: Igarashi Rika, 애니메이션 스타일 소녀. 이미지는 긴 연한 주황색 머리카락을 높은 단발로 묶고 흰색 리본과 노란 별 모양의 머리 장식을 단 애니메이션 스타일 캐릭터를 특징으로 합니다. 캐릭터는 반짝이는 듯한 큰 표현력 있는 파란 눈을 가지고 있습니다. 검은 색 초커에 작은 펜던트, 얇은 끈이 달린 녹색 상의, 고양이 모양 버클이 있는 노란 벨트를 착용하고 있습니다. 옷에는 흰색 칼라와 흰색 후드가 달린 검은 자켓이 포함됩니다. 캐릭터는 검은 줄무늬가 있는 무릎 높이 양말과 별 모양 장식이 있는 흰색 신발을 신고 있습니다.
학습 데이터: musubi-tuner, 30장 이미지
캡션: Qwen2.5-VL-3B에서 조정된 캡션(설명된 배경 포함)
lr: (2e-4, flow_shift3.0)
epoch: 200
train_step: 6000
lora_strength: 0.8
샘플 프롬프트: Igarashi Rika, anime-style girl. The image features an anime-style character with long, light orange hair styled in a high bun adorned with a white bow and a yellow star-shaped hair accessory. The character has large, expressive blue eyes with a hint of sparkle. She is wearing a black choker with a small pendant, a green top with thin straps, and a yellow belt with a cat-shaped buckle. Her outfit includes a white collar and a black jacket with a white hood. The character also wears knee-high socks with black stripes and white shoes with star-shaped decorations. (she is dancing:2.5), (chibi Nendoroid:3.5) in bedroom.
액션 프롬프트는 강조 프롬프트에 따라 2.0~4.0로 조정해야 합니다. 또는 모션 LoRA를 함께 사용하세요.
Action prompt should be adjusted to 2.0 to 4.0 depending on emphasis prompt. Or motion lora use together.
Wan2.2ver2:
트리거 단어: Igarashi Rika, 애니메이션 스타일 소녀. 이미지는 긴 연한 분홍색 머리카락을 높은 꼬리로 묶고 별 모양 머리 장식을 단 애니메이션 스타일 캐릭터를 특징으로 합니다. 캐릭터는 파란 눈을 가지고 있으며, 작은 펜던트가 달린 검은 색 초커를 착용하고 있습니다. 짧은 스커트와 후드가 달린 자켓이 포함된 티어플과 오렌지색 옷을 입고 있습니다. 드레스는 짧은 스커트와 높은 칼라를 가지고 있으며, 노란색 주머니와 가슴에 작은 리본이 달린 검은 자켓과 어울립니다. 캐릭터는 검은 줄무늬가 있는 무릎 높이 양말과 별 모양 장식이 있는 흰색 신발을 신고 있습니다.
lr: (3e-4, flow_shift7.0, timestep_boundary 885)
epoch: 140
train_step: 4200
lora_strength: 0.8
샘플 프롬프트: Igarashi Rika, anime-style girl. The image features an anime-style character with long, light pink hair styled in a high ponytail adorned with a star-shaped hair accessory. The character has blue eyes and is wearing a black choker with a small pendant. She is dressed in a teal and orange outfit that includes a short skirt and a jacket with a hood. The dress has a short skirt and a high collar, complemented by a black jacket with a yellow pocket and a small bow on the chest. The character also wears knee-high socks with black stripes and white shoes with star-shaped decorations. (she is dancing:4.0), (chibi Nendoroid:4.5) in bedroom.
액션 프롬프트는 강조 프롬프트에 따라 3.0~5.0로 조정해야 합니다. 또는 모션 LoRA를 함께 사용하세요.
lightx2v Wan2.2 v1.1과의 병용을 권장합니다.
Action prompt should be adjusted to 3.0 to 5.0 depending on emphasis prompt. Or motion lora use together.
It is recommended to use with lightx2v Wan2.2 v1.1 lora.
・왜 --timestep_boundary 885를 사용했는가
dpm++, step=8, shift=7.0일 때 타임스텝은 [1.0000, 0.9800, 0.9545, 0.9210, "0.8750", 0.8077, 0.7000, 0.5000]입니다.
여기서 low_noise 모델의 첫 번째 스텝은 0.8750인데, 이때 품질은 좋지만 캐릭터 재현도가 낮았습니다.
이때 shift를 줄여 0.8750 → 0.865로 하면 캐릭터 재현도가 향상되는 것을 발견했습니다.(동시에 품질은 약간 저하됨)
어떤 이유에서인지 musubi-tuner는 high/low 모델에서 하나의 LoRA만 학습시키며, --timestep_boundary 875일 경우 이 경계점을 제대로 학습하지 못하는 것으로 보입니다.
0.876에서는 high 모델로 학습되고, 0.874에서는 low 모델로 학습됩니다. 즉, 0.875 근처에서는 high/low 모델이 50% 확률로 선택됩니다.
생성 시 0.875는 low 모델을 사용하지만, 이 경계점을 low 모델만으로 학습할 수 없습니다. 두 개의 LoRA를 학습할 경우 이런 문제가 발생하지 않습니다.
학습 시 --timestep_boundary 885로 설정했을 때 캐릭터 재현도가 향상되었습니다.
Wan2.2ver1:
이 LoRA는 Nijisanji의 캐릭터 이가라시 리카(五十嵐梨花)를 묘사합니다.
트리거 단어: Igarashi Rika, 애니메이션 스타일 소녀. 이미지는 긴 연한 주황색 머리카락을 높은 단발로 묶고 흰색 리본과 노란 별 모양의 머리 장식을 단 애니메이션 스타일 캐릭터를 특징으로 합니다. 캐릭터는 반짝이는 듯한 큰 표현력 있는 파란 눈을 가지고 있습니다. 검은 색 초커에 작은 펜던트, 얇은 끈이 달린 녹색 오버올, 고양이 모양 버클이 있는 노란 벨트를 착용하고 있습니다. 옷에는 흰색 칼라와 흰색 후드가 달린 오렌지 및 검은 자켓이 포함됩니다. 캐릭터는 검은 줄무늬가 있는 무릎 높이 양말과 별 모양 장식이 있는 흰색 신발을 신고 있습니다.
학습 데이터: musubi-tuner, 30장 이미지
캡션: Qwen2.5-VL-3B에서 조정된 캡션(설명된 배경 포함)
lr: (2e-4, flow_shift7.0)
epoch: 200
train_step: 6000
lora_strength: 1.0
샘플 프롬프트: Igarashi Rika, anime-style girl. The image features an anime-style character with long, light orange hair styled in a high bun adorned with a white bow and a yellow star-shaped hair accessory. The character has large, expressive blue eyes with a hint of sparkle. She is wearing a black choker with a small pendant, a green overall with thin straps, and a yellow belt with a cat-shaped buckle. Her outfit includes a white collar and a orange and black jacket with a white hood. The character also wears knee-high socks with black stripes and white shoes with star-shaped decorations. (She is breakdancing:3.5) in bedroom.
액션 프롬프트는 강조 프롬프트에 따라 3.0~5.0로 조정해야 합니다. 또는 모션 LoRA를 함께 사용하세요.
Action prompt should be adjusted to 3.0 to 5.0 depending on emphasis prompt. Or motion lora use together.
스타일 LoRA(시험용)와 캐릭터 LoRA는 각각 high/low 모델 모두에 동일한 가중치를 적용하세요. lightx2v wan2.2 V1.1은 다른 가중치를 적용하세요.
Style lora(M1_prototype) and character lora should be adapted same weight to both high and low models. lightx2v wan2.2 V1.1 apply a different weight.
스타일 LoRA(시험용)는 함께 첨부해두지만, 아직 조정 중입니다.
LoRA 제작 메모:
・musubi-tuner로 처음 wan2.2를 학습시키려 했을 때, wan2.1의 학습 방법으로
--dit models/wan2.1_t2v_14B_fp16.safetensors → --dit models/wan2.2_t2v_high_noise_14B_fp16.safetensors
를 사용해 high_noise 모델만 학습시켰습니다.
이때 캐릭터 재현도가 부족했고, 배경이 하얗게 나오는 문제가 있었습니다.
さらに LoRA 적용 강도를 높이면 재현도는 향상되지만, 움직임이 거의 사라지고 배경이 완전히 하얗게 되는 상황이었습니다.
・wan2.2의 2단계 워크플로우에서 두 모델 모두 wan2.1로 교체하고, 앞부분 또는 뒷부분의 LoRA 강도를 없애보았습니다.
그러나 캐릭터 LoRA는 high_noise 또는 low_noise 영역 중 하나에만 국한되지 않고 양쪽을 모두 포함하는 것 같아, high 또는 low 중 하나만으로 학습하는 것이 부적절한 것으로 보입니다.
・(wan2.2_high_noise_model + wan2.2 LoRA) + (wan2.1_model + wan2.1 LoRA) 구조도 시도했지만 해결되지 않았습니다.
・--min_timestep 875 --max_timestep 1000 또는 --discrete_flow_shift 0.33의 역수를 시도했지만 개선되지 않았습니다.
・Wan2.2의 비디오 생성 설정에 대해서도 당시 여러 번 시도해보았습니다.
・또 wan2.2의 low_noise 모델에 스타일 LoRA를 학습시켜보았지만, 이를 추가해도 품질에 큰 변화가 없었습니다.
☆이러는 사이 musubi-tuner에서 wan2.2 학습 기능이 구현되었습니다.
high/low 모델에서 하나의 LoRA만 학습합니다.
VRAM을 많이 사용하므로, 로컬의 4070Ti(12GB)에서는 blocks_to_swap 38로도 학습이 불가능했습니다. Google Colab의 A100을 사용하여 학습했습니다.
그리고 "%pip install -e ." 및 "%pip install --upgrade bitsandbytes"를 실행했습니다.
이미지 30장, 학습 해상도 576, 모델 로딩 시간을 포함해 200스텝에 2시간 30분, 300스텝에 약 3시간 30분 정도 소요되었습니다.
--discrete_flow_shift는 처음에 3.0을 사용했고, 이후 7.0으로 변경했습니다. epoch 200에서 LoRA 가중치는 7.0이 더 좋았지만, 단순히 과적합이 해소된 것일 수도 있습니다.
참고로 제 학습 명령어를 보여드립니다.
!accelerate launch --num_cpu_threads_per_process 1 --mixed_precision bf16 wan_train_network.py --task t2v-A14B --dit models/wan2.2_t2v_low_noise_14B_fp16.safetensors --dit_high_noise models/wan2.2_t2v_high_noise_14B_fp16.safetensors --dataset_config configs/config.toml --sdpa --mixed_precision bf16 --fp8_base --optimizer_type adamw8bit --learning_rate 2e-4 --gradient_checkpointing --max_data_loader_n_workers 2 --persistent_data_loader_workers --network_module networks.lora_wan --network_dim 32 --timestep_sampling shift --discrete_flow_shift 7.0 --max_train_epochs 301 --save_every_n_epochs 20 --seed 42 --output_dir outputs --output_name wan22_multi2_test004 --blocks_to_swap 4 --preserve_distribution_shape --mixed_precision fp16
・그러나 이 LoRA로 생성해도 움직임은 좋았지만 결국 생성 품질은 보통이었습니다.
그리고 lightx2v wan2.2 V1.1을 사용했을 때 품질이 일반적으로 향상되었습니다.
그 전에 학습했던 스타일 LoRA도 lightx2v 적용 후에 효과를 발휘하게 되었습니다.
또한 스타일 LoRA 없이도 꽤 좋았습니다. 스타일 LoRA의 장점은 CFG=1일 때도 품질이 높다는 정도였습니다.
또한 재현도가 좋지 않았던 원인은 단순히 생성 프롬프트가 정확하지 않아서였고, 이는 생성 프롬프트를 미세 조정하여 개선되었습니다.
wan2.1은 프롬프트가 약간 달라도 캐릭터를 생성할 수 있는 유연성이 있었고, 반대로 말하면 wan2.2는 잘못된 프롬프트를 무시하지 않는 것으로 볼 수 있습니다.
생성 조건은 전반부 4스텝, 후반부 4스텝, 총 8스텝이며, 모두 CFG=1입니다.
