How to exclude Embeddings when saving a model

How can I save trained Pyrotch excluding embeddings level (in NLP task) which takes most of the place. I want to recreate this level during inference stage and do not want to save it with the model.

I think you could just pop embedding matrix out of model.state_dict() and put it back in for inference.