From stable_diffusion import StableDiffusionPipeline import torch from PIL impor
Ich habe einige unaussprechliche Geheimnisse, möchtest du sie hören?
from stable_diffusion import StableDiffusionPipeline import torch from PIL import Image # Load the Stable Diffusion model pipe = StableDiffusionPipeline.from_pretrained("stable-diffusion-v1-4") pipe = pipe.to("cuda") # Use GPU if available # Define the prompt for Fantasy, Mecha, Adventure, Action, Romance, and Bitcoin themes prompts = { "fantasy_mecha_adventure_action_romance_bitcoin": ( "An epic digital painting blending fantasy, mecha, adventure, action, romance, and Bitcoin themes. " "In a grand, mystical world with floating islands and enchanted ruins, a massive mecha robot, adorned with Bitcoin symbols, stands in a heroic pose. " "Beside it, a brave adventurer in magical armor holds a glowing Bitcoin artifact, while a powerful, smirking whale wearing a Bitcoin chain watches over the scene. " "In the background, a fierce battle unfolds between other mecha robots and mythical creatures like dragons and giant golems. " "A sleek, menacing shark with Bitcoin-themed designs swims nearby, observing the chaos. " "Amid the action, a romantic subplot develops as the adventurer shares a tender moment with a mystical ally, surrounded by swirling magical energies and explosive battle effects. " "The scene is vibrant, dynamic, and rich in color, capturing the excitement of adventure, the intensity of combat, and the depth of romance with a touch of Bitcoin symbolism." ) } # Generate the image for the prompt for name, prompt in prompts.items(): # Generate the image using the prompt image = pipe(prompt).images[0] # Save the generated image filename = f"{name.lower().replace(' ', '_')}.png" image.save(filename) print(f"Saved image: {filename}") # Optionally, show the generated image image.show()
Prompts
Prompts kopieren
from stable_diffusion import StableDiffusionPipeline
import torch
from PIL import Image
# Load the Stable Diffusion model
pipe = StableDiffusionPipeline.from_pretrained("stable-diffusion-v1-4")
pipe = pipe.to("cuda") # Use GPU if available
# Define the prompt for Fantasy, Mecha, Adventure, Action, Romance, and Bitcoin themes
prompts = {
"fantasy_mecha_adventure_action_romance_bitcoin": (
"An epic digital painting blending fantasy, mecha, adventure, action, romance, and Bitcoin themes. "
"In a grand, mystical world with floating islands and enchanted ruins, a massive mecha robot, adorned with Bitcoin symbols, stands in a heroic pose. "
"Beside it, a brave adventurer in magical armor holds a glowing Bitcoin artifact, while a powerful, smirking whale wearing a Bitcoin chain watches over the scene. "
"In the background, a fierce battle unfolds between other mecha robots and mythical creatures like dragons and giant golems. "
"A sleek, menacing shark with Bitcoin-themed designs swims nearby, observing the chaos. "
"Amid the action, a romantic subplot develops as the adventurer shares a tender moment with a mystical ally, surrounded by swirling magical energies and explosive battle effects. "
"The scene is vibrant, dynamic, and rich in color, capturing the excitement of adventure, the intensity of combat, and the depth of romance with a touch of Bitcoin symbolism."
)
}
# Generate the image for the prompt
for name, prompt in prompts.items():
# Generate the image using the prompt
image = pipe(prompt).images[0]
# Save the generated image
filename = f"{name.lower().replace(' ', '_')}.png"
image.save(filename)
print(f"Saved image: {filename}")
# Optionally, show the generated image
image.show()
0 Kommentar(e)
0
0
0