@@ -120,7 +120,7 @@ public static Tensor mean<T1, T2>(T1 input, T2 axis, bool keep_dims= false, stri
120120 {
121121 try
122122 {
123- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , tf . context . device_name , "Mean" , name , null , input , axis , "keep_dims" , keep_dims ) ;
123+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , tf . context . device_name , "Mean" , name , null , input , axis , "keep_dims" , keep_dims ) ;
124124 return _result ;
125125 }
126126 catch ( Exception ex )
@@ -171,7 +171,7 @@ public static Tensor add<Tx, Ty>(Tx x, Ty y, string name = null)
171171 {
172172 if ( tf . context . executing_eagerly ( ) )
173173 {
174- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , "" , "Add" , name , null , x , y ) ;
174+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , "" , "Add" , name , null , x , y ) ;
175175 return _result ;
176176 }
177177
@@ -204,6 +204,14 @@ public static Tensor ceil(Tensor x, string name = null)
204204
205205 public static Tensor sin ( Tensor x , string name = null )
206206 {
207+ if ( tf . context . executing_eagerly ( ) )
208+ {
209+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , tf . context . device_name ,
210+ "Sin" , name , null ,
211+ x ) ;
212+ return _result ;
213+ }
214+
207215 var _op = _op_def_lib . _apply_op_helper ( "Sin" , name , args : new { x } ) ;
208216
209217 return _op . outputs [ 0 ] ;
@@ -225,6 +233,14 @@ public static Tensor sin(Tensor x, string name = null)
225233 /// </remarks>
226234 public static Tensor sigmoid ( Tensor x , string name = "Sigmoid" )
227235 {
236+ if ( tf . context . executing_eagerly ( ) )
237+ {
238+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , tf . context . device_name ,
239+ "Sigmoid" , name , null ,
240+ x ) ;
241+ return _result ;
242+ }
243+
228244 var op = _op_def_lib . _apply_op_helper ( "Sigmoid" , name : name , new { x } ) ;
229245
230246 return op . output ;
@@ -493,7 +509,7 @@ public static Tensor cast(Tensor x, TF_DataType DstT, bool Truncate= false, stri
493509 {
494510 if ( tf . context . executing_eagerly ( ) )
495511 {
496- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , "" , "Cast" , name , null , x , "DstT" , DstT , "Truncate" , Truncate ) ;
512+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , "" , "Cast" , name , null , x , "DstT" , DstT , "Truncate" , Truncate ) ;
497513 return _result ;
498514 }
499515
@@ -520,7 +536,7 @@ public static Tensor sub<Tx, Ty>(Tx x, Ty y, string name = null)
520536 {
521537 if ( tf . context . executing_eagerly ( ) )
522538 {
523- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , "" , "Sub" , name , null , x , y ) ;
539+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , "" , "Sub" , name , null , x , y ) ;
524540 return _result ;
525541 }
526542
@@ -571,7 +587,7 @@ public static Tensor mul<Tx, Ty>(Tx x, Ty y, string name = null)
571587 {
572588 if ( tf . context . executing_eagerly ( ) )
573589 {
574- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , "" , "Mul" , name , null , x , y ) ;
590+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , "" , "Mul" , name , null , x , y ) ;
575591 return _result ;
576592 }
577593
@@ -591,7 +607,7 @@ public static Tensor real_div(Tensor x, Tensor y, string name = null)
591607 {
592608 if ( tf . context . executing_eagerly ( ) )
593609 {
594- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , "" , "RealDiv" , name , null , x , y ) ;
610+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , "" , "RealDiv" , name , null , x , y ) ;
595611 return _result ;
596612 }
597613
@@ -618,7 +634,7 @@ public static Tensor floor_div(Tensor x, Tensor y, string name = null)
618634 {
619635 if ( tf . context . executing_eagerly ( ) )
620636 {
621- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , "" , "FloorDiv" , name , null , x , y ) ;
637+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , "" , "FloorDiv" , name , null , x , y ) ;
622638 return _result ;
623639 }
624640
@@ -640,7 +656,7 @@ public static Tensor mat_mul(Tensor a, Tensor b, bool transpose_a = false, bool
640656 {
641657 if ( tf . context . executing_eagerly ( ) )
642658 {
643- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , tf . context . device_name ,
659+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , tf . context . device_name ,
644660 "MatMul" , name , null ,
645661 a , b , "transpose_a" , transpose_a , "transpose_b" , transpose_b ) ;
646662 return _result ;
@@ -748,7 +764,7 @@ public static Tensor _sum<Tx, Ty>(Tx input, Ty axis = default, bool keep_dims =
748764 {
749765 try
750766 {
751- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , tf . context . device_name ,
767+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , tf . context . device_name ,
752768 "Sum" , name , null ,
753769 input , axis , "keep_dims" , keep_dims ) ;
754770 return _result ;
@@ -789,7 +805,7 @@ public static Tensor range(Tensor start, Tensor limit, Tensor delta, string name
789805 {
790806 if ( tf . context . executing_eagerly ( ) )
791807 {
792- var _result = wrap_tfe_src . TFE_Py_FastPathExecute ( tf . context , tf . context . device_name , "Range" , name , null , start , limit , delta ) ;
808+ var _result = wrap_tfe_src . TFE_FastPathExecute ( tf . context , tf . context . device_name , "Range" , name , null , start , limit , delta ) ;
793809 return _result ;
794810 }
795811
0 commit comments