Apply adaptation layers. # here is list of three levels of features
(self, features: List[torch.tensor])
| 171 | self.add_module("adapt_layer_{}".format(i), layer) # ex: adapt_layer_0 |
| 172 | |
| 173 | def forward(self, features: List[torch.tensor]): |
| 174 | """Apply adaptation layers. # here is list of three levels of features |
| 175 | """ |
| 176 | |
| 177 | for i, _ in enumerate(features): |
| 178 | features[i] = getattr(self, "adapt_layer_{}".format(i))(features[i]) |
| 179 | return features |
| 180 | |
| 181 | class EfficientNetB0(nn.Module): |
| 182 | ''' DFNet with EB0 backbone, feature levels can be customized ''' |
nothing calls this directly
no outgoing calls
no test coverage detected