@@ -285,7 +285,7 @@ impl Module<&Array> for Glu {
285285 type Output = Array ;
286286
287287 fn forward ( & mut self , x : & Array ) -> Result < Array > {
288- glu ( x, self . axis ) . map_err ( Into :: into )
288+ glu ( x, self . axis )
289289 }
290290
291291 fn training_mode ( & mut self , _: bool ) { }
@@ -336,7 +336,7 @@ impl Module<&Array> for Mish {
336336 type Output = Array ;
337337
338338 fn forward ( & mut self , x : & Array ) -> Result < Array > {
339- mish ( x) . map_err ( Into :: into )
339+ mish ( x)
340340 }
341341
342342 fn training_mode ( & mut self , _: bool ) { }
@@ -358,7 +358,7 @@ impl Module<&Array> for Relu {
358358 type Output = Array ;
359359
360360 fn forward ( & mut self , x : & Array ) -> Result < Array > {
361- relu ( x) . map_err ( Into :: into )
361+ relu ( x)
362362 }
363363
364364 fn training_mode ( & mut self , _: bool ) { }
@@ -393,7 +393,7 @@ impl Module<&Array> for LeakyRelu {
393393 type Output = Array ;
394394
395395 fn forward ( & mut self , x : & Array ) -> Result < Array > {
396- leaky_relu ( x, self . neg_slope ) . map_err ( Into :: into )
396+ leaky_relu ( x, self . neg_slope )
397397 }
398398
399399 fn training_mode ( & mut self , _: bool ) { }
@@ -415,7 +415,7 @@ impl Module<&Array> for Relu6 {
415415 type Output = Array ;
416416
417417 fn forward ( & mut self , x : & Array ) -> Result < Array > {
418- relu6 ( x) . map_err ( Into :: into )
418+ relu6 ( x)
419419 }
420420
421421 fn training_mode ( & mut self , _: bool ) { }
@@ -472,7 +472,7 @@ impl Module<&Array> for Softplus {
472472 type Output = Array ;
473473
474474 fn forward ( & mut self , x : & Array ) -> Result < Array > {
475- softplus ( x) . map_err ( Into :: into )
475+ softplus ( x)
476476 }
477477
478478 fn training_mode ( & mut self , _: bool ) { }
@@ -494,7 +494,7 @@ impl Module<&Array> for Softsign {
494494 type Output = Array ;
495495
496496 fn forward ( & mut self , x : & Array ) -> Result < Array > {
497- softsign ( x) . map_err ( Into :: into )
497+ softsign ( x)
498498 }
499499
500500 fn training_mode ( & mut self , _: bool ) { }
@@ -530,7 +530,7 @@ impl Module<&Array> for Celu {
530530 type Output = Array ;
531531
532532 fn forward ( & mut self , x : & Array ) -> Result < Array > {
533- celu ( x, self . alpha ) . map_err ( Into :: into )
533+ celu ( x, self . alpha )
534534 }
535535
536536 fn training_mode ( & mut self , _: bool ) { }
@@ -552,7 +552,7 @@ impl Module<&Array> for Silu {
552552 type Output = Array ;
553553
554554 fn forward ( & mut self , x : & Array ) -> Result < Array > {
555- silu ( x) . map_err ( Into :: into )
555+ silu ( x)
556556 }
557557
558558 fn training_mode ( & mut self , _: bool ) { }
@@ -587,7 +587,7 @@ impl Module<&Array> for LogSoftmax {
587587 type Output = Array ;
588588
589589 fn forward ( & mut self , x : & Array ) -> Result < Array > {
590- log_softmax ( x, self . axis ) . map_err ( Into :: into )
590+ log_softmax ( x, self . axis )
591591 }
592592
593593 fn training_mode ( & mut self , _: bool ) { }
@@ -609,7 +609,7 @@ impl Module<&Array> for LogSigmoid {
609609 type Output = Array ;
610610
611611 fn forward ( & mut self , x : & Array ) -> Result < Array > {
612- log_sigmoid ( x) . map_err ( Into :: into )
612+ log_sigmoid ( x)
613613 }
614614
615615 fn training_mode ( & mut self , _: bool ) { }
@@ -671,7 +671,7 @@ impl Module<&Array> for Prelu {
671671 type Output = Array ;
672672
673673 fn forward ( & mut self , x : & Array ) -> Result < Array > {
674- prelu ( x, & self . weight ) . map_err ( Into :: into )
674+ prelu ( x, & self . weight )
675675 }
676676
677677 fn training_mode ( & mut self , _: bool ) { }
@@ -716,9 +716,9 @@ impl Module<&Array> for Gelu {
716716
717717 fn forward ( & mut self , x : & Array ) -> Result < Array > {
718718 match self . approximate {
719- GeluApprox :: None => gelu ( x) . map_err ( Into :: into ) ,
720- GeluApprox :: Precise => gelu_approximate ( x) . map_err ( Into :: into ) ,
721- GeluApprox :: Fast => gelu_fast_approximate ( x) . map_err ( Into :: into ) ,
719+ GeluApprox :: None => gelu ( x) ,
720+ GeluApprox :: Precise => gelu_approximate ( x) ,
721+ GeluApprox :: Fast => gelu_fast_approximate ( x) ,
722722 }
723723 }
724724
@@ -757,7 +757,7 @@ impl Module<&Array> for HardSwish {
757757 type Output = Array ;
758758
759759 fn forward ( & mut self , x : & Array ) -> Result < Array > {
760- hard_swish ( x) . map_err ( Into :: into )
760+ hard_swish ( x)
761761 }
762762
763763 fn training_mode ( & mut self , _: bool ) { }
@@ -795,7 +795,7 @@ impl Module<&Array> for Step {
795795 type Output = Array ;
796796
797797 fn forward ( & mut self , x : & Array ) -> Result < Array > {
798- step ( x, self . threshold ) . map_err ( Into :: into )
798+ step ( x, self . threshold )
799799 }
800800
801801 fn training_mode ( & mut self , _: bool ) { }
@@ -817,7 +817,7 @@ impl Module<&Array> for Selu {
817817 type Output = Array ;
818818
819819 fn forward ( & mut self , x : & Array ) -> Result < Array > {
820- selu ( x) . map_err ( Into :: into )
820+ selu ( x)
821821 }
822822
823823 fn training_mode ( & mut self , _: bool ) { }
0 commit comments