@@ -21,7 +21,7 @@ function make_patch_video(A,C,b,f,Y,d1,d2,param)
2121 else
2222 sx = 32 ;
2323 end
24-
24+
2525 if isfield(param ,' make_avi' ); % save an avi video
2626 make_avi = param .make_avi ;
2727 else
@@ -63,7 +63,8 @@ function make_patch_video(A,C,b,f,Y,d1,d2,param)
6363 if ismatrix(Y )
6464 Y = reshape(Y ,d1 ,d2 ,T );
6565 end
66-
66+ sx = min(sx ,floor(min(d1 ,d2 )/2 ));
67+
6768 Coor.x = kron(ones(d2 ,1 ),(1 : d1 )' );
6869 Coor.y = kron((1 : d2 )' ,ones(d1 ,1 ));
6970 nr = size(A ,2 );
@@ -117,7 +118,7 @@ function make_patch_video(A,C,b,f,Y,d1,d2,param)
117118 for t = 1 : skp : T
118119 subplot(4 ,6 ,[1 ,2 ,7 ,8 ]); imagesc(Y(: ,: ,t ),[0 ,mY ]);
119120 title(' Raw data' ,' fontweight' ,' bold' ,' fontsize' ,16 );
120- axis square ; axis off ;
121+ axis equal ; axis tight ; axis off ;
121122 if sc
122123 hold on ;
123124 for i = 1 : 4
@@ -129,7 +130,7 @@ function make_patch_video(A,C,b,f,Y,d1,d2,param)
129130 subplot(4 ,6 ,[3 ,4 ,9 ,10 ]); imagesc(C_rec(: ,: ,t ) - (1 - sb )*C_np(: ,: ,t ),[0 ,mC ]); % title(sprintf('%i',t));
130131 title(' Denoised' ,' fontweight' ,' bold' ,' fontsize' ,16 );
131132 xlabel(sprintf(' Timestep %i out of %i ' ,t ,T ),' fontweight' ,' bold' ,' fontsize' ,16 );
132- axis square ; set(gca ,' XTick' ,[],' YTick' ,[]);
133+ axis equal ; axis tight ; set(gca ,' XTick' ,[],' YTick' ,[]);
133134 if sc
134135 hold on ;
135136 for i = 1 : 4
@@ -139,10 +140,10 @@ function make_patch_video(A,C,b,f,Y,d1,d2,param)
139140 end
140141 subplot(4 ,6 ,[5 ,6 ,11 ,12 ]); imagesc(Y(: ,: ,t )-C_rec(: ,: ,t ),[-mC / 2 ,mC / 2 ]);
141142 title(' Residual 2x' ,' fontweight' ,' bold' ,' fontsize' ,16 );
142- axis square ; axis off ;
143+ axis equal ; axis tight ; axis off ;
143144 subplot(4 ,6 ,[13 ,14 ,19 ,20 ]); imagesc(C_np(: ,: ,t ),[0 ,mB ]);
144145 title({' Background' ; ' synchronized activity' },' fontweight' ,' bold' ,' fontsize' ,16 );
145- axis square ; axis off ;
146+ axis equal ; axis tight ; axis off ;
146147
147148 for i = 1 : 4
148149 subplot(4 ,6 ,14 + i ); imagesc(A_com(: ,: ,i )*C(ind(i ),t ),[0 ,up(i )/1.2 ]); axis square ;
0 commit comments