What is the difference between feature and classifier?
I saw code like this

self.feature = model_func()
if loss_type == 'softmax':
    self.classifier = nn.Linear(self.feature.final_feat_dim, num_class)
    self.classifier.bias.data.fill_(0)
elif loss_type == 'dist': #Baseline ++
    self.classifier = backbone.distLinear(self.feature.final_feat_dim, num_class)


where model_func is a ConvNet 4/6 or ResNet 10/18/34/101

What here is classifier?

I know that in neural networks we have parameters that we learn, buffers that are used to store something that gets updated during training, activations that are the results after each layer.

Is feature same as activation, and what is a classifier, where is the end of features, and the beginning of classifier in a neural network? Is the result of a classifier also activation?

I find the question a little messy, but I'll give my best from what I understand you're asking.


  What here is classifier?


The classifier would be the model itself. The model is the one who will, after being trained, be able to classify new data. 


  Is feature same as activation


I don't know what kind of feature you have in mind. In data science context, a feature is understood to be one of the variables of the data one has. For example, if you have a dataset about houses, you may have features such as latitude, long., if it has a pool, how many bedrooms it has, etc.

Activation functions are mathematical equations that determine the output of a neural network. The function is attached to each neuron in the network, and determines whether it should be activated (“fired”) or not, based on whether each neuron’s input is relevant for the model’s prediction. [1]

I'm not sure I'm truly understanding what you're asking. 


  Is the result of a classifier also activation?


The result of a classifier is the label, the class to which each data point belongs. Activation functions are used by neural networks in the process of classifying.



Hope this helps!

[1] https://missinglink.ai/guides/neural-network-concepts/7-types-neural-network-activation-functions-right/
