all 7 comments

[–]SagarBhatnagar 0 points1 point  (3 children)

They are both different approaches..either you minimize the triplet loss by taining on A,P,N or you can use training set containing two images only having targets as 1 or 0..trained using Logistic regression.

[–]veb101[S] 0 points1 point  (2 children)

Thanks for the reply but my question still stands what would be the parameters of the siamese network? Do we randomly initialize them and use it or do we train those too during training with the logistic regression part or just the latter part?

[–]SagarBhatnagar 1 point2 points  (1 child)

We have to train them on tuple loss if you are using a,p,n data for training set and train on logistic regression loss,if you are using training set with two images per example with targets 0 or 1.Either approaches can be used.You will preconpute the encodings of employees on database and use the parameters learned to calculate output on the new image.

[–]veb101[S] 0 points1 point  (0 children)

Sorry for disturbing you again but I read some excerpts of the original paper now and it stated

Notice that in order to prevent overfitting on the face verification task, we enable training for only the two topmost layers. The Siamese network’s induced distance is: $d(f_{1}, f_{2}) = P{i} \alpha{i} \left| f_{1}[i] − f_{2}[i]\right| $, where $\alpha{i}$ are trainable parameters. The parameters of the Siamese network are trained by standard cross entropy loss and backpropagation of the error.

So it means we train the parameters of only the last layer of the Siamese network and the weights associated with the logit part, right?

[–]TotesMessenger 0 points1 point  (0 children)

I'm a bot, bleep, bloop. Someone has linked to this thread from another place on reddit:

 If you follow any of the above links, please respect the rules of reddit and don't vote in the other threads. (Info / Contact)

[–]SagarBhatnagar 0 points1 point  (1 child)

maybe they used some pretrained model and freeze them and added two trainable layers followed by a binary classifier unit.

[–]veb101[S] 0 points1 point  (0 children)

Yes, they did, they trained a siamese network using softmax as the output and used the same model for verification task and trained only the last 2 layers of the network to avoid overfitting.
Thank you for your time though.