Beispiel #1
0
 def hybrid_forward(self, F, x):
     sigmoid = F.npx.tanh if is_np_array() else F.tanh
     return sigmoid(x, name='fwd')
Beispiel #2
0
 def g():
     with mx.np_array(False):
         event.wait()
         if not mx.is_np_array():
             status[0] = True
Beispiel #3
0
 def hybrid_forward(self, F, x):
     relu = F.npx.relu if is_np_array() else F.relu
     return relu(x, name='fwd')