YU1ut / imprinted-weights

Code for 'Low-Shot Learning with Imprinted Weights'
68 stars 24 forks source link

About the pre-training #4

Open kikyou123 opened 4 years ago

kikyou123 commented 4 years ago

It seems that you pre-train the model with all the training images, including the base and novel classes. I argue it is unfair to use the novel classes to train the model.

YU1ut commented 4 years ago

No. Only base classes are used in pre-training. https://github.com/YU1ut/imprinted-weights/blob/master/loader.py#L27 And the network only classifies 100 classes. https://github.com/YU1ut/imprinted-weights/blob/master/models.py#L6

blue-blue272 commented 4 years ago

Yes, I understand. Thanks for replying!

blue-blue272 commented 4 years ago

I have another question. When you pretrain the model, you set the train loader as : train_dataset = loader.ImageLoader( args.data, transforms.Compose([ transforms.RandomResizedCrop(224), transforms.RandomHorizontalFlip(), transforms.ToTensor(), normalize, ]), train=True) I argue should you insert the transforms.Resize(256), before transforms.RandomResizedCrop(224),