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?

 採用された回答

Chunru
Chunru 2023 年 12 月 21 日

0 投票

a = gpuArray(rand(3, 4, 2));
a(:,:,1)
% use gather to convert gpu array to regular array
b = gather(a(:,:,1))

1 件のコメント

asaii
asaii 2023 年 12 月 21 日
Thank you.You have helped me solve this problem.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Programming についてさらに検索

タグ

質問済み:

2023 年 12 月 21 日

コメント済み:

2023 年 12 月 21 日

Community Treasure Hunt

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

Start Hunting!

Translated by