Closed llearner closed 4 years ago
that's the last classifier layer, the weights there is not included.
What you can do is, loading the model with strict = False, and the last layer (classifier) will then be randomly initialised.
that's the last classifier layer, the weights there is not included.
What you can do is, loading the model with strict = False, and the last layer (classifier) will then be randomly initialised.
You mean the softmax layer or the layer after softmax layer? The network mode is "train", and load_weights attribute "by_name" is True. For the softmax(prediction) layer, it seems the number of params is 512*5994.
oh, yes, you are right, so, where does this 19,136 come from ? do you know which layer ? This code has been quite a long time.... So I can't remember that well..
Hi, Weidi, when I load pretrained model, it occurs "Non-trainable params: 19,136". I try to find layers which trainable=False, but I didn't find it. Can you give me some guidance? And whether it influnce finetune result or not?