adambielski / siamese-triplet

Siamese and triplet networks with online pair/triplet mining in PyTorch
BSD 3-Clause "New" or "Revised" License
3.1k stars 633 forks source link

Extract features from images - Triplet Model #34

Closed josianerodrigues closed 5 years ago

josianerodrigues commented 5 years ago

Hi @adambielski,

I need to do some testing with the triplet model. My experiments consist of extracting features for each image in the test dataset and using these features for the task of image retrieval. I'm saving the trained model, but I'm not able to load to extract the features of each image because the model is trained for a triplet format input. Some idea?

adambielski commented 5 years ago

@josianerodrigues That's what get_embedding method in TripletNet is for https://github.com/adambielski/siamese-triplet/blob/master/networks.py#L86 It's also used in the notebook as an example

josianerodrigues commented 5 years ago

Thank you :)