diff options
author | Laurent Mazare <laurent.mazare@gmail.com> | 2023-07-22 11:39:27 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-22 10:39:27 +0100 |
commit | 43c72232927ca80c850a73ce977c2063d5a2dcf5 (patch) | |
tree | c93c07984e06b1925313f4f641a8b1a3956fc0ed /candle-examples/examples/musicgen/t5_model.rs | |
parent | 52c5d8c087f6a2ee91b807467860eb3e96bb6267 (diff) | |
download | candle-43c72232927ca80c850a73ce977c2063d5a2dcf5.tar.gz candle-43c72232927ca80c850a73ce977c2063d5a2dcf5.tar.bz2 candle-43c72232927ca80c850a73ce977c2063d5a2dcf5.zip |
Rename the .r functions to .dims so as to be a bit more explicit. (#220)
Diffstat (limited to 'candle-examples/examples/musicgen/t5_model.rs')
-rw-r--r-- | candle-examples/examples/musicgen/t5_model.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/candle-examples/examples/musicgen/t5_model.rs b/candle-examples/examples/musicgen/t5_model.rs index 15945d4e..61c0a1bb 100644 --- a/candle-examples/examples/musicgen/t5_model.rs +++ b/candle-examples/examples/musicgen/t5_model.rs @@ -338,7 +338,7 @@ impl T5Stack { fn forward(&self, input_ids: &Tensor) -> Result<Tensor> { let input_embeds = self.shared.as_ref().forward(input_ids)?; - let (_b_sz, _seq_len) = input_embeds.shape().r2()?; + let (_b_sz, _seq_len) = input_embeds.dims2()?; let mut hidden_states = self.dropout.forward(&input_embeds)?; for block in self.block.iter() { |