Hi
I trained my own model while using the pre-trained Imagenet model. Now, I have trouble understanding how my model is loaded for inference? Is first the model found in OUTPUT_DIR loaded and then the one from MODEL.WEIGHT ?
save_dir = cfg.OUTPUT_DIR
checkpointer = DetectronCheckpointer(cfg, self.model, save_dir=save_dir)
_ = checkpointer.load(cfg.MODEL.WEIGHT)
Thanks in advance
If there is a last_checkpoint file in OUTPUT_DIR, it will take the file present there.
If there isn't any file named last_checkpoint in OUTPUT_DIR, it will load the weights from MODEL.WEIGHT.
If there is a
last_checkpointfile inOUTPUT_DIR, it will take the file present there.
If there isn't any file namedlast_checkpointinOUTPUT_DIR, it will load the weights fromMODEL.WEIGHT.
if I just write,
save_dir= cfg.OUTPUT_DIR
checkpointer = DetectronCheckpointer(cfg, self.model, save_dir=save_dir)
If there isn't any file named last_checkpoint in OUTPUT_DIR, it will start from the scratch, right?
Most helpful comment
If there is a
last_checkpointfile inOUTPUT_DIR, it will take the file present there.If there isn't any file named
last_checkpointinOUTPUT_DIR, it will load the weights fromMODEL.WEIGHT.