Skip to content

Commit

Permalink
Merge pull request #910 from antoniprzybylik/main
Browse files Browse the repository at this point in the history
Change visibility of `nn::Path::add` method to public.
  • Loading branch information
LaurentMazare authored Nov 18, 2024
2 parents 4841b68 + 0cce5bb commit 2de026d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/nn/var_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,7 @@ impl<'a> Path<'a> {
self.set_float_kind(Kind::Double);
}

pub(crate) fn add(&self, name: &str, tensor: Tensor, trainable: bool) -> Tensor {
pub fn add(&self, name: &str, tensor: Tensor, trainable: bool) -> Tensor {
let path = self.path(name);
let mut variables = self.var_store.variables_.lock().unwrap();
let path = if variables.named_variables.contains_key(&path) {
Expand Down

0 comments on commit 2de026d

Please sign in to comment.