When the input is gpuArray for bitxor function I get this error. How I solve it?
古いコメントを表示
When the input is gpuArray for bitxor function I get this error. How I solve it?

9 件のコメント
KALYAN ACHARJYA
2020 年 12 月 13 日
>>whos X1
>>whos X2
Please provide?
amenah mwuafaq
2020 年 12 月 13 日
Walter Roberson
2020 年 12 月 13 日
Well those are both clearly datatype double(), and bitxor() requires that at least one of the two inputs be an integer class (the other can be either the same integer class or can be a scalar double.)
We do not know what range Packet and Packet2 are so we cannot guess which value range X1 and X2 are.
amenah mwuafaq
2020 年 12 月 16 日
Walter Roberson
2020 年 12 月 16 日
It looks like GFin is probably 16. In that case, when you take the x property of the gf() result, you are going to get uint32() of the result of the randi() . What is the purpose of going through the gf() step ?
Is it correct that class(videoFrames) is uint8 ?
It looks to me as if you are effectively working with 12 bit integers? uint8 video data, times random value that is up to 16, so maximum 4080 ?
amenah mwuafaq
2020 年 12 月 17 日
Walter Roberson
2020 年 12 月 17 日
What difference do you observe between selecting random numbers from gf and selecting random integers with the same maximum?
amenah mwuafaq
2020 年 12 月 17 日
Walter Roberson
2020 年 12 月 18 日
How do you propose to choose random numbers from a gf?
If you have an array named data that is nonnegative integers in the range 0 to 255, and you have
g = gf(data, 8)
Now you want to pick a random element from g
idx = randi(numel(g))
rg = g(idx)
rgfd = gf(data(idx), 8)
Are you expecting that rg and rgfd would be different?
回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Linear Algebra についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!