cuda: set compute parameters via command line arguments

This commit is contained in:
Iwan Kawrakow
2025-11-06 15:55:44 +02:00
parent 575e2c2821
commit ccabf5713d
10 changed files with 127 additions and 29 deletions

View File

@@ -66,7 +66,7 @@ struct pca_model {
pca_model(struct ggml_tensor * t_input) {
#ifdef GGML_USE_CUDA
fprintf(stderr, "%s: using CUDA backend\n", __func__);
backend = ggml_backend_cuda_init(0); // init device 0
backend = ggml_backend_cuda_init(0, nullptr); // init device 0
if (!backend) {
fprintf(stderr, "%s: ggml_backend_cuda_init() failed\n", __func__);
}