Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError: bad marshal data #87

Closed
YanZhangADS opened this issue Dec 5, 2022 · 1 comment · Fixed by #86
Closed

ValueError: bad marshal data #87

YanZhangADS opened this issue Dec 5, 2022 · 1 comment · Fixed by #86
Milestone

Comments

@YanZhangADS
Copy link

YanZhangADS commented Dec 5, 2022

I am using Ubuntu 20.04 Linux

conda create -n eynollah -y python=3.8
conda activate eynollah
// in eynollah's directory
pip install -e .
make models

// execute following command generates "ValueError: bad marshal data"
eynollah -i data/input/1.jpg -o data/output -m models_eynollah

Full error messages is below.

Traceback (most recent call last):
File "/anaconda/envs/eynollah/bin/eynollah", line 33, in
sys.exit(load_entry_point('eynollah', 'console_scripts', 'eynollah')())
File "/anaconda/envs/eynollah/lib/python3.8/site-packages/click/core.py", line 1130, in call
return self.main(*args, **kwargs)
File "/anaconda/envs/eynollah/lib/python3.8/site-packages/click/core.py", line 1055, in main
rv = self.invoke(ctx)
File "/anaconda/envs/eynollah/lib/python3.8/site-packages/click/core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/anaconda/envs/eynollah/lib/python3.8/site-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "/home/mylogin/notebooks/eynollah/qurator/eynollah/cli.py", line 151, in main
pcgts = eynollah.run()
File "/home/mylogin/notebooks/eynollah/qurator/eynollah/eynollah.py", line 2307, in run
img_res, is_image_enhanced, num_col_classifier, num_column_is_classified = self.run_enhancement()
File "/home/mylogin/notebooks/eynollah/qurator/eynollah/eynollah.py", line 1990, in run_enhancement
is_image_enhanced, img_org, img_res, num_col_classifier, num_column_is_classified, img_bin = self.resize_and_enhance_image_with_column_classifier()
File "/home/mylogin/notebooks/eynollah/qurator/eynollah/eynollah.py", line 408, in resize_and_enhance_image_with_column_classifier
_, page_coord = self.early_page_for_num_of_column_classification(img_bin)
File "/home/mylogin/notebooks/eynollah/qurator/eynollah/eynollah.py", line 648, in early_page_for_num_of_column_classification
model_page, session_page = self.start_new_session_and_model(self.model_page_dir)
File "/home/mylogin/notebooks/eynollah/qurator/eynollah/eynollah.py", line 518, in start_new_session_and_model
model = load_model(model_dir, compile=False)
File "/anaconda/envs/eynollah/lib/python3.8/site-packages/keras/utils/traceback_utils.py", line 70, in error_handler
raise e.with_traceback(filtered_tb) from None
File "/anaconda/envs/eynollah/lib/python3.8/site-packages/keras/utils/generic_utils.py", line 103, in func_load
code = marshal.loads(raw_code)
ValueError: bad marshal data (unknown type code)

@bertsky
Copy link
Contributor

bertsky commented Feb 9, 2023

I am also hitting this. Looks like a similar problem we countered with sbb_binarization. But it's strange this occurs on 3.8 already.

Anyway, I propose we switch to SavedModel format quickly. Did anyone already publish something?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants