summaryrefslogtreecommitdiff
path: root/candle-examples/examples/stable-diffusion/utils.rs
Commit message (Collapse)AuthorAgeFilesLines
* Move the stable-diffusion modeling code so that it's easier to re-use. (#812)Laurent Mazare2023-09-111-39/+0
|
* dinov2 - read images from disk and compute the class probabilities (#503)Laurent Mazare2023-08-181-19/+0
| | | | | * Load the image from disk and convert it to a tensor. * Tweak the function name.
* Add a simple Module trait and implement it for the various nn layers (#500)Laurent Mazare2023-08-181-0/+1
| | | | | | | * Start adding the module trait. * Use the module trait. * Implement module for qmatmul.
* Track the conv2d operations in stable-diffusion. (#431)Laurent Mazare2023-08-131-0/+26
| | | | | | | | | | | | | * Track the conv2d operations in stable-diffusion. * Add more tracing to stable-diffusion. * Also trace the resnet bits. * Trace the attention blocks. * Also trace the attention inner part. * Small tweak.
* Write the generated images using the image crate. (#363)Laurent Mazare2023-08-091-0/+19
| | | | | * Use the image crate to write the generated images. * Make the dependency optional.
* Skeleton for the avg-pool2d and upsample-nearest2d ops. (#337)Laurent Mazare2023-08-071-8/+0
| | | | | * Skeleton for the avg-pool2d and upsample-nearest2d ops. * Preliminary conv2d support.
* Simple pad support. (#336)Laurent Mazare2023-08-071-4/+0
| | | | | * Simple pad support. * Fix the tensor indexing when padding.
* Implement group-norm. (#334)Laurent Mazare2023-08-071-5/+0
| | | | | * Implement group-norm. * Add some testing for group-norm.
* Add the recip op + use it in stable-diffusion. (#331)Laurent Mazare2023-08-061-5/+13
| | | | | | | * Add the recip unary op. * Fix the cuda kernel. * Use the recip op in sigmoid.
* Add the ddim scheduler. (#330)Laurent Mazare2023-08-061-0/+4
|
* Add a stable diffusion example (#328)Laurent Mazare2023-08-061-0/+17
* Start adding a stable-diffusion example. * Proper computation of the causal mask. * Add the chunk operation. * Work in progress: port the attention module. * Add some dummy modules for conv2d and group-norm, get the attention module to compile. * Re-enable the 2d convolution. * Add the embeddings module. * Add the resnet module. * Add the unet blocks. * Add the unet. * And add the variational auto-encoder. * Use the pad function from utils.