Because I’m fine-tuning a neural network, I always need change something in the class of network (e.g., activation, neuron number, …). How can I load a trained model without the class of its network structure?
you can save the state_dict()
of a network, and load it back with load_state_dict
. It’s been built for this purpose.