OpenNMT / OpenNMT/CTranslate2

Python process crashes on exit under Windows with CUDA

Open
#1,782 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
4.7k
Forks
536
Avg merge
12h 12m
Merged PRs (30d)
4

Description

I am using Windows 10 with CUDA 11.8, Python 3.10 and ctranslate2 4.4.0.
The problem already seems to reported in the faster-whisper repo but I also have it when I directly use ctranslate2:
https://github.com/SYSTRAN/faster-whisper/issues/71

The python process crashes after executing this code:

import ctranslate2
model = ctranslate2.models.Whisper("openai/whisper-tiny", device="cuda")

It is not the the code itself that crashes the process but I guess some kind of internal routine on process exit that is necessary for CUDA.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the crash with the shown ctranslate2.models.Whisper example on Windows 10 with CUDA 11.8 and Python 3.10, then compare the behavior with the linked faster-whisper issue. Done means the Python process exits normally after creating the CUDA-backed model, with the relevant exit-time behavior covered by a regression test.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, python
Domain
machine-learning, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.