Is it possible to change scalar to numeric in workspace?

2 Ansichten (letzte 30 Tage)
asaii
asaii am 21 Dez. 2023
Kommentiert: asaii am 21 Dez. 2023
This picture is the scalar that I would like to have converted to a Matrix of arrays (numeric if possible).
Is it possible to change scalar to numeric in workspace?

Akzeptierte Antwort

Chunru
Chunru am 21 Dez. 2023
a = gpuArray(rand(3, 4, 2));
a(:,:,1)
% use gather to convert gpu array to regular array
b = gather(a(:,:,1))

Weitere Antworten (0)

Kategorien

Mehr zu Matrices and Arrays finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by