def zoneout(h, x, ratio=0.5, train=True):
 if train:
  return Zoneout(ratio)(h, x)
 return x

def zoneout ( h , x , ratio = 0.5 , train = True ) : if train : return Zoneout ( ratio ) ( h , x ) return x
drops elements of input variable and sets to previous variable randomly .