Hello,
Is there any way for using apply method for only train the last 10 layers?
My current solution is to reversely walk through each layer and set the gradient=True, but I want to see if there is any more clear way to do that? The problem with my own solution is that I have to know the name of blocks of each model fo rexample Resnet has models.resnet.BasicBlock.