Skip to content

Cannot load the fine-tuned ckpt #51

@hlzhang109

Description

@hlzhang109
Unexpected key(s) in state_dict: "head.weight", "head.bias", "fc_norm.weight", "fc_norm.bias". 
size mismatch for pos_embed: copying a param with shape torch.Size([1, 197, 1024]) from checkpoint, the shape in current model is torch.Size([1, 257, 1024]).
checkpoint = torch.load(ckpt_path, map_location='cpu')
model.load_state_dict(checkpoint['model'])

I am loading the mage-vitl-ft.pth but didn't work. do we need conversion scripts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions