Testing / app.py
Masrkai's picture
Update app.py
b55c638 verified
raw
history blame
380 Bytes
import torch
from diffusers import ShapEPipeline
from diffusers.utils import export_to_gif
ckpt_id = "openai/shap-e-xs"
pipe = ShapEPipeline.from_pretrained(repo).to("cpu")
guidance_scale = 15.0
prompt = "a shark"
images = pipe(
prompt,
guidance_scale=guidance_scale,
num_inference_steps=16,
size=256,
).images
gif_path = export_to_gif(images, "shark_3d.gif")