Stack Exchange
MATLAB - Regarding int2int LWT2 and ILWT
I write following code in MATLAB to apply int2int lifting wavelet transform to the lena.jpg image. 
    I=imread('lena.jpg');
    im=double(I);
    lshaarInt = liftwave('haar','int2int');
    els = {'p',[-0.125 0.125],0};
    lsnewInt = addlift(lshaarInt,els);
    [LL1,HL1,LH1,HH1] = lwt2(im,lsnewInt)
    LL1=uint8(LL1);LH1=uint8(LH1);HL1=uint8(HL1);HH1=uint8(HH1);
    figure()
    subplot(2,2,1);imshow(LL1);
    subplot(2,2,2);imshow(LH1);
    subplot(2,2,3);imshow(HL1);
    subplot(2,2,4);imshow(HH1);

Now I apply inverse LWT using following code without applying any other operations on sub-bands:
    LL1=double(LL1);LH1=double(LH1);HL1=double(HL1);HH1=double(HH1);
    wmd1= (ilwt2(LL1,HL1,LH1,HH1,lsnewInt));
    wmd=uint8(wmd1);

I compare two images 'I' and 'wmd' using Normalized Co-relation Coefficient (NCC)
In output, in place of 1 as a answer I got 0.9994. 
When I compare the intensity values of two images then the values are not same.
LWT is the lossless data technique but i found that the data loss.
Please suggest me where I am wrong.

Hum maybe those are floating point numerical errors, not actual loss. Also, can you show the comparison you mention?

Following is the code to calculate NCC:                                    'function N=nc(mark_prime,mark_get)
mark_get=double(mark_get);
mark_prime=double(mark_prime);
if size(mark_get)~=size(mark_prime)
error('Input vectors must  be the same size!')
else
[m,n]=size(mark_get);
fenzi=0;
fenmu=0;
for i=1:m
for j=1:n
fenzi=fenzi+mark_get(i,j)*mark_prime(i,j);
fenmu=fenmu+mark_prime(i,j)*mark_prime(i,j);
end
end
N=min(fenzi/fenmu,fenmu/fenzi);
end

The Intensity values are changed after applying ILWT (That is the loss). I want the exact or nearer  values.

I found the solution
The problem is with following code:
    LL1=uint8(LL1);LH1=uint8(LH1);HL1=uint8(HL1);HH1=uint8(HH1);

No need to convert all the above values from double to int. 
I got NCC value as 1 when I gave comment to above statement.
Thank you for response.
