Hamming code on image

19 ビュー (過去 30 日間)
Neeraj Chimwal
Neeraj Chimwal 2021 年 4 月 1 日
回答済み: Abhishek Kolla 2021 年 8 月 17 日
Hi
I want to use hamming ecode/decode function on an image.
I chosee pout.tif image and converted it to binary using im2bw(image).
Now I don't know what coding ratio to chose for encode(image,n,k).
Can anyone please help

回答 (2 件)

Aayush Gupta
Aayush Gupta 2021 年 6 月 13 日
Try Reading the image into workspace using imread funtion. After reading the image, convert it into a gray scale image. Then convert it into binary image using dec2bin function, Then convert it to double format from uint8 using imdouble. After this, you will have image in the form of binary bits and can apply "encode(data,n,k,'hamming/binary')" function to apply hamming encoder.

Abhishek Kolla
Abhishek Kolla 2021 年 8 月 17 日
The coding ratio (n,k) can be taken for every integer m greater than or equal to two. The formula's for calculating n and k can be found Block encoder - MATLAB encode (mathworks.com)

カテゴリ

Help Center および File ExchangeHamming についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by