PyABSA icon indicating copy to clipboard operation
PyABSA copied to clipboard

Fail to load the model from ./checkpoints/ATEPC_ENGLISH_CHECKPOINT!

Open khorg0sh opened this issue 1 year ago • 6 comments

I'm using Google Colab. As was suggested, the version was downgraded to 1.16.27. I get the following error while loading the model :

RuntimeError: Exception: Error(s) in loading state_dict for FAST_LCF_ATEPC: Unexpected key(s) in state_dict: "bert4global.embeddings.position_ids". Fail to load the model from ./checkpoints/ATEPC_ENGLISH_CHECKPOINT!

Thanks in advance.

khorg0sh avatar Jul 23 '23 04:07 khorg0sh

freeze transformers==4.29.0

yangheng95 avatar Jul 23 '23 11:07 yangheng95

I am having same issue, freezing is also not working and all pyabsa versions. Please help me to fix that. @yangheng95

ImSanjayChintha avatar Aug 01 '23 12:08 ImSanjayChintha

I am having same issue, freezing is also not working and all pyabsa versions. Please help me to fix that. @yangheng95

Hi! Please report your problem in details: https://github.com/yangheng95/PyABSA/issues/new?assignees=&labels=&projects=&template=bug_report.md&title=

yangheng95 avatar Aug 01 '23 12:08 yangheng95

Below installations are worked for me

!pip install pyabsa==1.16.24 !pip install transformers==4.29.0

ImSanjayChintha avatar Aug 01 '23 18:08 ImSanjayChintha

I think you need to update your code to compatible with new version transformers.

SupritYoung avatar Sep 15 '23 11:09 SupritYoung

I think you need to update your code to compatible with new version transformers.

Hi, are you using v1.x?

yangheng95 avatar Sep 15 '23 12:09 yangheng95