How do I save a model, using Huggingface, after adding tensorflow layers to it. I am able to save it using native tensorflow, but not Huggingface. Specifially, I am using “model = TFBertModel.from_pretrained(‘bert-base-cased’)”, and then adding a few layers to it. After I add the layers it is no longer saveable using transformers. I get the error “AttributeError: ‘Functional’ object has no attribute ‘save_model’”. Please help.
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
Saving custom and/or finetuned models without the HUB | 3 | 1058 | March 2, 2022 | |
Save a tensorflow model with a transformer layer | 0 | 1653 | January 21, 2022 | |
Error messages when trying to use save_pretrained and load from_pretrained | 0 | 1012 | April 8, 2023 | |
How to save my model to use it later | 17 | 177413 | July 28, 2025 | |
Can't save my finetuned model | 5 | 286 | November 9, 2024 |