-
Notifications
You must be signed in to change notification settings - Fork 7.9k
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: (InvalidArgument) x dim number should greater than 0, but received value is: 0 [Hint: Expected x_dim > 0, but received x_dim:0 <= 0:0.] #11261
Comments
i followed the RE instruction in kie document and got this problem |
I am also facing the same issue in some documents... |
also |
@danghoangnhan 问题解决了吗,我也遇到这样的类似错了 |
Got the same error, do we have any update on this issue? |
same error when training RE models |
PaddleOCR/ppocr/data/imaug/vqa/token/vqa_token_relation.py Lines 35 to 49 in 0525f6b
Bug found, when building relations in dataloader, labels of entity are limited to "question" and "answer", custom dataset with other labels will be ignored and no relations built. I modified it into:
there is a try-except because sometimes And still there will be (very) few invalid batches, I add a try-except in this for loop, the model starts training: Line 269 in 0525f6b
|
同样的问题,训练的时候修改vqa_token_relation.py后可以了,但是预测的时候依然报错,完整的错误信息如下: Traceback (most recent call last): |
训练re模型的时候我也遇到这个问题,最后解决是通过修改数据集的label的顺序解决的。我是将question排在answer前面,就是对label排个序。我猜测是要保证linking=[[a,b]]的a需要放在b的前面。最后数据集长这样:[{id:1, linking:[[1, 2]]},{id:2, linking:[[1, 2]]}],而不能[{id:2, linking:[[1, 2]]}, {id:1, linking:[[1, 2]]}] |
Is there any news , i am still struggling with this issue in the prediction . |
你好,请问方便提供带linking的1-2条数据集,我想参考一下 |
你好,请问你解决这个问题了吗? |
same error, how did you fix this? |
我也遇到了这个问题,请问怎么解决的? |
Hi everyone, for this problem, I used several tricks to fix the IDs:
Hope it helps! |
If you're using a custom recognition model and have updated the dictionary, the model may still use the default dictionary. To apply your changes, you need to update the dictionary directory manually. python3 predict_kie_token_ser_re.py --rec_char_dict_path=../../dict/custom_dict.txt this line will not work that's why the error happens change dict path manually. |
请提供下述完整信息以便快速定位问题/Please provide the following information to quickly locate the problem
aiohttp==3.8.6
aiosignal==1.3.1
annotated-types==0.6.0
anyio==3.7.1
astor==0.8.1
async-timeout==4.0.3
attrdict==2.0.1
attrs==23.1.0
Babel==2.13.1
bce-python-sdk==0.8.96
blinker==1.7.0
cachetools==5.3.2
certifi==2023.7.22
charset-normalizer==3.3.2
click==8.1.7
colorama==0.4.6
colorlog==6.7.0
contourpy==1.1.1
cssselect==1.2.0
cssutils==2.9.0
cycler==0.12.1
Cython==3.0.5
datasets==2.14.7
decorator==5.1.1
dill==0.3.4
et-xmlfile==1.1.0
exceptiongroup==1.1.3
fastapi==0.104.1
filelock==3.13.1
flask==3.0.0
Flask-Babel==2.0.0
fonttools==4.44.0
frozenlist==1.4.0
fsspec==2023.10.0
future==0.18.3
h11==0.14.0
httpcore==1.0.2
httpx==0.25.1
huggingface-hub==0.19.3
idna==3.4
imageio==2.32.0
imgaug==0.4.0
importlib-metadata==6.8.0
importlib-resources==6.1.1
itsdangerous==2.1.2
jieba==0.42.1
Jinja==23.1.2
joblib==1.3.2
kiwisolver==1.4.5
lazy-loader==0.3
lmdb==1.4.1
lxml==4.9.3
markdown-it-py==3.0.0
MarkupSafe==2.1.3
matplotlib==3.7.3
mdurl==0.1.2
multidict==6.0.4
multiprocess==0.70.12.2
networkx==3.1
numpy==1.24.4
onnx==1.15.0
opencv-contrib-python==4.6.0.66
opencv-python==4.6.0.66
openpyxl==3.1.2
opt-einsum==3.3.0
packaging==23.2
paddle2onnx==1.1.0
paddlefsl==1.1.0
paddlenlp==2.5.2
paddlepaddle-gpu==2.5.2
pandas==2.0.3
Pillow==10.1.0
pip==20.0.2
pkg-resources==0.0.0
premailer==3.10.0
protobuf==3.20.2
psutil==5.9.6
pyarrow==14.0.1
pyarrow-hotfix==0.5
pyclipper==1.3.0.post5
pycryptodome==3.19.0
pydantic==2.5.1
pydantic-core==2.14.3
Pygments==2.16.1
PyMuPDF==1.20.2
pypandoc==1.12
pyparsing==3.1.1
python-dateutil==2.8.2
python-docx==1.1.0
pytz==2023.3.post1
PyWavelets==1.4.1
PyYAML==6.0.1
rapidfuzz==3.5.2
rarfile==4.1
requests==2.31.0
rich==13.7.0
safetensors==0.4.0
scikit-image==0.21.0
scikit-learn==1.3.2
scipy==1.10.1
sentencepiece==0.1.99
seqeval==1.2.2
setuptools==44.0.0
shapely==2.0.2
six==1.16.0
sniffio==1.3.0
starlette==0.27.0
threadpoolctl==3.2.0
tifffile==2023.7.10
tqdm==4.66.1
typer==0.9.0
typing-extensions==4.8.0
tzdata==2023.3
urllib==32.1.0
uvicorn==0.24.0.post1
visualdl==2.5.3
werkzeug==3.0.1
wheel==0.34.2
xxhash==3.4.1
yacs==0.1.8
yarl==1.9.2
zipp==3.17.0
The text was updated successfully, but these errors were encountered: