(self, drop_prob=None)
| 63 | """Drop paths (Stochastic Depth) per sample (when applied in main path of residual blocks).""" |
| 64 | |
| 65 | def __init__(self, drop_prob=None): |
| 66 | super(DropPath, self).__init__() |
| 67 | self.drop_prob = drop_prob |
| 68 | |
| 69 | def forward(self, x): |
| 70 | return drop_path(x, self.drop_prob, self.training) |