-
Notifications
You must be signed in to change notification settings - Fork 5
/
MAIN.m
88 lines (82 loc) · 3.29 KB
/
MAIN.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
% ============================================================================
%
% Corresponding Author
% =========> Diclehan Karakaya Ulucan, M.Sc., Izmir, Turkey
% ============ Electrical and Electronics Engineer
% ============ diclehanulucan@gmail.com
%
% ============================================================================
%
% PAS-MEF: Multi-exposure image fusion based on principal component analysis,
% adaptive well-exposedness and saliency map
%
% ============================================================================
%
% Copyright(c) 2020-present.
%
% This work is licensed under the Creative Commons Attribution 4.0
% International License. To view a copy of this license, visit
% http://creativecommons.org/licenses/by/4.0/
% or send a letter to Creative Commons, PO Box 1866,
% Mountain View, CA 94042, USA.
%
%
% All Rights Reserved.
%
% ----------------------------------------------------------------------------
% Permission to use, copy, or modify this software and its documentation
% for educational and research purposes only and without fee is hereby
% granted, provided that this copyright notice and the original authors'
% names appear on all copies and supporting documentation. This program
% shall not be used, rewritten, or adapted as the basis of a commercial
% software or hardware product without first obtaining permission of the
% authors. The authors make no representations about the suitability of
% this software for any purpose. It is provided "as is" without express
% or implied warranty.
%-----------------------------------------------------------------------------
%
% This is the implementation of PAS-MEF: Multi-exposure image fusion based on
% principal component analysis, adaptive well-exposedness and
% saliency map, arXiv preprint arXiv:2105.11809, 2021.
%
%
% Please cite the work if you use this package.
%
%
% @article{karakaya2021pas,
% title={PAS-MEF: Multi-exposure image fusion based on principal component analysis,
% adaptive well-exposedness and saliency map},
% author={Karakaya, Diclehan and Ulucan, Oguzhan and Turkan, Mehmet},
% journal={arXiv preprint arXiv:2105.11809},
% year={2021}
% }
%
%----------------------------------------------------------------------
%
% Required Input : Source static image sequence in RGB.
%
% Output:
% (1) Fused : The fused image.
% (2) Weights : PAS-MEF Weights
% (3) run-time : Computational Complexity of the PAS-MEF in seconds
% (4) MEF_SSIM : Statistical result of the image according to:
% Perceptual Quality Assessment for Multi-Exposure Image Fusion,
% Kede Ma, Kai Zeng, Zhou Wang,
% IEEE Transactions on Image Processing, vol. 24,pp. 3345 - 3356, Nov.2015.
%
% Usage:
% Install the PAS-MEF package by using the "run install" command
% Select the image stacks folder to be fused.
% Run the PAS-MEF code in order to obtain results.
% Uninstall the PAS-MEF packages by using the "run uninstall" command
%
%
%----------------------------------------------------------------------
%% Install PAS-MEF
run install
%% Read Image Folder
I = load_images(uigetdir);
%% PAS-MEF
[Fused, Weights, run_time, MEF_SSIM] = PAS_MEF(I);
%% Uninstall PAS-MEF
run uninstall