Not matching parameters for structure-recognition.
#8
by
Mauricio-Physics
- opened
Hi, I wanted to ask you the following:
- I did the pretraining of the structure recognition following the instructions in the repository, I tried to update the parameters of the model doing this:
model = TableTransformerForObjectDetection.from_pretrained("microsoft/table-transformer-structure-recognition")
model_keys = list(model.state_dict().keys())
checkpoint = torch.load("model.pth", map_location=torch.device('cpu'))
but there was a warning, none of the parameters name matched, am I doing it wrong ? what is the right way ?
- To extract the information of the tables, Do I have to use the inference script in the repo ?
Thanks a lot !
model = TableTransformerForObjectDetection.from_pretrained("microsoft/table-transformer-structure-recognition")
checkpoint = torch.load("TATR-v1.1-All-msft.pth", map_location=torch.device('cpu'))
model.load_state_dict(checkpoint)
RuntimeError: Error(s) in loading state_dict for TableTransformerForObjectDetection:
Missing key(s) in state_dict: "model.backbone.conv_encoder.model.embedder.embedder.convolution.weight", "model.backbone.conv_encoder.model.embedder.embedder.normalization.weight", ..........
@nielsr I would really appreciate your help you don't know how much <3