VERTEX AI SETUP SUCCESS (01.01.2026 21:00): ✅ gcloud CLI installed (v550.0.0) ✅ Authentication configured (ADC) ✅ Vertex AI API enabled ✅ Test generation successful (2 skull PNG) ✅ Credits confirmed: €1,121.80 available CHARACTER TESTS: ⚠️ edit_image blocked by safety filters (face generation) ⚠️ seed parameter blocked by watermark 📝 Character animations need alternative approach NEW FILES: ✅ reference_images/kai_master_stylea.png - Kai cartoon reference ✅ reference_images/kai_master_styleb.png - Kai noir reference ✅ scripts/test_character_consistency.py - Image edit test ✅ scripts/test_character_seed.py - Seed-based test TEST OUTPUTS: ✅ test_vertex_output.png (Style A skull - 2.4MB) ✅ test_vertex_output_styleb.png (Style B skull) PRODUCTION PLAN: 📊 Complete game: ~3,121-12,400 PNG 💰 Cost: €56-€223 (fully covered by credits!) ⏱️ Time: 8-34 hours for full generation 🎯 Ready for bulk asset generation NEXT STEPS: 1. Decide generation scope (unique vs full production) 2. Run bulk generation script 3. Background removal post-processing 4. Git commit batches during generation STATUS: Infrastructure ready, awaiting generation start 🚀
78 lines
2.7 KiB
Python
78 lines
2.7 KiB
Python
#!/usr/bin/env python3
|
|
"""
|
|
Test Character Consistency - SEED method
|
|
Generate Kai walking frames with CONSISTENT SEED
|
|
"""
|
|
|
|
import vertexai
|
|
from vertexai.preview.vision_models import ImageGenerationModel
|
|
from pathlib import Path
|
|
|
|
# Initialize
|
|
vertexai.init(project="gen-lang-client-0428644398", location="us-central1")
|
|
|
|
print("="*60)
|
|
print("🎮 KAI CHARACTER CONSISTENCY TEST - SEED METHOD")
|
|
print("="*60)
|
|
|
|
# Base character description
|
|
base_character = """
|
|
Young male farmer character named Kai. Green spiky hair, determined expression, wearing dark blue jean jacket over white shirt, backpack, ripped blue jeans, and brown boots. Cartoon vector art style with bold black outlines (1.4px), flat vibrant colors, clean playful aesthetic.
|
|
"""
|
|
|
|
# Animation frames with SAME SEED
|
|
frames = [
|
|
{
|
|
"name": "kai_seed_idle",
|
|
"prompt": f"{base_character} Standing idle pose, front facing view. Solid bright green background (#00FF00), centered character."
|
|
},
|
|
{
|
|
"name": "kai_seed_walk1",
|
|
"prompt": f"{base_character} Walking animation, left leg forward step, right arm swinging forward. Solid bright green background (#00FF00), centered character."
|
|
},
|
|
{
|
|
"name": "kai_seed_walk2",
|
|
"prompt": f"{base_character} Walking animation, neutral standing pose between steps. Solid bright green background (#00FF00), centered character."
|
|
},
|
|
{
|
|
"name": "kai_seed_walk3",
|
|
"prompt": f"{base_character} Walking animation, right leg forward step, left arm swinging forward. Solid bright green background (#00FF00), centered character."
|
|
}
|
|
]
|
|
|
|
model = ImageGenerationModel.from_pretrained("imagegeneration@006")
|
|
|
|
SEED = 12345 # ← ISTO število za vse frame = boljša konsistentnost!
|
|
|
|
# Generate frames
|
|
for i, frame in enumerate(frames, 1):
|
|
print(f"\n🎨 Generating Frame {i}/4: {frame['name']}")
|
|
print(f"📝 Using SEED: {SEED}")
|
|
|
|
try:
|
|
response = model.generate_images(
|
|
prompt=frame['prompt'],
|
|
number_of_images=1,
|
|
seed=SEED, # ← ISTI SEED!
|
|
aspect_ratio="1:1",
|
|
guidance_scale=15, # Higher = stricter prompt following
|
|
safety_filter_level="block_some",
|
|
person_generation="allow_adult"
|
|
)
|
|
|
|
output_path = Path(f"test_character/{frame['name']}.png")
|
|
output_path.parent.mkdir(exist_ok=True)
|
|
|
|
response.images[0].save(location=str(output_path))
|
|
|
|
print(f"✅ Saved: {output_path}")
|
|
|
|
except Exception as e:
|
|
print(f"❌ Error: {e}")
|
|
|
|
print("\n" + "="*60)
|
|
print("✅ TEST COMPLETE!")
|
|
print("📁 Check: test_character/ folder")
|
|
print("🔍 Compare frames for consistency!")
|
|
print("="*60)
|