PaddleNLP taskflow和fastdeploy放在一起会产生中断,是怎么回事呢?

sulc1iza  于 2个月前  发布在  其他
关注(0)|答案(5)|浏览(43)

请提出你的问题

我使用Taskflow和fastdeploy.text放在一起运行会报错如下:
I0524 16:09:00.122905 1214780 gpu_info.cc:225] [cudaMalloc] size=0.1875 MB, result=0
I0524 16:09:00.122918 1214780 stats.h:78] HostMemoryStatAllocated0: Update current_value with -196608, after update, current value = 256
I0524 16:09:00.122920 1214780 stats.h:78] HostMemoryStatReserved0: Update current_value with -196608, after update, current value = 256
I0524 16:09:00.122924 1214780 stats.h:78] HostMemoryStatReserved0: Update current_value with 256, after update, current value = 512
I0524 16:09:00.122926 1214780 stats.h:78] HostMemoryStatAllocated0: Update current_value with 256, after update, current value = 512
I0524 16:09:00.122929 1214780 stats.h:78] HostMemoryStatAllocated0: Update current_value with -256, after update, current value = 256
I0524 16:09:00.122931 1214780 stats.h:78] HostMemoryStatReserved0: Update current_value with -256, after update, current value = 256
I0524 16:09:00.122936 1214780 gpu_info.cc:225] [cudaMalloc] size=0.000244141 MB, result=0
I0524 16:09:00.122956 1214780 stats.h:78] HostMemoryStatAllocated0: Update current_value with -256, after update, current value = 0
I0524 16:09:00.122957 1214780 stats.h:78] HostMemoryStatReserved0: Update current_value with -256, after update, current value = 0
[INFO] fastdeploy/runtime/backends/paddle/paddle_backend.cc(29)::BuildOption Will inference_precision float32
Segmentation fault (core dumped)

hmmo2u0o

hmmo2u0o1#

请直接参考fastdeploy的uie的适配步骤,目前人力有限,UIE的相关技术停止更新,欢迎开发者继续贡献。

kyks70gy

kyks70gy2#

从您提供的代码和错误信息来看,问题可能出在GPU内存分配上。在这种情况下,建议您尝试以下方法:

  1. 检查您的模型是否适用于GPU。确保您的模型已经迁移到GPU上,并且支持CUDA。

  2. 检查您的输入数据是否正确。确保输入数据的类型和形状与模型期望的输入相匹配。

  3. 尝试减小批量大小。较小的批量大小可能会减少内存使用和计算量,从而降低出现错误的可能性。

  4. 更新PyTorch和相关依赖库。确保您使用的是最新版本的PyTorch和相关依赖库,以避免因版本不兼容导致的问题。

  5. 如果问题仍然存在,您可以尝试在其他计算机或设备上运行相同的代码,以排除硬件问题。

8xiog9wr

8xiog9wr4#

UIE和UTC已经停止更新,欢迎开发者贡献和完善。另外推荐使用大模型的解决方案。

iyr7buue

iyr7buue5#

https://github.com/PaddlePaddle/PaddleNLP/blob/develop/applications/zero_shot_text_classification/deploy/python/README.md
我这里使用的是UTC出现问题,不是UIE,难道UTC也停止更新维护了吗
请问这个问题解决了吗

相关问题