COLA-Laboratory / issta2020

This repository contains materials related to our DeepSQLi paper published in ISSTA 2020.
GNU General Public License v3.0
15 stars 9 forks source link

trained.chkpt file broken. #4

Closed UnnameBao closed 3 years ago

UnnameBao commented 3 years ago

When I run main.py file as it run into \transformer\Translator.py file in line 17 it rasie an error:

Traceback (most recent call last): File ".\main.py", line 77, in parse() File ".\main.py", line 49, in parse payload = generator('./model/trained.chkpt', "./dataset/tc.csv" ,input) File "C:\Users\A\Desktop\WorkingSpace\project\issta2020\generator.py", line 88, in generator translator = Translator(opt) File "C:\Users\A\Desktop\WorkingSpace\project\issta2020\transformer\Translator.py", line 18, in init checkpoint = torch.load(opt.model) File "C:\Users\A\anaconda3\lib\site-packages\torch\serialization.py", line 593, in load return _legacy_load(opened_file, map_location, pickle_module, pickle_load_args) File "C:\Users\A\anaconda3\lib\site-packages\torch\serialization.py", line 762, in _legacy_load magic_number = pickle_module.load(f, pickle_load_args) _pickle.UnpicklingError: could not find MARK

I tried python 2.7, python 3.4 ~ python 3.8, all version python could not load this pickle file.

Ying091909 commented 2 years ago

hello, I met the same problem. And how did you solve it?