Stability-AI / stablediffusion

High-Resolution Image Synthesis with Latent Diffusion Models
MIT License
38.83k stars 5.01k forks source link

Setting default device as cuda #275

Open Mateusmsouza opened 1 year ago

Mateusmsouza commented 1 year ago

Recently there was a change to support CPU, but CPU was set as default device. It broke old versions pipelines to generate samples on txt2image, throwing an error: RuntimeError: expected scalar type BFloat16 but found Float Like in this issue https://github.com/Stability-AI/stablediffusion/issues/236. It is solved by passing --device cuda, which used to be default.

This PR changes default device to cuda.