How to convert a negative value to 1bit binary?
이전 댓글 표시
I have A = (1; 0; 1; 0; 1) (in vector )
A value, I embed it in the watermarking process. and the output of the extraction B = (-1.9934; -2.337; -1.1123; -3.4532; 1.2186) (in vector).
so how to change the value of B to be the same as the value of A (in binary )?
How to convert a negative value to 1bit binary?
댓글 수: 2
Bhaskar R
2019년 10월 30일
Walter Roberson
2019년 10월 30일
In cases where you are thinking of embedding bits into floating point numbers, that is often the wrong thing to do. People wanting to do this are often working either with floating point DCT coefficients, or else with floating point wavelet coefficients. When you change a single bit in DCT or wavelet coefficients, often there is no effect on the decoded image, and when there is an effect, often re-encoding in order to extract the bits will not get back the stored bits. Changing a single LSB for a wavelet coefficient can result in a representation that is invalid, something that cannot be produced by any input image, which can lead to the back transformation to an "image" to fail.
Think about it this way: the input image is typically Rows * Columns * 8 bits, and the floating point DCT or wavelet coefficients occupy Rows * Columns * 32 bits total, so you have 4 times as much information capacity in the floating point representation. If you change a single bit in that floating point representation, then even if you just consider it as a random process, there would only be a 1 in 4 chance that the bit was important to back-constructing an image.
What is recommended is to use Integer DCT (IDCT) or one of the integer wavelet transforms.
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Image Analysis에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!