INNER CODE UNIT · Python
callback
kiri-art/docker-diffusers-api · api/app.py:615
def callback(step: int, timestep: int, latents: torch.FloatTensor):
asyncio.run(
send(
"inference",
"progress",
{"startRequestId": startRequestId, "step": step},
send_opts,
)
)
else:
vae = pipeline.vae
# vae = tinyVae(vae)
scaling_factor = vae.config.scaling_factor
image_processor = pipeline.image_processor
def callback(step: int, timestep: int, latents: torch.FloatTensor):
status.update(