mirror of
https://github.com/huggingface/candle.git
synced 2025-06-17 11:08:52 +00:00
Softmax cpu implementation.
This commit is contained in:
@ -301,7 +301,7 @@ impl Tensor {
|
||||
.storage
|
||||
.unary_impl::<crate::op::Exp>(shape, self.stride())?;
|
||||
// The resulting storage is contiguous.
|
||||
storage.divide_by_sum_over_dim(shape, dim);
|
||||
storage.divide_by_sum_over_dim(shape, dim)?;
|
||||
let op = if self.track_op() {
|
||||
Some(Op::Softmax(self.clone(), dim))
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user