> restart: > Digits:=14: > st:= time(): > with(LinearAlgebra): > with(PolynomialTools): > with(DiscreteTransforms): > with(ImageTools): > read"../Src/Three_GreyImages.mpl": > infolevel[S_stls]:=1: > interface(rtablesize=190): > printlevel:=0: > k:=6:m:=4:s:=256: > Ph:=Read("../Result/Figure.1/TGI_original.jpg"): > Vx:=Vector(s,i->x^(i-1)):Vy:=Vector(s,i->y^(i-1)): > P1:=RandomMatrix(s,s,density=1,generator=-10..10):P2:=RandomMatrix(s,s > ,density=1,generator=-10..10):P3:=RandomMatrix(s,s,density=1,generator > =-10..10): > pert_f:=expand(LinearAlgebra:-Transpose(Vx).P1.Vy):pert_g:=expand(Line > arAlgebra:-Transpose(Vx).P2.Vy):pert_h:=expand(LinearAlgebra:-Transpos > e(Vx).P3.Vy): > Pr1:=(0.89*x+x^6+y^5+x^6*y^6+0.9*y+1)/k:Pr2:=(y^2+y*x^5+y^3+1+x^6*y^6+ > x*0.92+1)/k:Pr3:=(y^3+y*x^2+y^4+1+x^6*y^6+0.95*x+1)/k: > coeff(coeff(Pr1,x^6),y^6);coeff(coeff(Pr2,x^6),y^6); 1/6 1/6 > Pho1:=SD_Blurred(Ph,Pr1,10^(-m)*pert_f):Pho2:=SD_Blurred(Ph,Pr2,10^(-m > )*pert_g):Pho3:=SD_Blurred(Ph,Pr3,10^(-m)*pert_h): > View([Ph,Pho1,Pho2,Pho3]); > Write("../Result/Figure.1/TGI_blur1.jpg",Pho1):Write("../Result/Figure > .1/TGI_blur2.jpg",Pho2):Write("../Result/Figure.1/TGI_blur3.jpg",Pho3) > : > SD_SNR(Ph,Pr1,10^(-m)*pert_f);SD_SNR(Ph,Pr2,10^(-m)*pert_g);SD_SNR(Ph, > Pr3,10^(-m)*pert_h); 57.991342213298 59.570688111372 59.607014466421 > st:= time()-st; st := 6.235 > st:= time(): > e:=4: > Phoo,p2:=SSD_ImageDeconvolution(Pho1,Pho2,Pho3,e): SSD_ImageDeconvolution: Before we compute gcd using computing time is st1 = 0.562 evlu1 = 7/10 evlu2 = 3/5 evlu3 = 1 evlu1 = 1/5 evlu2 = 3/5 evlu3 = 2/5 Get_AB: the begin AB time is st = 0. BZ_ClGet_gcddegree: Getting degree using time is: st1 = 0.016 degy = [0.770618500736215850, 0.0815059281313930962, 0.0192549447482845970, 0.0163870202970447555, 0.00223289755070339366, 0.00139381710716186716, 0.0000431346445912512562, 0.0000200611860209281194, -5 0.530177843960529994 10 ] BZ_ClGet_gcddegree: Getting degree using time is: st1 = 0. degy = [0.290384500156059822, 0.0442878144355570575, 0.0131317350182875142, 0.0105629967441901886, 0.00595566621950467062, 0.00535350687309797766, 0.0000425112525307291160, 0.0000165717531068712862, -5 0.595190008397059486 10 ] Get_AB: the degree of GCD is degx = 249 degy = 249 st = 0.047 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0.016 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0.015 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0.015 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0.016 Get_AB: the first time cofactor's computing time is st1 = 0.656 Get_AB: the evaluation time 1D f and g is st1 = 0. BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the evaluation time 1D f and g is st1 = 0.234 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the evaluation time 1D f and g is st1 = 0.063 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the evaluation time 1D f and g is st1 = 0.062 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the evaluation time 1D f and g is st1 = 0.063 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the evaluation time 1D f and g is st1 = 0.062 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the evaluation time 1D f and g is st1 = 0.063 BZ_Get_1Dcofactors: the cofactors' coeff time is st = 0. Get_AB: the second time cofactor's computing time is st1 = 0.547 Ap2D_gcd: we get co-fator 1 using computing time is st1 = 1.250 SD_Dividen: we get Polynomials' coefficient matrix using computing time is st1 = 0.172 SD_Dividen: The first FFT time is st1 = 0. SD_Dividen: The second FFT time is st1 = 0.312 SD_Dividen: The divide time is st1 = 2.469 SD_Dividen: The inverse FFT time is st1 = 0.391 Ap2D_gcd: we get GCD by dividen using computing time is st1 = 4.187 Ap2D_gcd: we get gcd using computing time is st1 = 5.437 SSD_ImageDeconvolution: After we compute gcd using computing time is st1 = 0.235 > View([Ph,Phoo]); > Write("../Result/Figure.1/TGI_deblur.jpg",Phoo): > st:= time()-st;#the time is st := 6.125 > > > > > > >