필터 지우기
필터 지우기

"Maximum variable size allowed on the device is exceeded" error when using internal.s​tats.gpu.p​dist2?

조회 수: 12 (최근 30일)
Hello, I hope you are well. I'm encountering an issue with the pdist2 function on my GPUs. I have both an A6000 with 40 GB of memory and an A100 with 80 GB of memory,
load('Dataset_1.mat')
X=single(Dataset(:,[2 4]));
X_CPU = X(1:60000,:);
X_GPU = gpuArray(X_CPU); % Convert data to gpuArray
% Compute pairwise distances more efficiently
D = pdist2(X_GPU, X_GPU, 'squaredeuclidean');
but I'm getting the same error on both devices. the error as shown below
Error using internal.stats.gpu.pdist2 Maximum variable size allowed on the device is exceeded.
Error in gpuArray/pdist2 (line 262) [doTranspose,D] = internal.stats.gpu.pdist2(X.',Y.',dist,additionalArg,smallestLargestFlag,d.AvailableMemory);
How can I solve this error?

답변 (0개)

카테고리

Help CenterFile Exchange에서 Get Started with GPU Coder에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by