You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, i have trained the DeepLab model on my custom dataset. I'm able to load these saved weights inside the model architecture.
And now, I am trying to save this architecture with its loaded weights into a single .h5 file. However, when i do this i get error
RecursionError: maximum recursion depth exceeded while calling a Python object
Following is the code i'm using,
from utils import *
backbone = 'mobilenetv2'
n_classes=2
image_size=(512,512)
SegClass = SegModel(image_size=image_size)
model1 = SegClass.create_seg_model(net='original',n=n_classes, load_weights=False, multi_gpu=False, backbone=backbone)
model1.load_weights('weights/Saved_Weights-02.h5')
model1.save('Complete_Model.h5')
Im getting the RecursionError when the last line model1.save('Complete_Model.h5') is executed.
How can i resolve this issue such that both the 'model architecture' as well as its 'weights' are stored inside a single file.
The text was updated successfully, but these errors were encountered:
Hi, i have trained the DeepLab model on my custom dataset. I'm able to load these saved weights inside the model architecture.
And now, I am trying to save this architecture with its loaded weights into a single .h5 file. However, when i do this i get error
RecursionError: maximum recursion depth exceeded while calling a Python object
Following is the code i'm using,
from utils import *
backbone = 'mobilenetv2'
n_classes=2
image_size=(512,512)
SegClass = SegModel(image_size=image_size)
model1 = SegClass.create_seg_model(net='original',n=n_classes, load_weights=False, multi_gpu=False, backbone=backbone)
model1.load_weights('weights/Saved_Weights-02.h5')
model1.save('Complete_Model.h5')
Im getting the RecursionError when the last line model1.save('Complete_Model.h5') is executed.
How can i resolve this issue such that both the 'model architecture' as well as its 'weights' are stored inside a single file.
The text was updated successfully, but these errors were encountered: