diff options
author | drbh <david.richard.holtz@gmail.com> | 2023-11-16 16:15:22 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-16 21:15:22 +0000 |
commit | 92a05b51cf8c88e40f03f6431b81f68a456f633f (patch) | |
tree | 3f666a747e94014d60d4dcf829792b94c5e0a448 /candle-examples/examples | |
parent | c6763e3b41790bea0459d3838c3ed1d59d5174ef (diff) | |
download | candle-92a05b51cf8c88e40f03f6431b81f68a456f633f.tar.gz candle-92a05b51cf8c88e40f03f6431b81f68a456f633f.tar.bz2 candle-92a05b51cf8c88e40f03f6431b81f68a456f633f.zip |
fix: address clippy 0.1.74 issues (#1336)
- clippy::needless-borrows-for-generic-args
- clippy::reserve-after-initialization
Diffstat (limited to 'candle-examples/examples')
-rw-r--r-- | candle-examples/examples/stable-diffusion/main.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/candle-examples/examples/stable-diffusion/main.rs b/candle-examples/examples/stable-diffusion/main.rs index d982a209..3e6de34d 100644 --- a/candle-examples/examples/stable-diffusion/main.rs +++ b/candle-examples/examples/stable-diffusion/main.rs @@ -416,7 +416,7 @@ fn run(args: Args) -> Result<()> { println!("Building the autoencoder."); let vae_weights = ModelFile::Vae.get(vae_weights, sd_version, use_f16)?; - let vae = sd_config.build_vae(&vae_weights, &device, dtype)?; + let vae = sd_config.build_vae(vae_weights, &device, dtype)?; let init_latent_dist = match &img2img { None => None, Some(image) => { @@ -426,7 +426,7 @@ fn run(args: Args) -> Result<()> { }; println!("Building the unet."); let unet_weights = ModelFile::Unet.get(unet_weights, sd_version, use_f16)?; - let unet = sd_config.build_unet(&unet_weights, &device, 4, use_flash_attn, dtype)?; + let unet = sd_config.build_unet(unet_weights, &device, 4, use_flash_attn, dtype)?; let t_start = if img2img.is_some() { n_steps - (n_steps as f64 * img2img_strength) as usize |