(self, x, bboxes=None)
| 205 | self.post_act = head_act |
| 206 | |
| 207 | def forward(self, x, bboxes=None): |
| 208 | x = x[0] |
| 209 | x = self.model(x) |
| 210 | if self.detection_mode: |
| 211 | x = self.detection_head(x, bboxes) |
| 212 | x = self.post_act(x) |
| 213 | else: |
| 214 | # Performs fully convlutional inference. |
| 215 | if not self.training: |
| 216 | x = self.post_act(x) |
| 217 | x = x.mean([2, 3, 4]) |
| 218 | x = x.view(x.shape[0], -1) |
| 219 | return x |
| 220 | |
| 221 | |
| 222 | @MODEL_REGISTRY.register() |
nothing calls this directly
no outgoing calls
no test coverage detected