how to calculate hamming distance between 2 binary matrices having size 20 * 512 with a single score value as result.
6 ビュー (過去 30 日間)
古いコメントを表示
i have 2 binary matrices with 0's and 1's of size 20 * 512... i want to compute hamming distance between them..and the result should be a single score value..
0 件のコメント
回答 (1 件)
Image Analyst
2018 年 5 月 28 日
If they are truly binary matrices of type logical, then you can use xor() to see which pixels are different, and then count them with sum() or nnz():
numberOfMismatches = nnz(xor(BW1, BW2))
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Hamming についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!