Skip to content

Commit

Permalink
String-. &str
Browse files Browse the repository at this point in the history
  • Loading branch information
zachcp committed Nov 26, 2024
1 parent 0d753ee commit c4dba2f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions candle-nn/src/var_builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -549,10 +549,10 @@ impl<'a> VarBuilder<'a> {
pub fn from_pth_with_state<P: AsRef<std::path::Path>>(
p: P,
dtype: DType,
state_key: String,
state_key: &str,
dev: &Device,
) -> Result<Self> {
let pth = candle::pickle::PthTensors::new(p, Some(state_key.as_str()))?;
let pth = candle::pickle::PthTensors::new(p, Some(state_key))?;
Ok(Self::from_backend(Box::new(pth), dtype, dev.clone()))
}
/// Gets a VarBuilder that applies some renaming function on tensor it gets queried for before
Expand Down

0 comments on commit c4dba2f

Please sign in to comment.