I have successfully trained a multi label classifier and a multi class classifier, both of the classifiers are using transfer learning(resent50). However, I don't know how to modify the model part to combine this two classifiers in order to achieve the result that this architecture (the architecture of a multi task learning ) can accomplish.
muti label classifiers: there are 15 attributes(labels) in every single input
model=models.resnet50(pretrained=True) for params in model.parameters(): params.requires_grad=False model.fc=nn.Sequential( nn.Linear(2048,15), nn.Sigmoid() )
multi class classifier: there are 10 classes in the multi class classifier
model=models.resnet101(pretrained=True) for params in model.parameters(): params.requires_grad=False model.fc=nn.Linear(2048,10)