temporary fix bug of 0 size tensor (#4844)

This commit is contained in:
RAM
2025-11-06 14:20:59 +08:00
committed by GitHub
parent eac823aec8
commit 93aedaf23e
+4
View File
@@ -2016,6 +2016,10 @@ class GPUModelRunner(ModelRunnerBase):
if not self.not_need_stop():
self._execute_empty_input()
return None
# TODO: Fix ORC 0 size bug
if self.forward_meta.ids_remove_padding.shape[0] == 0:
self.share_inputs["not_need_stop"].zero_()
return None
# 2. Padding inputs for cuda graph
self.padding_cudagraph_inputs()