Mercurial > hg > smallbox
comparison examples/Pierre Villars/Pierre_Villars_Example.m @ 30:dc6aaa255836
(none)
author | idamnjanovic |
---|---|
date | Tue, 29 Jun 2010 11:05:31 +0000 |
parents | cbf3521c25eb |
children | dab78a3598b6 |
comparison
equal
deleted
inserted
replaced
29:a07585dff65c | 30:dc6aaa255836 |
---|---|
9 % License, or (at your option) any later version. See the file | 9 % License, or (at your option) any later version. See the file |
10 % COPYING included with this distribution for more information. | 10 % COPYING included with this distribution for more information. |
11 % | 11 % |
12 % This example is based on the experiment suggested by Professor Pierre | 12 % This example is based on the experiment suggested by Professor Pierre |
13 % Vandergheynst on the SMALL meeting in Villars. | 13 % Vandergheynst on the SMALL meeting in Villars. |
14 % The idea behind is to use patches from source image as a dictonary in | 14 % The idea behind is to use patches from source image as a dictionary in |
15 % which we represent target image using matching pursuit algorithm. | 15 % which we represent target image using matching pursuit algorithm. |
16 % Calling Pierre_Problem function to get src image to be used as dictionary | 16 % Calling Pierre_Problem function to get src image to be used as dictionary |
17 % and target image to be represented using MP with 3 paches from source image | 17 % and target image to be represented using MP with 3 patches from source image |
18 % | 18 % |
19 %% | 19 %% |
20 | 20 |
21 clear all; | 21 clear all; |
22 | 22 |
47 | 47 |
48 % Set reconstruction function | 48 % Set reconstruction function |
49 | 49 |
50 SMALL.Problem.reconstruct=@(x) Pierre_reconstruct(x, SMALL.Problem); | 50 SMALL.Problem.reconstruct=@(x) Pierre_reconstruct(x, SMALL.Problem); |
51 | 51 |
52 SMALL.solver(i)=SMALL_init_solver; | 52 |
53 | 53 |
54 % Defining the parameters sparse representation | 54 % Defining the parameters sparse representation |
55 | 55 SMALL.solver(i)=SMALL_init_solver; |
56 SMALL.solver(i).toolbox='SMALL'; | 56 SMALL.solver(i).toolbox='SMALL'; |
57 SMALL.solver(i).name='SMALL_MP'; | 57 SMALL.solver(i).name='SMALL_MP'; |
58 | 58 |
59 % Parameters needed for matching pursuit (max number of atoms is 3 | 59 % Parameters needed for matching pursuit (max number of atoms is 3 |
60 % and residual error goal is 1e14 | 60 % and residual error goal is 1e-14 |
61 | 61 |
62 SMALL.solver(i).param=sprintf('%d, 1e-14',3); | 62 SMALL.solver(i).param=sprintf('%d, 1e-14',3); |
63 | 63 |
64 % Represent the image using the source image patches as dictionary | 64 % Represent the image using the source image patches as dictionary |
65 | 65 |