Hi, thank you for your answer. I am using VoxCeleb 1 as my dataset and it contains 138361 files for training, 8251 for test and 6904 files for validation. There are 1251 speakers to be identified. I was using till now optim.SGD as my optimizer, now I’m trying optim.Adam. It is a bit better but I’m still not having results. Could ypu please give me an simple example how to increase dropout?
I have changed my model again:
class Resnet_Speaker_Recognition(nn.Module):
def init(self):
super(Resnet_Speaker_Recognition, self).init()
    self.resnet_model = models.resnet18(pretrained=True)
    self.resnet_model.conv1 = torch.nn.Conv2d(1, 64, kernel_size=(7,7), stride=(2,2), padding=(3,3), bias=False)
    self.num_ftrs = self.resnet_model.fc.in_features
    self.resnet_model.fc = nn.Linear(self.num_ftrs, 1251)

def forward(self,x):

    x = self.resnet_model(x)
    return x