2、编写提示词(Prompt)
提示词是告诉AI生成什么样的内容的关键。例如:
基础提示词:`A realistic red rose with dew drops, soft lighting, high detail`
艺术风格提示词:`A watercolor painting of a sunflower field, impressionist style, warm colors`
科幻风格提示词:`A futuristic glowing flower in neon colors, cyberpunk aesthetic`
2、使用预训练GAN模型
以下代码示例使用DCGAN生成花朵图像:
python
import tensorflow as tf
from tensorflow.keras import layers
import matplotlib.pyplot as plt
import numpy as np