Search code examples
machine-learningdeep-learningloss-functionfaster-rcnn

How to create a loss plot from loaded weights? (model.load_weights) How to add model.load_weights to history?


I would like to create a loss. (plot) I use Mask-RCNN. I loaded a weights from my model. But I can't create a loss function. I got error: 'Model' object has no attribute 'history'

model = modellib.MaskRCNN(mode="training",
                          config=config,
                          model_dir=ROOT_DIR)

model.load_weights('/my/path/to/mask_rcnn_0007.h5', by_name=True)
model.load_weights(''/my/path/to/mask_rcnn_0008.h5'', by_name=True)
model.load_weights(''/my/path/to/mask_rcnn_0009.h5'', by_name=True)
model.load_weights(''/my/path/to/mask_rcnn_0010.h5'', by_name=True)
model.load_weights(''/my/path/to/mask_rcnn_0011.h5'.h5', by_name=True)


history = model.keras_model.history.history

Solution

  • you can use tensorboard

    $ tensorboard --logdir logs/

    logs/ -->use your folder where you save your .h5 files

    you should see something like this in your browser, using https://127.0.0.1:6006/ .

    tensorboard