(self)
| 293 | return x |
| 294 | |
| 295 | def structural_reparam(self): |
| 296 | for m in self.modules(): |
| 297 | if hasattr(m, 'merge_kernel'): |
| 298 | m.merge_kernel() |
| 299 | |
| 300 | # If your framework cannot automatically fuse BN for inference, you may do it manually. |
| 301 | # The BNs after and before conv layers can be removed. |