许可证:其他
标签:
- stable-diffusion
- text-to-image
推理:false
Cool Japan Diffusion 2.1.2 模型卡片

英文版请见此处。
简介
Cool Japan Diffusion 是基于 Stable Diffusion 微调的模型,专注于表现动漫、漫画、游戏等“酷日本”文化。请注意,此模型与日本内阁府的“酷日本”战略无直接关联。
使用方法
想快速体验的用户可使用此Space。
详细操作指南请参阅使用说明书。
模型文件可从此处下载。
许可证说明
本模型在 CreativeML Open RAIL++-M License 基础上追加了非商业用途限制条款,原因是为避免对创作行业造成潜在负面影响。若此担忧消除,后续版本将恢复原始许可证并允许商用。原始许可证日文译本见此链接。
商业机构用户请咨询法务部门。个人用户遵循常识即可,无需过度担忧。根据许可证要求,任何模型修改仍需继承本许可协议。
法律与伦理
本模型在日本开发,适用日本法律。
- 合法性声明:模型训练基于《著作权法》第30条之4主张合法;分发行为不构成直接或间接侵权(详见柿沼律师观点)。
- 伦理声明:尽管法律允许,但作者认为未经原作者许可的分发行为存在伦理争议。本次分发亦旨在探讨技术伦理边界。
模型详情
- 开发者:Robin Rombach, Patrick Esser, Alfred Increment
- 模型类型:基于扩散模型的文生图模型
- 语言:日语
- 许可证:CreativeML Open RAIL++-M-NC License
- 算法:Latent Diffusion Model 与 OpenCLIP-ViT/H
- 引用文献:
@InProceedings{Rombach_2022_CVPR,
author = {Rombach, Robin and Blattmann, Andreas and Lorenz, Dominik and Esser, Patrick and Ommer, Bj\"orn},
title = {High-Resolution Image Synthesis With Latent Diffusion Models},
booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
month = {June},
year = {2022},
pages = {10684-10695}
}
使用示例
Web UI方式
推荐安装xformers,具体步骤参照指南。
Diffusers库方式
安装依赖:
pip install --upgrade git+https://github.com/huggingface/diffusers.git transformers accelerate scipy
生成图像脚本:
from diffusers import StableDiffusionPipeline, EulerAncestralDiscreteScheduler
import torch
model_id = "aipicasso/cool-japan-diffusion-2-1-2"
scheduler = EulerAncestralDiscreteScheduler.from_pretrained(model_id, subfolder="scheduler")
pipe = StableDiffusionPipeline.from_pretrained(model_id, scheduler=scheduler, torch_dtype=torch.float32)
pipe = pipe.to("cuda")
prompt = "anime, masterpiece, a portrait of a girl, good pupil, 4k, detailed"
negative_prompt = "deformed, blurry..."
images = pipe(prompt, negative_prompt=negative_prompt, num_inference_steps=20).images
images[0].save("girl.png")
注意:
- 使用xformers可加速生成
- 低显存设备建议启用
pipe.enable_attention_slicing()
适用场景
- 新闻报道(含商业媒体)
- 海外“酷日本”文化推广
- 学术研究(模型微调/性能评估等)
- 美术教育(毕业设计/课题研究)
- 个人创意表达
禁用场景
- 伪造事实内容
- 盈利性视频内容
- 直接商用服务
- 破坏教学秩序
- 损害创作行业
风险提示
- 禁止数字赝品制作
- 禁止未经授权的图生图
- 禁止传播淫秽内容
- 禁止制造虚假新闻
局限性
- 存在与Stable Diffusion相同的偏见问题
训练数据
- VAE:65万组合规日本数据(经扩增)
- U-Net:200万组数据+3个混合模型
训练配置
- 硬件:NVIDIA A6000
- 优化器:AdamW
- 批次大小:1
- 训练时长:200小时
环境影响
碳排放量极低(日本本地训练)
本模型卡片基于Stable Diffusion v2由Alfred Increment编写