(self, name='resnet50', head='linear', feat_dim=128)
| 141 | class CMCMultiHeads(CMCSingleHead): |
| 142 | """CMC model with Multiple linear/mlp projection heads""" |
| 143 | def __init__(self, name='resnet50', head='linear', feat_dim=128): |
| 144 | super(CMCMultiHeads, self).__init__(name, head, feat_dim) |
| 145 | |
| 146 | self.head1_jig = JigsawHead(dim_in=int(2048*self.width), |
| 147 | dim_out=feat_dim, |
| 148 | head=head) |
| 149 | self.head2_jig = JigsawHead(dim_in=int(2048*self.width), |
| 150 | dim_out=feat_dim, |
| 151 | head=head) |
| 152 | |
| 153 | def forward(self, x, x_jig=None, mode=0): |
| 154 | # mode -- |
nothing calls this directly
no test coverage detected