Clippy fixes for 1.81.0. (#2461)

* Clippy fixes for 1.81.0.

* Another fix.
This commit is contained in:
Laurent Mazare
2024-09-05 22:46:55 +01:00
committed by GitHub
parent c02b7c3272
commit e3261216b1
17 changed files with 28 additions and 29 deletions

View File

@ -275,7 +275,7 @@ impl Llama {
let lm_head = linear(cfg.dim, cfg.vocab_size, vb.pp("lm_head"))?;
let norm = rms_norm(cfg.dim, cfg.norm_eps, vb.pp("model.norm"))?;
let blocks: Vec<_> = (0..cfg.n_layers)
.map(|i| Block::load(vb.pp(&format!("model.layers.{i}")), cache, cfg).unwrap())
.map(|i| Block::load(vb.pp(format!("model.layers.{i}")), cache, cfg).unwrap())
.collect();
Ok(Self::new(wte, blocks, norm, lm_head))
}