dropout using activation scaling to avoid test time weight rescaling
(X, p=0.)
| 34 | return dist |
| 35 | |
| 36 | def dropout(X, p=0.): |
| 37 | """ |
| 38 | dropout using activation scaling to avoid test time weight rescaling |
| 39 | """ |
| 40 | if p > 0: |
| 41 | retain_prob = 1 - p |
| 42 | X *= t_rng.binomial(X.shape, p=retain_prob, dtype=theano.config.floatX) |
| 43 | X /= retain_prob |
| 44 | return X |
| 45 | |
| 46 | def conv_cond_concat(x, y): |
| 47 | """ |
nothing calls this directly
no outgoing calls
no test coverage detected