Skip to content

Commit 46cb516

Browse files
committed
Update auto_batch_size.py
1 parent 10d5a67 commit 46cb516

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

deepmd/pt/utils/auto_batch_size.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@ def is_oom_error(self, e: Exception) -> bool:
5454
or "CUDA driver error: out of memory" in e.args[0]
5555
or "cusolver error: CUSOLVER_STATUS_INTERNAL_ERROR" in e.args[0]
5656
or "CUDA error: CUBLAS_STATUS_INTERNAL_ERROR" in e.args[0]
57+
or "nonzero is not supported for tensors with more than INT_MAX elements"
58+
in e.args[0]
5759
):
5860
# Release all unoccupied cached memory
5961
torch.cuda.empty_cache()

0 commit comments

Comments
 (0)