zjunlp / EasyEdit

[知识编辑] [ACL 2024] An Easy-to-use Knowledge Editing Framework for LLMs.
https://zjunlp.github.io/project/KnowEdit
MIT License
1.63k stars 200 forks source link

error when cache file exist #312

Closed dignfei closed 1 month ago

dignfei commented 1 month ago

image image

when file exists , ds = none ,then error

shell: cd examples python run_zsre_llama2.py --editing_method=MEMIT --hparams_dir=../hparams/MEMIT/llama-7b --data_dir=../dataroot

dignfei commented 1 month ago

What needs to be adjusted?

XeeKee commented 1 month ago

Please ensure that your filename is the correct path. You can print it out to check if the filename is the Wikipedia path.

dignfei commented 1 month ago

filename = PosixPath('data/stats/Llama-2-7b-chat-hf/wikipedia_stats/model.layers.4.mlp.down_proj_float32_mom2_100000.npz') No code or cache files were altered by me. They were created automatically upon successful execution. However, when I run the program again, the error I previously described occurs.

xzwyyd commented 1 month ago

Hello, thank you for your feedback. We will review it thoroughly later and address it promptly. Thank you for your patience.

XeeKee commented 1 month ago

So you mean that you are sure that your ds is not a null value at this location: https://github.com/zjunlp/EasyEdit/blob/4f228d6cd4865facc2cf1cfd3e029e82a2cdc6fb/easyeditor/models/rome/layer_stats.py#L168

zxlzr commented 1 month ago

hi, do you have any further questions?