mirror of
https://github.com/mudler/LocalAI.git
synced 2026-02-28 04:40:15 -05:00
fix: whisper breaking on cuda-13 (use absolute path for CUDA directory detection) (#8678)
fix: use absolute path for CUDA directory detection The capability detection was using a relative path 'usr/local/cuda-13' which doesn't work when LocalAI is run from a different working directory. This caused whisper (and other backends) to fail on CUDA-13 containers because the system incorrectly detected 'nvidia' capability instead of 'nvidia-cuda-13', leading to wrong backend selection (cuda12-whisper instead of cuda13-whisper). Fixes: https://github.com/mudler/LocalAI/issues/8033 Co-authored-by: localai-bot <localai-bot@users.noreply.github.com>
This commit is contained in:
@@ -50,9 +50,9 @@ var (
|
||||
)
|
||||
|
||||
func init() {
|
||||
_, err := os.Stat(filepath.Join("usr", "local", "cuda-13"))
|
||||
_, err := os.Stat(filepath.Join(string(os.PathSeparator), "usr", "local", "cuda-13"))
|
||||
cuda13DirExists = err == nil
|
||||
_, err = os.Stat(filepath.Join("usr", "local", "cuda-12"))
|
||||
_, err = os.Stat(filepath.Join(string(os.PathSeparator), "usr", "local", "cuda-12"))
|
||||
cuda12DirExists = err == nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user