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

我使用多线程启动ppstructure+ocr处理任务(具体起了两个线程),运行时报错PreconditionNotMetError: Tensor's dimension is out of bound.,单线程运行没问题 #64248

Open
binfox1 opened this issue May 13, 2024 · 2 comments
Assignees
Labels

Comments

@binfox1
Copy link

binfox1 commented May 13, 2024

请提出你的问题 Please ask your question

完整报错:
PreconditionNotMetError: Tensor's dimension is out of bound.Tensor's dimension must be equal or less than the size of its memory.But received Tensor's dimension is 7741440, memory's size is 7004160.
[Hint: Expected numel() * SizeOf(dtype()) <= memory_size(), but received numel() * SizeOf(dtype()):7741440 > memory_size():7004160.] (at /paddle/paddle/phi/core/dense_tensor_impl.cc:55)
[operator < fused_conv2d > error]

@cxxly
Copy link
Contributor

cxxly commented May 14, 2024

您好,麻烦补充下飞桨版本号,复现代码;

@cxxly
Copy link
Contributor

cxxly commented May 14, 2024

另外,请教下为什么会有这种诉求,是想提升推理服务并发度吗,部署多个服务,启多个进程是不是更合适。两个线程运行同一份数据和模型,如果没做好线程间同步和互斥机制,问题会比较大,而且并没有真正高并发。

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

No branches or pull requests

2 participants