Class AlgorithmSimulatedExposureFusion

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.awt.event.WindowListener, java.lang.Runnable, java.util.EventListener

    public class AlgorithmSimulatedExposureFusion
    extends AlgorithmBase
    • Field Detail

      • alpha

        private double alpha
        Original code from dispersionMap.m, multiscaleBlending.m, remapFun.m, robustNormalization.m, runsef.m, and sef.m located at https://github.com/chlsl/simulated-exposure-fusion-ipol was written by Charles Hessel and is being ported to Java with his permission. This method was first described in the following paper: HESSEL, Charles, MOREL, Jean-Michel, An Extended Exposure Fusion and its Application to Single Image Contrast Enhancement. In: 2020 IEEE Winter Conference on Applications of Computer Vision (WACV). IEEE, 2020. For robustNormalization.m refer to: Charles Hessel, An Implementation of the Exposure Fusion Algorithm, Image Processing On Line, 8 (2018), pp. 369–387. https://doi.org/10.5201/ipol.2018.230 The code provided by Charles Hessel makes use of downsample.m, gaussian_pyramid.m, laplacian_pyramid.m, pyramid_filter.m, reconstruct_laplacian_pyramid.m, and upsample.m, which is from code located at https://github.com/Mericam/exposure-fusion that is covered under the BSD-2-Clause license: Copyright (c) 2015, Tom Mertens, tom.mertens@gmail.com All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Implementation of Exposure Fusion in Matlab, as described in: "Exposure Fusion", Tom Mertens, Jan Kautz and Frank Van Reeth In proceedings of Pacific Graphics 2007 "Exposure Fusion: A Simple and Practical Alternative to High Dynamic Range Photography. " Tom Mertens, Jan Kautz and Frank Van Reeth In Computer Graphics Forum, 28 (1) 161 - 171, 2009 This code was originally written by Tom Mertens at Hasselt University, August 2007. Uploaded to GitHub in February 2015 Author and main contact: Tom Mertens, tom.mertens@gmail.com
      • beta

        private double beta
      • nScales

        private int nScales
      • M

        private int M
      • med

        private double med
      • lambda

        private double lambda
      • Nx

        private int Nx
      • Mp

        private int Mp
      • Ns

        private int Ns
      • N

        private int N
      • a

        private double a
      • b

        private double b
      • epsilon

        private double epsilon
    • Constructor Detail

      • AlgorithmSimulatedExposureFusion

        public AlgorithmSimulatedExposureFusion()
      • AlgorithmSimulatedExposureFusion

        public AlgorithmSimulatedExposureFusion​(ModelImage destImg,
                                                ModelImage srcImg,
                                                double alpha,
                                                double beta,
                                                int nScales,
                                                int M,
                                                double med,
                                                double lambda)
    • Method Detail

      • runAlgorithm

        public void runAlgorithm()
        Description copied from class: AlgorithmBase
        Actually runs the algorithm. Implemented by inheriting algorithms.
        Specified by:
        runAlgorithm in class AlgorithmBase
      • multiscaleBlending

        private double[][] multiscaleBlending​(double[][][] seq,
                                              double[][][] W,
                                              int nScales)
      • reconstruct_laplacian_pyramid

        private double[][] reconstruct_laplacian_pyramid​(java.util.Vector<double[][]> pyr)
      • laplacian_pyramid

        java.util.Vector<double[][]> laplacian_pyramid​(double[][] I,
                                                       int nlev)
      • upsample

        private double[][] upsample​(double[][] I,
                                    int[] odd,
                                    double[][] filter)
      • gaussian_pyramid

        java.util.Vector<double[][]> gaussian_pyramid​(double[][] I,
                                                      int nlev)
      • downsample

        private double[][] downsample​(double[][] I,
                                      double[][] filter)
      • copyMakeBorder

        public double[][] copyMakeBorder​(double[][] src,
                                         int top,
                                         int bottom,
                                         int left,
                                         int right,
                                         int borderType,
                                         double borderValue)
      • filter2Same

        private double[][] filter2Same​(double[][] img,
                                       double[][] win)
      • pyramid_filter

        private double[][] pyramid_filter()
      • f

        private double[] f​(double[] t,
                           int k)
      • fs

        private double[] fs​(double[] t,
                            int k)
      • r

        private double r​(int k)
      • g

        private double[] g​(double[] t,
                           int k)
      • h

        private double[] h​(double[] t,
                           int k)
      • hs

        private double[] hs​(double[] t,
                            int k)
      • dg

        private double[] dg​(double[] t,
                            int k)
      • dh

        private double[] dh​(double[] t,
                            int k)
      • dhs

        private double[] dhs​(double[] t,
                             int k)