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

LayoutLM model cannot import name 'LayoutlmConfig' #1518

Open
qiujiu123 opened this issue Apr 11, 2024 · 0 comments
Open

LayoutLM model cannot import name 'LayoutlmConfig' #1518

qiujiu123 opened this issue Apr 11, 2024 · 0 comments

Comments

@qiujiu123
Copy link

Describe
Model I am using (UniLM, MiniLM, LayoutLM ...):LayoutLM
When i using the code:
python run_seq_labeling.py --data_dir data
--model_type layoutlm
--model_name_or_path path/to/pretrained/model/directory
--do_lower_case
--max_seq_length 512
--do_train
--num_train_epochs 100.0
--logging_steps 10
--save_steps -1
--output_dir path/to/output/directory
--labels data/labels.txt
--per_gpu_train_batch_size 16
--per_gpu_eval_batch_size 16
--fp16
there is a problem :
File "run_seq_labeling.py", line 52, in
from layoutlm import FunsdDataset, LayoutlmConfig, LayoutlmForTokenClassification
ImportError: cannot import name 'LayoutlmConfig'
How to resolve it?

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

No branches or pull requests

1 participant