\documentclass[11pt,twoside]{article}\makeatletter

\IfFileExists{xcolor.sty}%
  {\RequirePackage{xcolor}}%
  {\RequirePackage{color}}
\usepackage{colortbl}
\usepackage{wrapfig}
\usepackage{ifxetex}
\ifxetex
  \usepackage{fontspec}
  \usepackage{xunicode}
  \catcode`⃥=\active \def⃥{\textbackslash}
  \catcode`❴=\active \def❴{\{}
  \catcode`❵=\active \def❵{\}}
  \def\textJapanese{\fontspec{Noto Sans CJK JP}}
  \def\textChinese{\fontspec{Noto Sans CJK SC}}
  \def\textKorean{\fontspec{Noto Sans CJK KR}}
  \setmonofont{DejaVu Sans Mono}
  
\else
  \IfFileExists{utf8x.def}%
   {\usepackage[utf8x]{inputenc}
      \PrerenderUnicode{–}
    }%
   {\usepackage[utf8]{inputenc}}
  \usepackage[english]{babel}
  \usepackage[T1]{fontenc}
  \usepackage{float}
  \usepackage[]{ucs}
  \uc@dclc{8421}{default}{\textbackslash }
  \uc@dclc{10100}{default}{\{}
  \uc@dclc{10101}{default}{\}}
  \uc@dclc{8491}{default}{\AA{}}
  \uc@dclc{8239}{default}{\,}
  \uc@dclc{20154}{default}{ }
  \uc@dclc{10148}{default}{>}
  \def\textschwa{\rotatebox{-90}{e}}
  \def\textJapanese{}
  \def\textChinese{}
  \IfFileExists{tipa.sty}{\usepackage{tipa}}{}
\fi
\def\exampleFont{\ttfamily\small}
\DeclareTextSymbol{\textpi}{OML}{25}
\usepackage{relsize}
\RequirePackage{array}
\def\@testpach{\@chclass
 \ifnum \@lastchclass=6 \@ne \@chnum \@ne \else
  \ifnum \@lastchclass=7 5 \else
   \ifnum \@lastchclass=8 \tw@ \else
    \ifnum \@lastchclass=9 \thr@@
   \else \z@
   \ifnum \@lastchclass = 10 \else
   \edef\@nextchar{\expandafter\string\@nextchar}%
   \@chnum
   \if \@nextchar c\z@ \else
    \if \@nextchar l\@ne \else
     \if \@nextchar r\tw@ \else
   \z@ \@chclass
   \if\@nextchar |\@ne \else
    \if \@nextchar !6 \else
     \if \@nextchar @7 \else
      \if \@nextchar (8 \else
       \if \@nextchar )9 \else
  10
  \@chnum
  \if \@nextchar m\thr@@\else
   \if \@nextchar p4 \else
    \if \@nextchar b5 \else
   \z@ \@chclass \z@ \@preamerr \z@ \fi \fi \fi \fi
   \fi \fi  \fi  \fi  \fi  \fi  \fi \fi \fi \fi \fi \fi}
\gdef\arraybackslash{\let\\=\@arraycr}
\def\@textsubscript#1{{\m@th\ensuremath{_{\mbox{\fontsize\sf@size\z@#1}}}}}
\def\Panel#1#2#3#4{\multicolumn{#3}{){\columncolor{#2}}#4}{#1}}
\def\abbr{}
\def\corr{}
\def\expan{}
\def\gap{}
\def\orig{}
\def\reg{}
\def\ref{}
\def\sic{}
\def\persName{}\def\name{}
\def\placeName{}
\def\orgName{}
\def\textcal#1{{\fontspec{Lucida Calligraphy}#1}}
\def\textgothic#1{{\fontspec{Lucida Blackletter}#1}}
\def\textlarge#1{{\large #1}}
\def\textoverbar#1{\ensuremath{\overline{#1}}}
\def\textquoted#1{‘#1’}
\def\textsmall#1{{\small #1}}
\def\textsubscript#1{\@textsubscript{\selectfont#1}}
\def\textxi{\ensuremath{\xi}}
\def\titlem{\itshape}
\newenvironment{biblfree}{}{\ifvmode\par\fi }
\newenvironment{bibl}{}{}
\newenvironment{byline}{\vskip6pt\itshape\fontsize{16pt}{18pt}\selectfont}{\par }
\newenvironment{citbibl}{}{\ifvmode\par\fi }
\newenvironment{docAuthor}{\ifvmode\vskip4pt\fontsize{16pt}{18pt}\selectfont\fi\itshape}{\ifvmode\par\fi }
\newenvironment{docDate}{}{\ifvmode\par\fi }
\newenvironment{docImprint}{\vskip 6pt}{\ifvmode\par\fi }
\newenvironment{docTitle}{\vskip6pt\bfseries\fontsize{22pt}{25pt}\selectfont}{\par }
\newenvironment{msHead}{\vskip 6pt}{\par}
\newenvironment{msItem}{\vskip 6pt}{\par}
\newenvironment{rubric}{}{}
\newenvironment{titlePart}{}{\par }

\newcolumntype{L}[1]{){\raggedright\arraybackslash}p{#1}}
\newcolumntype{C}[1]{){\centering\arraybackslash}p{#1}}
\newcolumntype{R}[1]{){\raggedleft\arraybackslash}p{#1}}
\newcolumntype{P}[1]{){\arraybackslash}p{#1}}
\newcolumntype{B}[1]{){\arraybackslash}b{#1}}
\newcolumntype{M}[1]{){\arraybackslash}m{#1}}
\definecolor{label}{gray}{0.75}
\def\unusedattribute#1{\sout{\textcolor{label}{#1}}}
\DeclareRobustCommand*{\xref}{\hyper@normalise\xref@}
\def\xref@#1#2{\hyper@linkurl{#2}{#1}}
\begingroup
\catcode`\_=\active
\gdef_#1{\ensuremath{\sb{\mathrm{#1}}}}
\endgroup
\mathcode`\_=\string"8000
\catcode`\_=12\relax

\usepackage[a4paper,twoside,lmargin=1in,rmargin=1in,tmargin=1in,bmargin=1in,marginparwidth=0.75in]{geometry}
\usepackage{framed}

\definecolor{shadecolor}{gray}{0.95}
\usepackage{longtable}
\usepackage[normalem]{ulem}
\usepackage{fancyvrb}
\usepackage{fancyhdr}
\usepackage{graphicx}
\usepackage{marginnote}

\renewcommand{\@cite}[1]{#1}


\renewcommand*{\marginfont}{\itshape\footnotesize}

\def\Gin@extensions{.pdf,.png,.jpg,.mps,.tif}

  \pagestyle{fancy}

\usepackage[pdftitle={Comparative Study of OpenCV Inpainting Algorithms},
 pdfauthor={}]{hyperref}
\hyperbaseurl{}

	 \paperwidth210mm
	 \paperheight297mm
              
\def\@pnumwidth{1.55em}
\def\@tocrmarg {2.55em}
\def\@dotsep{4.5}
\setcounter{tocdepth}{3}
\clubpenalty=8000
\emergencystretch 3em
\hbadness=4000
\hyphenpenalty=400
\pretolerance=750
\tolerance=2000
\vbadness=4000
\widowpenalty=10000

\renewcommand\section{\@startsection {section}{1}{\z@}%
     {-1.75ex \@plus -0.5ex \@minus -.2ex}%
     {0.5ex \@plus .2ex}%
     {\reset@font\Large\bfseries}}
\renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
     {-1.75ex\@plus -0.5ex \@minus- .2ex}%
     {0.5ex \@plus .2ex}%
     {\reset@font\Large}}
\renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
     {-1.5ex\@plus -0.35ex \@minus -.2ex}%
     {0.5ex \@plus .2ex}%
     {\reset@font\large}}
\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
     {-1ex \@plus-0.35ex \@minus -0.2ex}%
     {0.5ex \@plus .2ex}%
     {\reset@font\normalsize}}
\renewcommand\subparagraph{\@startsection{subparagraph}{5}{\parindent}%
     {1.5ex \@plus1ex \@minus .2ex}%
     {-1em}%
     {\reset@font\normalsize\bfseries}}


\def\l@section#1#2{\addpenalty{\@secpenalty} \addvspace{1.0em plus 1pt}
 \@tempdima 1.5em \begingroup
 \parindent \z@ \rightskip \@pnumwidth 
 \parfillskip -\@pnumwidth 
 \bfseries \leavevmode #1\hfil \hbox to\@pnumwidth{\hss #2}\par
 \endgroup}
\def\l@subsection{\@dottedtocline{2}{1.5em}{2.3em}}
\def\l@subsubsection{\@dottedtocline{3}{3.8em}{3.2em}}
\def\l@paragraph{\@dottedtocline{4}{7.0em}{4.1em}}
\def\l@subparagraph{\@dottedtocline{5}{10em}{5em}}
\@ifundefined{c@section}{\newcounter{section}}{}
\@ifundefined{c@chapter}{\newcounter{chapter}}{}
\newif\if@mainmatter 
\@mainmattertrue
\def\chaptername{Chapter}
\def\frontmatter{%
  \pagenumbering{roman}
  \def\thechapter{\@roman\c@chapter}
  \def\theHchapter{\roman{chapter}}
  \def\thesection{\@roman\c@section}
  \def\theHsection{\roman{section}}
  \def\@chapapp{}%
}
\def\mainmatter{%
  \cleardoublepage
  \def\thechapter{\@arabic\c@chapter}
  \setcounter{chapter}{0}
  \setcounter{section}{0}
  \pagenumbering{arabic}
  \setcounter{secnumdepth}{6}
  \def\@chapapp{\chaptername}%
  \def\theHchapter{\arabic{chapter}}
  \def\thesection{\@arabic\c@section}
  \def\theHsection{\arabic{section}}
}
\def\backmatter{%
  \cleardoublepage
  \setcounter{chapter}{0}
  \setcounter{section}{0}
  \setcounter{secnumdepth}{2}
  \def\@chapapp{\appendixname}%
  \def\thechapter{\@Alph\c@chapter}
  \def\theHchapter{\Alph{chapter}}
  \appendix
}
\newenvironment{bibitemlist}[1]{%
   \list{\@biblabel{\@arabic\c@enumiv}}%
       {\settowidth\labelwidth{\@biblabel{#1}}%
        \leftmargin\labelwidth
        \advance\leftmargin\labelsep
        \@openbib@code
        \usecounter{enumiv}%
        \let\p@enumiv\@empty
        \renewcommand\theenumiv{\@arabic\c@enumiv}%
	}%
  \sloppy
  \clubpenalty4000
  \@clubpenalty \clubpenalty
  \widowpenalty4000%
  \sfcode`\.\@m}%
  {\def\@noitemerr
    {\@latex@warning{Empty `bibitemlist' environment}}%
    \endlist}

\def\tableofcontents{\section*{\contentsname}\@starttoc{toc}}
\parskip0pt
\parindent1em
\def\Panel#1#2#3#4{\multicolumn{#3}{){\columncolor{#2}}#4}{#1}}
\newenvironment{reflist}{%
  \begin{raggedright}\begin{list}{}
  {%
   \setlength{\topsep}{0pt}%
   \setlength{\rightmargin}{0.25in}%
   \setlength{\itemsep}{0pt}%
   \setlength{\itemindent}{0pt}%
   \setlength{\parskip}{0pt}%
   \setlength{\parsep}{2pt}%
   \def\makelabel##1{\itshape ##1}}%
  }
  {\end{list}\end{raggedright}}
\newenvironment{sansreflist}{%
  \begin{raggedright}\begin{list}{}
  {%
   \setlength{\topsep}{0pt}%
   \setlength{\rightmargin}{0.25in}%
   \setlength{\itemindent}{0pt}%
   \setlength{\parskip}{0pt}%
   \setlength{\itemsep}{0pt}%
   \setlength{\parsep}{2pt}%
   \def\makelabel##1{\upshape ##1}}%
  }
  {\end{list}\end{raggedright}}
\newenvironment{specHead}[2]%
 {\vspace{20pt}\hrule\vspace{10pt}%
  \phantomsection\label{#1}\markright{#2}%

  \pdfbookmark[2]{#2}{#1}%
  \hspace{-0.75in}{\bfseries\fontsize{16pt}{18pt}\selectfont#2}%
  }{}
      \def\TheFullDate{2021-10-15 (revised: 15 October 2021)}
\def\TheID{\makeatother }
\def\TheDate{2021-10-15}
\title{Comparative Study of OpenCV Inpainting Algorithms}
\author{}\makeatletter 
\makeatletter
\newcommand*{\cleartoleftpage}{%
  \clearpage
    \if@twoside
    \ifodd\c@page
      \hbox{}\newpage
      \if@twocolumn
        \hbox{}\newpage
      \fi
    \fi
  \fi
}
\makeatother
\makeatletter
\thispagestyle{empty}
\markright{\@title}\markboth{\@title}{\@author}
\renewcommand\small{\@setfontsize\small{9pt}{11pt}\abovedisplayskip 8.5\p@ plus3\p@ minus4\p@
\belowdisplayskip \abovedisplayskip
\abovedisplayshortskip \z@ plus2\p@
\belowdisplayshortskip 4\p@ plus2\p@ minus2\p@
\def\@listi{\leftmargin\leftmargini
               \topsep 2\p@ plus1\p@ minus1\p@
               \parsep 2\p@ plus\p@ minus\p@
               \itemsep 1pt}
}
\makeatother
\fvset{frame=single,numberblanklines=false,xleftmargin=5mm,xrightmargin=5mm}
\fancyhf{} 
\setlength{\headheight}{14pt}
\fancyhead[LE]{\bfseries\leftmark} 
\fancyhead[RO]{\bfseries\rightmark} 
\fancyfoot[RO]{}
\fancyfoot[CO]{\thepage}
\fancyfoot[LO]{\TheID}
\fancyfoot[LE]{}
\fancyfoot[CE]{\thepage}
\fancyfoot[RE]{\TheID}
\hypersetup{citebordercolor=0.75 0.75 0.75,linkbordercolor=0.75 0.75 0.75,urlbordercolor=0.75 0.75 0.75,bookmarksnumbered=true}
\fancypagestyle{plain}{\fancyhead{}\renewcommand{\headrulewidth}{0pt}}

\date{}
\usepackage{authblk}

\providecommand{\keywords}[1]
{
\footnotesize
  \textbf{\textit{Index terms---}} #1
}

\usepackage{graphicx,xcolor}
\definecolor{GJBlue}{HTML}{273B81}
\definecolor{GJLightBlue}{HTML}{0A9DD9}
\definecolor{GJMediumGrey}{HTML}{6D6E70}
\definecolor{GJLightGrey}{HTML}{929497} 

\renewenvironment{abstract}{%
   \setlength{\parindent}{0pt}\raggedright
   \textcolor{GJMediumGrey}{\rule{\textwidth}{2pt}}
   \vskip16pt
   \textcolor{GJBlue}{\large\bfseries\abstractname\space}
}{%   
   \vskip8pt
   \textcolor{GJMediumGrey}{\rule{\textwidth}{2pt}}
   \vskip16pt
}

\usepackage[absolute,overlay]{textpos}

\makeatother 
      \usepackage{lineno}
      \linenumbers
      
\begin{document}

             \author[1]{Preeti  Chatterjee}

             \author[2]{Subhadeep  Jana}

             \author[3]{Souradeep  Ghosh}

\renewcommand\Authands{ and }

\date{\small \em Received: 6 September 2021 Accepted: 2 October 2021 Published: 15 October 2021}

\maketitle


\begin{abstract}
        


Digital image processing has been a significant and important part in the realm of computing science since its inception. It entails the methods and techniques that are used to manipulate a digital image using a digital computer. It is a type of signal processing in which the input and output maybe image or features/characteristics associated with that image. In this age of advanced technology, digital image processing has its uses manifold, some major fields being image restoration, medical field, computer vision, color processing, pattern recognition and video processing. Image inpainting is one such important domain of image processing. It is a form of image restoration and conservation. This paper presents a comparative study of the various digital inpainting algorithms provided by Open CV (a popular image processing library) and also identifies the most effective inpainting algorithm on the basis of Peak Signal to Noise Ratio (PSNR), Structural Similarity Index (SSIM) and runtime metrics.

\end{abstract}


\keywords{image processing, openCV, Image Inpainting, Artificial Intelligence, Machine Learning}

\begin{textblock*}{18cm}(1cm,1cm) % {block width} (coords) 
\textcolor{GJBlue}{\LARGE Global Journals \LaTeX\ JournalKaleidoscope\texttrademark}
\end{textblock*}

\begin{textblock*}{18cm}(1.4cm,1.5cm) % {block width} (coords) 
\textcolor{GJBlue}{\footnotesize \\ Artificial Intelligence formulated this projection for compatibility purposes from the original article published at Global Journals. However, this technology is currently in beta. \emph{Therefore, kindly ignore odd layouts, missed formulae, text, tables, or figures.}}
\end{textblock*}


\let\tabcellsep& 	 	 		 
\section[{Introduction}]{Introduction}\par
mage processing is the technique of performing operations on an image to enhance the quality of the image, extract useful information from it, or manipulate it for better usage. Digital image processing techniques are applied in fields of computer vision, pattern recognition, video processing, image restoration and image correction \hyperref[b0]{[1]}.\par
Image restoration \hyperref[b1]{[2]} and correction entails all the techniques used to restore a damaged image. It includes noise removal from the image, correcting a blurred photo, enhancing an image with defocused subject, converting a black and white image to color image, removing stains and unwanted marks from the image, etc. Image inpainting is one such technique that falls under image restoration.\par
Image inpainting \hyperref[b2]{[3]} is a form of image restoration and conservation. The technique is generally used to repair photos with missing areas due to damage or aging, or mask out unpleasant deformed areas of the image. The use of inpainting can be traced back to the 1700s when Pietro Edwards, director of the Restoration of the Public Pictures in Venice, Italy, applied his scientific methodology to restore and preserve historic artworks. The modern approach to inpainting was established in 1930 during the International Conference for the Study of Scientific Methods for the Examination and Preservation of Works of Art. Technological advancements led to new applications of inpainting. Since the mid-1990's, the method of inpainting has evolved to include digital media. Widespread use of digital inpainting techniques range from entirely automatic computerized inpainting to tools used to simulate the process manually. Digital inpainting includes the use of software that relies on sophisticated algorithms to replace lost or corrupted parts of the image data. There are various advanced inpainting methodologies \hyperref[b3]{[4]}, namely Partial Differential Equation (PDE) based inpainting \hyperref[b4]{[5]}, Texture synthesis based inpainting \hyperref[b5]{[6]}, Hybrid inpainting \hyperref[b6]{[7]}, Example based inpainting \hyperref[b7]{[8]} and Deep generative model based inpainting \hyperref[b8]{[9]}.\par
In this paper, we have presented a detailed comparative study of the three inpainting algorithms natively provided by the Open CV library, and also stated which is the most effective algorithm out of them. The paper is structured as follows: Section II contains the related work done in the past on comparative analysis of inpainting techniques and algorithms. Section III contains a brief theory behind the inpainting algorithms to be discussed. Section IV contains the details of the comparative study and experimental setup. Section V presents the results we obtained from our study and their critical explanations. Section VI details the possibilities of further work that can be performed on this topic. Section VII concludes the paper. We have focused more on the practical analysis of the three algorithms, and less on the theoretical and mathematical interpretation of the algorithms. 
\section[{II.}]{II.} 
\section[{Related Work}]{Related Work}\par
The first inpainting algorithm provided by OpenCV is established on the paper "An Image Inpainting Technique based on the Fast Marching method" by Alexandru Telea \hyperref[b9]{[10]} in 2004. It is based on the Fast Marching Method. The second inpainting algorithm provided by OpenCV is established on the paper "Navier-Stokes, Fluid Dynamics, and Image and Video Inpainting" by M. Bertalmio et al \hyperref[b10]{[11]} in 2001. It is based on fluid dynamics. The third inpainting algorithm was reviewed in the paper "Demonstration of Rapid Frequency Selective Reconstruction for Image Resolution Enhancement" by Nils Genser et al \hyperref[b11]{[12]} in 2017. It is based on the Rapid Frequency Selective Reconstruction (FSR) method. They applied the algorithm on Kodak and Tecnick image datasets over custom error masks and presented the Peak Signal to Noise Ratio (PSNR), Structural Similarity Index (SSIM) and runtime metrics. We have used the same metrics for comparison, explained later in Section IV. Supriya Chhabra et al \hyperref[b12]{[13]} presented a critical analysis of different digital inpainting algorithms for still images, and also a comparison of the computational cost of the algorithms. We have considered execution time and memory consumption as metrics to compare computational cost between the algorithms. Raluca Vreja et al \hyperref[b13]{[14]} published a detailed analytical overview of five advanced inpainting algorithms and measurement benchmarks. They emphasized on the advantages and disadvantages of the used algorithms and also proposed an improved adaptation of the Oliviera's \hyperref[b14]{[15]} and Hadhoud's \hyperref[b15]{[16]} inpainting algorithms.\par
Kunti Patel et al \hyperref[b16]{[17]} presented a study and analysis of image inpainting algorithms and concluded that exemplar based techniques are generally more effective than PDE based or texture synthesis based techniques. They also extensively listed the merits and demerits of the algorithms, which makes it easy to choose for end users without further research. Anupama Sanjay Awati et al \hyperref[b17]{[18]} detailed a review of digital image inpainting algorithms, comparing hybrid techniques against commonly used ones. K. Singh et al \hyperref[b18]{[19]} presented a comparison of patch based inpainting techniques and proposed an adaptive neighborhood selection method for efficient patch inpainting. 
\section[{III.}]{III.} 
\section[{Theory}]{Theory}\par
OpenCV is a library of programming functions mainly aimed at real-time computer vision. It is a huge open source library for computer vision, machine learning, image and video processing tasks. OpenCV is used in a lot of machine learning problems like face recognition, object detection, image segmentation, etc. mainly due to its simple syntax and presence of a large number of predefined functions and modules.\par
There are several algorithms present for digital image inpainting, but OpenCV natively provides three of  This algorithm is based on the paper "An Image Inpainting Technique based on the Fast Marching method" by Alexandru Telea \hyperref[b9]{[10]} in 2004. It is based on the Fast Marching Method (FMM), a solutional paradigm which builds a solution outwards starting from the "known information" of a problem. It is a numerical method created by James Sethian for solving boundary value problems of the Eikonal equation \hyperref[b19]{[20]}. A simple explanation of the working of the algorithm follows, extracted from the original paper \hyperref[b9]{[10]}.\par
The first and foremost step in any inpainting method is to identify the region to be inpainted. There is the region to be inpainted, also known as the unknown region and the surrounding known region of the image.\par
The algorithm first considers the boundary of the unknown region, which is of infinitesimal width, and inpaints one pixel lying on the boundary. Then it iterates over all the pixels lying on the boundary to inpaint the whole boundary. A single pixel is inpainted as a function of all other pixels lying in its known neighborhood by summing the estimates of all pixels, normalized by a weighting function. A weighting function is necessary as it ensures the inpainted pixel is influenced more by the pixels lying close to it and less by the pixels lying far away. After the boundary has been inpainted, the algorithm propagates forward towards the center of the unknown region.\par
To implement the propagation, the Fast Marching Method (FMM) is used. FMM ensures the pixels near the known pixels are inpainted first, so that it mimics a manual inpainting technique. The FMM's main advantage is that it explicitly maintains a narrow band that separates the known from the unknown image area and specifies which pixel to inpaint next. 
\section[{b) INPAINT\textunderscore NS}]{b) INPAINT\textunderscore NS}\par
This algorithm provided by OpenCV is established on the paper "Navier-Stokes, Fluid Dynamics, and Image and Video Inpainting" by M. Bertalmio et al \hyperref[b10]{[11]} in 2001. This algorithm is based on fluid dynamics (fluid dynamics is a sub-discipline of fluid mechanics that describe the flow of fluids: liquids and gases) and utilizes partial differential equations. The method involves a direct solution of the Navier-Stokes equation \hyperref[b20]{[21]} for an incompressible fluid. A simple explanation of the working of the algorithm follows, extracted from the original paper \hyperref[b10]{[11]}.\par
The basic principle is heuristic. After the user selects the unknown region, the algorithm first travels along the edges from known regions to unknown regions, and automatically transports information into the inpainting region. The algorithm makes use of isophotes (a line in a diagram connecting points where the intensity of light or brightness is the same). The fill-in is done is such a way that the isophote lines arriving at the unknown region's boundary are completed inside, which allows the smooth continuation of information towards the center of the unknown region. M. Bertalmio et al \hyperref[b10]{[11]} drew an analogy between the image intensity function of an image and the stream function in a 2D incompressible fluid, and used techniques from the computational fluid dynamics to produce an approximate solution to image inpainting problem. 
\section[{c) INPAINT\textunderscore FSR}]{c) INPAINT\textunderscore FSR}\par
FSR stands for Rapid Frequency Selective Reconstruction \hyperref[b11]{[12]}. It is a high quality signal extrapolation algorithm. FSR has proven to be very efficient in the domain of inpainting. The FSR is a powerful approach to reconstruct and inpaint missing areas of an image.\par
The signal of a distorted block is extrapolated using known samples and already reconstructed pixels as support. This algorithm iteratively generates a generic complex valued model of the signal, which approximates the undistorted samples in the extrapolation area of a particular size as a weighted linear combination of Fourier basic function. The Fourier basic function is a method to smooth out data varying over a continuum (here the unknown region) and exhibiting a cyclical trend. An important feature of FSR algorithm is that the calculations are carried out in the Fourier domain, which leads to fast implementation.\par
There are two implementations of the FSR inpainting algorithm -INPAINT\textunderscore FSR\textunderscore FAST and INPAINT\textunderscore FSR\textunderscore BEST. The Fast implementation of FSR provides a great balance between speed and accuracy, and the Best implementation mainly focuses on the accuracy, with speed being slower compared to Fast.\par
IV. 
\section[{Comparative Study a) Theoretical Comparison}]{Comparative Study a) Theoretical Comparison}\par
All the three inpainting algorithms provided by OpenCV are unique and works on different methodologies. The similarity between the algorithms is the inpainting procedure starts with the pixels lying in the boundary of the unknown region, and slowly propagates towards the centre of the unknown region. All the three algorithms are heuristic in nature. The propagation method used in each is different. TELEA uses the Fast Marching Method (FMM), NS uses fluid dynamics equations and FSR extrapolates the pixel values of the unknown region using known samples. 
\section[{b) Practical Comparison}]{b) Practical Comparison}\par
For practical comparison of the 3 algorithms, we ran some code in Python. Our testing setup had the following specifications:\par
-CPU : i7-8700K (3.70 GHz) -RAM : 16 GB (3200 MHz) -GPU : 8 GB GTX 1080\par
We took the Kodak image set (which contains 25 uncompressed PNG true colour images of size 768x512 pixels) and four custom error masks for the dataset. We applied all the inpainting algorithms individually over each error mask on the images. We compared the results using four main metrics:\par
-Peak Signal to Noise Ratio (PSNR): It is the ratio between the maximum possible power of a signal and the power of corrupting noise. To estimate the PSNR of an image, it is necessary to compare the distorted image to an ideal clean image with the maximum possible power. PSNR is commonly used to estimate the efficiency of compressors, filters etc. A higher value of PSNR suggests an efficient manipulation method. In our case, we will compute the PSNR between the original image and the inpainted image. The Python code to calculate PSNR is given in Fig \hyperref[fig_2]{2}.   -Memory: It is the total memory consumed by the algorithm while completing the task. We use tracemalloc module, which is a debug tool to trace memory blocks allocated by Python. We find the peak memory usage during the working of the algorithm. 
\section[{Fig. 5: Memory code}]{Fig. 5: Memory code}\par
All the values have been taken up to three decimal places. Apart from the four main metrics, we also considered two hybrid metrics defined in Section V. We also curated some custom images for testing of certain specific cases. The results obtained are given in the next section, along with their critical explanation.\par
V. 
\section[{Results and Discussion}]{Results and Discussion} 
\section[{a) Kodak image dataset results}]{a) Kodak image dataset results}\par
There are 19 landscape and 6 portrait oriented photos in the Kodak image set. We initially made the custom error masks for landscape orientation, and rotated them to fit the portrait orientation. We chose striped masks as the error regions are equally distributed. The four custom error masks we considered are: Fig.  {\ref 6}: Four custom error masks\par
The white stripes are the areas to be inpainted. We have displayed the image results for just 1 landscape photo (2 error masks) and 1 portrait photo (2 error masks). These are the following results we obtained:-Sample\textunderscore 1 (Landscape)\par
The original, distorted and 4 inpainted results of the first image sample over the first error mask are given in Fig \hyperref[fig_5]{7}. The metric values calculated for the first image sample over the first error mask are given in Table \hyperref[tab_0]{1}.  The metric values calculated for the first image sample over the second error mask are given in Table \hyperref[tab_1]{2}. We have not given the image results for the third and fourth error masks, only the metric values. The metric values calculated for the first image sample over the third error mask are given in Table \hyperref[tab_2]{3}. The metric values calculated for the first image sample over the fourth error mask are given in Table \hyperref[tab_3]{4}.  
\section[{Sample\textunderscore 2 (Portrait)}]{Sample\textunderscore 2 (Portrait)}\par
For portrait images, the error masks have been rotated 90 degree clockwise to fit the orientation. Given are the original, distorted and 4 in painted results of the second image sample over the first error mask in Fig \hyperref[fig_7]{9}. The metric values calculated for the second image sample over the first error mask are given in Table \hyperref[tab_4]{5}.  The metric values calculated for the second image sample over the first error mask are given in Table \hyperref[tab_5]{6}. We have not given the image results for the third and fourth error masks, only the metric values. The metric values calculated for the second image sample over the third error mask are given in Table \hyperref[tab_6]{7}. The metric values calculated for the second image sample over the fourth error mask are given in Table \hyperref[tab_7]{8}.  Generally speaking, lower memory consumption and runtime values mean a better algorithm. For other metrics, the higher the PSNR and SSIM value, the better the algorithm. The average memory consumption, as seen from Table \hyperref[tab_9]{9},10,11,12 is same for any mask on any image for any algorithm for the particular dataset. Hence we will not consider it as a factor for deciding the most efficient algorithm. We have defined two hybrid metrics X and Y for deciding which algorithm is most efficient based on our data. Metric X is directly proportional to PSNR, directly proportional to SSIM and inversely proportional to Runtime value:X ? PSNR X ? SSIM X ? (1/Runtime)\par
Combining all three above equations we get:X ? (PSNR * SSIM)/Runtime X = k * ((PSNR * SSIM)/Runtime)\par
where k is a constant, taken to be 1 for comparison purposes. Hence X = (PSNR * SSIM)/Runtime A high value of metric X means an effective algorithm. We used the values obtained in Table \hyperref[tab_9]{9},10,11,12 and calculated metric X values for the four error masks. The values are given in Table \hyperref[tab_11]{13}. From Table \hyperref[tab_11]{13}, we can see that TELEA algorithm gets the highest value in all four error masks. Hence, TELEA is the most efficient in painting algorithm when we consider metric X to be the comparison metric.\par
But as we can infer from the definition of metric X, it has the runtime factor associated with it. Runtime is an important factor for analysing algorithms, but can be subjective at times to different end users. Some users may have a time constraint, some users may not. Hence we need to define such a metric which does not include the runtime factor. Therefore, we define metric Y. Metric Y is directly proportional to PSNR and directly proportional to SSIM value: Y ? PSNR Y ? SSIM Combining all two above equations we get:Y ? PSNR * SSIM Y = k * (PSNR * SSIM)\par
where k is a constant, taken to be 1 for comparison purposes. Hence Y = PSNR * SSIM A high value of metric Y means an effective algorithm, without taking the runtime factor into account. Similarly, we used the values in Table \hyperref[tab_9]{9},10,11,12 and calculated metric Y values for the four error masks. The values are given in Table \hyperref[tab_12]{14}. From Table \hyperref[tab_12]{14}, we can see that FSR\textunderscore BEST algorithm gets the highest value in all four error masks. Hence, FSR\textunderscore BEST is the most efficient inpainting algorithm when we consider metric Y to be the comparison metric, which does not take the runtime factor into account.\par
Summing up our observation and results for the Kodak image dataset, we can say that the most efficient inpainting algorithm when runtime is a constraint is TELEA algorithm and the most efficient inpainting algorithm when runtime is not a constraint is FSR\textunderscore BEST algorithm. 
\section[{b) Edge inpainting results}]{b) Edge inpainting results}\par
The inpainting algorithms produce very different results when working on edges. To compare the working, we have chosen an image which has clear distinct foreground and background. We distorted a part of the edge, and applied the inpainting algorithms to it. The image results are given in  {\ref Fig 11,} and metric values are given in Table \hyperref[tab_13]{15}.\par
As we can see from the results, TELEA has the highest value for X metric. That is if we consider runtime to be a factor, TELEA is the most efficient algorithm. But FSR\textunderscore BEST has the highest value for Y metric, i.e. if we do not consider runtime to be a factor, then FSR\textunderscore BEST is the most efficient algorithm for edge inpainting. We can also see from the image results that FSR\textunderscore BEST produces the most believable result, but also has the largest runtime. TELEA and NS do a decent job in filling up the edges and maintaining the edge difference. But still some parts are hazed and distorted. FSR\textunderscore FAST does the worst job, mainly because it trades off accuracy for runtime, and the result is bad.   
\section[{c) Pattern inpainting results}]{c) Pattern inpainting results}\par
The inpainting algorithms produce very different results when working on patterns. To compare the working, we have chosen a checkerboard image as it is the easiest pattern to replicate. We distorted a part of the image in the centre, and applied the inpainting algorithms to it. The image results are given in  {\ref Fig 12,} and metric values are given in Table \hyperref[tab_14]{16}.\par
As we can see from the image results, none of the inpainting algorithms can replicate the pattern in the unknown region, which is understandable because the inpainting algorithms are focused on filling up the unknown region progressively based on information from the nearest known region. They work on the small scale spatial influences. In order to inpaint a pattern, the algorithm must work over a broad range of the known region to understand the dynamics of the pattern. An exemplar based inpainting or patch based inpainting method can work for pattern inpainting.\par
Comparing the metric values, TELEA has the highest X value and FSR\textunderscore BEST has the highest Y value. From the image results, TELEA still does a decent job of producing an arbitrary pattern, while FSR\textunderscore BEST fills the whole unknown region with a singular colour. Hence, no algorithm provided by OpenCV is perfectly suitable for inpainting a pattern, but TELEA can be used as a last resort.   
\section[{d) Text error mask inpainting results}]{d) Text error mask inpainting results}\par
We also tested the working of the inpainting algorithms on a custom text error mask. We took an image from the Kodak dataset and wrote some random text on it as error regions, then applied the algorithms on it. The image results are given in Fig \hyperref[fig_11]{13}, and metric values are given in Table \hyperref[tab_15]{17}.\par
Comparing the metric values, NS has the highest X value and FSR\textunderscore BEST has the highest Y value. All the algorithms work decent, but from the image results we can see that TELEA and NS have some distortions near the fence area, while FSR\textunderscore FAST and FSR\textunderscore BEST have inpainted smoothly in that area. If runtime is a constraint, then NS is the most effective algorithm to be used. Although, TELEA can also be used as it produces very similar results to NS. If runtime is not a constraint, then FSR\textunderscore BEST is the most effective choice for text error mask inpainting.   
\section[{e) Monochromatic image inpainting results}]{e) Monochromatic image inpainting results}\par
We tested the working of the inpainting algorithms on a monochromatic image. We took an image from the Kodak dataset and converted it into monochrome and used a spiral error mask on it. The image results are given in Fig \hyperref[fig_12]{14}, and metric values are given in Table \hyperref[tab_16]{18}.\par
Comparing the metric values, NS has the highest X value and FSR\textunderscore BEST has the highest Y value. All the algorithms work decent, but from the image results, we see that TELEA and NS have some distortions near the beak of the bird, while FSR\textunderscore FAST and FSR\textunderscore BEST have inpainted smoothly in that area. If runtime is a constraint, then NS is the most effective algorithm to be used. Although, TELEA can also be used as it produces very similar results to NS. If runtime is not a constraint, then FSR\textunderscore BEST is the most effective choice for monochromatic image inpainting.   
\section[{f) Discussions}]{f) Discussions}\par
Summing up our observations and results for the Kodak image dataset and other specific cases, we can say that the TELEA inpainting algorithm is the most efficient algorithm if runtime is a constraint i.e. the user needs to perform the inpainting operation as fast as he can and produce the best results. On the other hand, FSR\textunderscore BEST inpainting algorithm is the most efficient algorithm if runtime is not a constraint i.e. the user has no time limit for the inpainting operation and wants to get the best result. The average memory consumption for all the inpainting algorithms are modest, hence memory will hardly be an issue in any system while running the Open CV inpainting algorithms.  
\section[{Future Scope}]{Future Scope}\par
Our inpainting comparison study was done on the Kodak image dataset, a relatively small dataset containing 25 images only. The study can be done on a larger, more robust dataset which contains variety of images. This can be done to get more extensive results. We compared our results on the basis of four metrics only; more intricate metrics may be defined for the testing. Our study can be a base for analysing how various OpenCV inpainting methods work on images with different colour profiles.\par
We ran tests using four custom error masks. The error masks considered were mostly linear in shape. Other type of error masks such as curved, mixture of linear and curved can be taken for testing. This study can be a base for a comprehensive study on video inpainting techniques, which would be beneficial for people looking to work in this field. 
\section[{VII.}]{VII.} 
\section[{Conclusion}]{Conclusion}\par
In conclusion, we present a comparative study of the various OpenCV inpainting algorithms, focusing extensively on their practical uses. The purpose of this paper is to apprise new users and researchers of the most efficient inpainting algorithm provided by OpenCV: TELEA algorithm for time constrained operations and FSR\textunderscore BEST algorithm for non time constrained operations. We present the most efficient OpenCV inpainting algorithm to be used for various scenarios, which can help a beginner at inpainting to make his decision wisely without any further research. This study can be a base for more detailed comparative works on image and video inpainting. Inpainting is an evolving domain of image processing with major strides being made in the past, and much more sophisticated algorithms yet to arrive. It opens up the doorway for new image processing researchers to better the existing algorithms and create finer advanced inpainting algorithms which achieve near perfect accuracy.\begin{figure}[htbp]
\noindent\textbf{}\includegraphics[]{image-2.png}
\caption{\label{fig_0}}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{1}\includegraphics[]{image-3.png}
\caption{\label{fig_1}Fig. 1 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{2}\includegraphics[]{image-4.png}
\caption{\label{fig_2}Fig. 2 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{3}\includegraphics[]{image-5.png}
\caption{\label{fig_3}Fig. 3 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{4}\includegraphics[]{image-6.png}
\caption{\label{fig_4}Fig. 4 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{7}\includegraphics[]{image-7.png}
\caption{\label{fig_5}Fig. 7 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{8}\includegraphics[]{image-8.png}
\caption{\label{fig_6}Fig. 8 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{9}\includegraphics[]{image-9.png}
\caption{\label{fig_7}Fig. 9 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{10}\includegraphics[]{image-10.png}
\caption{\label{fig_8}Fig. 10 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{11}\includegraphics[]{image-11.png}
\caption{\label{fig_9}Fig. 11 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{12}\includegraphics[]{image-12.png}
\caption{\label{fig_10}Fig. 12 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{13}\includegraphics[]{image-13.png}
\caption{\label{fig_11}Fig. 13 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{14}\includegraphics[]{image-14.png}
\caption{\label{fig_12}Fig. 14 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{1} \par 
\begin{longtable}{P{0.2125\textwidth}P{0.2367857142857143\textwidth}P{0.018214285714285714\textwidth}P{0.06071428571428571\textwidth}P{0.024285714285714285\textwidth}P{0.15785714285714286\textwidth}P{0.13964285714285715\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{27.218 26.713}\tabcellsep 26.612\tabcellsep 26.315\\
SSIM\tabcellsep \multicolumn{2}{l}{0.889}\tabcellsep \multicolumn{2}{l}{0.889}\tabcellsep 0.887\tabcellsep 0.884\\
Runtime [s]\tabcellsep \multicolumn{4}{l}{5.349 96.199}\tabcellsep 1.089\tabcellsep 1.085\\
Memory [MB]\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_0}Table 1 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{2} \par 
\begin{longtable}{P{0.21402877697841724\textwidth}P{0.19568345323741007\textwidth}P{0.11618705035971223\textwidth}P{0.02446043165467626\textwidth}P{0.15899280575539568\textwidth}P{0.14064748201438848\textwidth}}
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{34.577 34.764}\tabcellsep 30.556\tabcellsep 30.689\\
SSIM\tabcellsep 0.974\tabcellsep \multicolumn{2}{l}{0.975}\tabcellsep 0.950\tabcellsep 0.952\\
Runtime [s]\tabcellsep 2.887\tabcellsep \multicolumn{2}{l}{35.132}\tabcellsep 1.049\tabcellsep 1.047\\
Memory [MB]\tabcellsep 1.339\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_1}Table 2 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{3} \par 
\begin{longtable}{P{0.2125\textwidth}P{0.2367857142857143\textwidth}P{0.018214285714285714\textwidth}P{0.06071428571428571\textwidth}P{0.024285714285714285\textwidth}P{0.15785714285714286\textwidth}P{0.13964285714285715\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{27.143 27.229}\tabcellsep 27.096\tabcellsep 26.796\\
SSIM\tabcellsep \multicolumn{2}{l}{0.890}\tabcellsep \multicolumn{2}{l}{0.892}\tabcellsep 0.888\tabcellsep 0.883\\
Runtime [s]\tabcellsep \multicolumn{4}{l}{5.210 97.800}\tabcellsep 1.091\tabcellsep 1.091\\
Memory [MB]\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_2}Table 3 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{4} \par 
\begin{longtable}{P{0.21402877697841724\textwidth}P{0.19568345323741007\textwidth}P{0.05503597122302158\textwidth}P{0.0856115107913669\textwidth}P{0.15899280575539568\textwidth}P{0.14064748201438848\textwidth}}
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{34.788 34.897}\tabcellsep 30.709\tabcellsep 31.209\\
SSIM\tabcellsep 0.975\tabcellsep \tabcellsep 0.976\tabcellsep 0.952\tabcellsep 0.955\\
Runtime [s]\tabcellsep 3.114\tabcellsep \multicolumn{2}{l}{39.762}\tabcellsep 1.055\tabcellsep 1.049\\
Memory [MB]\tabcellsep 1.339\tabcellsep \tabcellsep 1.339\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_3}Table 4 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{5} \par 
\begin{longtable}{P{0.2125\textwidth}P{0.2367857142857143\textwidth}P{0.018214285714285714\textwidth}P{0.06071428571428571\textwidth}P{0.024285714285714285\textwidth}P{0.15785714285714286\textwidth}P{0.13964285714285715\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{31.739 32.738}\tabcellsep 31.398\tabcellsep 31.133\\
SSIM\tabcellsep \multicolumn{2}{l}{0.936}\tabcellsep \multicolumn{2}{l}{0.941}\tabcellsep 0.934\tabcellsep 0.932\\
Runtime [s]\tabcellsep \multicolumn{4}{l}{4.574 65.644}\tabcellsep 1.092\tabcellsep 1.088\\
Memory [MB]\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_4}Table 5 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{6} \par 
\begin{longtable}{P{0.19966442953020133\textwidth}P{0.23959731543624158\textwidth}P{0.10838926174496645\textwidth}P{0.022818791946308724\textwidth}P{0.1483221476510067\textwidth}P{0.13120805369127517\textwidth}}
\tabcellsep \multicolumn{3}{l}{error mask}\tabcellsep \\
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{39.632 39.673}\tabcellsep 36.063\tabcellsep 35.106\\
SSIM\tabcellsep 0.983\tabcellsep \multicolumn{2}{l}{0.983}\tabcellsep 0.972\tabcellsep 0.971\\
Runtime [s]\tabcellsep 2.568\tabcellsep \multicolumn{2}{l}{23.655}\tabcellsep 1.044\tabcellsep 1.052\\
Memory [MB]\tabcellsep 1.339\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_5}Table 6 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{7} \par 
\begin{longtable}{P{0.19966442953020133\textwidth}P{0.1825503355704698\textwidth}P{0.16543624161073825\textwidth}P{0.022818791946308724\textwidth}P{0.1483221476510067\textwidth}P{0.13120805369127517\textwidth}}
\tabcellsep \tabcellsep \multicolumn{2}{l}{error mask}\tabcellsep \\
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{32.105 31.834}\tabcellsep 30.596\tabcellsep 30.268\\
SSIM\tabcellsep 0.933\tabcellsep \multicolumn{2}{l}{0.936}\tabcellsep 0.929\tabcellsep 0.927\\
Runtime [s]\tabcellsep 4.334\tabcellsep \multicolumn{2}{l}{67.520}\tabcellsep 1.089\tabcellsep 1.085\\
Memory [MB]\tabcellsep 1.339\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_6}Table 7 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{8} \par 
\begin{longtable}{P{0.49810964083175807\textwidth}P{0.13015122873345936\textwidth}P{0.035349716446124765\textwidth}P{0.01606805293005671\textwidth}P{0.01285444234404537\textwidth}P{0.08355387523629489\textwidth}P{0.07391304347826086\textwidth}}
\tabcellsep \multicolumn{4}{l}{error mask}\\
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{39.689 39.532}\tabcellsep 37.029\tabcellsep 37.092\\
SSIM\tabcellsep \multicolumn{2}{l}{0.985}\tabcellsep \multicolumn{2}{l}{0.985}\tabcellsep 0.975\tabcellsep 0.975\\
Runtime [s]\tabcellsep \multicolumn{4}{l}{2.634 25.407}\tabcellsep 1.056\tabcellsep 1.057\\
Memory [MB]\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\\
\multicolumn{6}{l}{We applied the in painting algorithms to all the}\\
\multicolumn{6}{l}{25 images present in the dataset. The average metric}\\
\multicolumn{6}{l}{values for first, second, third and fourth error masks are}\\
\multicolumn{6}{l}{given in tables 9,10,11,12 respectively.}\\
\multicolumn{6}{l}{Average metric values for first error mask}\\
\tabcellsep Fast\tabcellsep FSR\tabcellsep \tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{29.719 30.017}\tabcellsep 29.145\tabcellsep 28.891\\
SSIM\tabcellsep 0.929\tabcellsep \multicolumn{3}{l}{0.932}\tabcellsep 0.925\tabcellsep 0.923\\
Runtime [s]\tabcellsep 4.346\tabcellsep \multicolumn{3}{l}{72.229}\tabcellsep 1.089\tabcellsep 1.091\\
Memory [MB]\tabcellsep 1.339\tabcellsep \multicolumn{3}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_7}Table 8 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{10} \par 
\begin{longtable}{P{0.21402877697841724\textwidth}P{0.19568345323741007\textwidth}P{0.05503597122302158\textwidth}P{0.0856115107913669\textwidth}P{0.15899280575539568\textwidth}P{0.14064748201438848\textwidth}}
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{34.002 37.734}\tabcellsep 33.421\tabcellsep 33.406\\
SSIM\tabcellsep 0.952\tabcellsep \tabcellsep 0.983\tabcellsep 0.968\tabcellsep 0.969\\
Runtime [s]\tabcellsep 3.546\tabcellsep \multicolumn{2}{l}{27.488}\tabcellsep 1.047\tabcellsep 1.048\\
Memory [MB]\tabcellsep 1.339\tabcellsep \tabcellsep 1.339\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_8}Table 10 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{9} \par 
\begin{longtable}{P{0.2125\textwidth}P{0.2367857142857143\textwidth}P{0.018214285714285714\textwidth}P{0.06071428571428571\textwidth}P{0.024285714285714285\textwidth}P{0.15785714285714286\textwidth}P{0.13964285714285715\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{28.948 29.143}\tabcellsep 28.602\tabcellsep 28.376\\
SSIM\tabcellsep \multicolumn{2}{l}{0.925}\tabcellsep \multicolumn{2}{l}{0.927}\tabcellsep 0.922\tabcellsep 0.920\\
Runtime [s]\tabcellsep \multicolumn{4}{l}{4.282 73.604}\tabcellsep 1.095\tabcellsep 1.093\\
Memory [MB]\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_9}Table 9 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{12} \par 
\begin{longtable}{P{0.2125\textwidth}P{0.2367857142857143\textwidth}P{0.018214285714285714\textwidth}P{0.06071428571428571\textwidth}P{0.024285714285714285\textwidth}P{0.15785714285714286\textwidth}P{0.13964285714285715\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{37.831 38.039}\tabcellsep 34.088\tabcellsep 33.958\\
SSIM\tabcellsep \multicolumn{2}{l}{0.983}\tabcellsep \multicolumn{2}{l}{0.984}\tabcellsep 0.970\tabcellsep 0.969\\
Runtime [s]\tabcellsep \multicolumn{4}{l}{2.725 31.751}\tabcellsep 1.052\tabcellsep 1.051\\
Memory [MB]\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\end{longtable} \par
 
\caption{\label{tab_10}Table 12 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{13} \par 
\begin{longtable}{P{0.30357142857142855\textwidth}P{0.1568452380952381\textwidth}P{0.015178571428571427\textwidth}P{0.07589285714285714\textwidth}P{0.020238095238095236\textwidth}P{0.14672619047619048\textwidth}P{0.13154761904761905\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
1 st Error Mask\tabcellsep \multicolumn{2}{l}{6.353}\tabcellsep \multicolumn{2}{l}{0.387}\tabcellsep 24.756\tabcellsep 24.442\\
2 nd Error Mask\tabcellsep \multicolumn{2}{l}{9.129}\tabcellsep \multicolumn{2}{l}{1.349}\tabcellsep 30.899\tabcellsep 30.888\\
3 rd Error Mask\tabcellsep \multicolumn{2}{l}{6.253}\tabcellsep \multicolumn{2}{l}{0.367}\tabcellsep 24.083\tabcellsep 23.885\\
4 th Error Mask\tabcellsep \multicolumn{4}{l}{13.647 1.179}\tabcellsep 31.431\tabcellsep 31.309\end{longtable} \par
 
\caption{\label{tab_11}Table 13 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{14} \par 
\begin{longtable}{P{0.3513966480446927\textwidth}P{0.2041899441340782\textwidth}P{0.01424581005586592\textwidth}P{0.01899441340782123\textwidth}P{0.1377094972067039\textwidth}P{0.123463687150838\textwidth}}
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
1 st Error Mask\tabcellsep \multicolumn{3}{l}{27.609 27.976}\tabcellsep 26.959\tabcellsep 26.666\\
\multicolumn{4}{l}{2 nd Error Mask 32.369 37.093}\tabcellsep 32.352\tabcellsep 32.370\\
3 rd Error Mask\tabcellsep \multicolumn{3}{l}{26.779 27.016}\tabcellsep 26.371\tabcellsep 26.106\\
4 th Error Mask\tabcellsep \multicolumn{3}{l}{37.188 37.430}\tabcellsep 33.065\tabcellsep 32.905\end{longtable} \par
 
\caption{\label{tab_12}Table 14 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{15} \par 
\begin{longtable}{P{0.16640211640211638\textwidth}P{0.22936507936507936\textwidth}P{0.04047619047619047\textwidth}P{0.08544973544973544\textwidth}P{0.17089947089947088\textwidth}P{0.15740740740740738\textwidth}}
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{35.249 43.100}\tabcellsep 38.577\tabcellsep 37.973\\
SSIM\tabcellsep 0.995\tabcellsep \tabcellsep 0.996\tabcellsep 0.994\tabcellsep 0.994\\
Runtime [s]\tabcellsep 1.642\tabcellsep \multicolumn{2}{l}{21.282}\tabcellsep 1.028\tabcellsep 1.023\\
Memory [MB]\tabcellsep 2.079\tabcellsep \tabcellsep 2.079\tabcellsep 2.079\tabcellsep 2.079\\
X\tabcellsep \multicolumn{2}{l}{21.359}\tabcellsep 2.017\tabcellsep 37.301\tabcellsep 36.897\\
Y\tabcellsep \multicolumn{3}{l}{35.073 42.928}\tabcellsep 38.346\tabcellsep 37.745\end{longtable} \par
 
\caption{\label{tab_13}Table 15 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{16} \par 
\begin{longtable}{P{0.1672872340425532\textwidth}P{0.22606382978723402\textwidth}P{0.040691489361702124\textwidth}P{0.08590425531914893\textwidth}P{0.17180851063829786\textwidth}P{0.15824468085106383\textwidth}}
\tabcellsep Fast\tabcellsep FSR\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{3}{l}{20.094 21.881}\tabcellsep 19.017\tabcellsep 18.872\\
SSIM\tabcellsep 0.959\tabcellsep \tabcellsep 0.964\tabcellsep 0.962\tabcellsep 0.958\\
Runtime [s]\tabcellsep 2.827\tabcellsep \multicolumn{2}{l}{60.066}\tabcellsep 1.051\tabcellsep 1.047\\
Memory [MB]\tabcellsep 1.188\tabcellsep \tabcellsep 1.188\tabcellsep 1.188\tabcellsep 1.188\\
X\tabcellsep 6.816\tabcellsep \tabcellsep 0.351\tabcellsep 17.407\tabcellsep 17.268\\
Y\tabcellsep \multicolumn{3}{l}{19.270 21.093}\tabcellsep 18.294\tabcellsep 18.079\end{longtable} \par
 
\caption{\label{tab_14}Table 16 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{17} \par 
\begin{longtable}{P{0.16640211640211638\textwidth}P{0.22936507936507936\textwidth}P{0.013492063492063491\textwidth}P{0.09444444444444444\textwidth}P{0.01798941798941799\textwidth}P{0.17089947089947088\textwidth}P{0.15740740740740738\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{45.019 45.497}\tabcellsep 30.784\tabcellsep 31.571\\
SSIM\tabcellsep 0.995\tabcellsep \tabcellsep \multicolumn{2}{l}{0.996}\tabcellsep 0.962\tabcellsep 0.967\\
Runtime [s]\tabcellsep 4.019\tabcellsep \tabcellsep \multicolumn{2}{l}{36.729}\tabcellsep 2.659\tabcellsep 2.133\\
Memory [MB]\tabcellsep 1.339\tabcellsep \tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\\
X\tabcellsep \multicolumn{2}{l}{11.146}\tabcellsep \multicolumn{2}{l}{1.234}\tabcellsep 11.137\tabcellsep 14.313\\
Y\tabcellsep \multicolumn{4}{l}{44.794 45.315}\tabcellsep 29.614\tabcellsep 30.529\end{longtable} \par
 
\caption{\label{tab_15}Table 17 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{18} \par 
\begin{longtable}{P{0.16640211640211638\textwidth}P{0.22936507936507936\textwidth}P{0.013492063492063491\textwidth}P{0.09444444444444444\textwidth}P{0.01798941798941799\textwidth}P{0.17089947089947088\textwidth}P{0.15740740740740738\textwidth}}
\tabcellsep Fast\tabcellsep \multicolumn{2}{l}{FSR}\tabcellsep Best\tabcellsep TELEA\tabcellsep NS\\
PSNR [dB]\tabcellsep \multicolumn{4}{l}{45.649 46.040}\tabcellsep 36.509\tabcellsep 36.417\\
SSIM\tabcellsep 0.997\tabcellsep \tabcellsep \multicolumn{2}{l}{0.998}\tabcellsep 0.987\tabcellsep 0.988\\
Runtime [s]\tabcellsep 1.744\tabcellsep \tabcellsep \multicolumn{2}{l}{13.549}\tabcellsep 1.163\tabcellsep 1.097\\
Memory [MB]\tabcellsep 1.339\tabcellsep \tabcellsep \multicolumn{2}{l}{1.339}\tabcellsep 1.339\tabcellsep 1.339\\
X\tabcellsep \multicolumn{2}{l}{26.096}\tabcellsep \multicolumn{2}{l}{3.391}\tabcellsep 30.984\tabcellsep 32.799\\
Y\tabcellsep \multicolumn{4}{l}{45.512 45.948}\tabcellsep 36.034\tabcellsep 35.979\end{longtable} \par
 
\caption{\label{tab_16}Table 18 :}\end{figure}
 \begin{figure}[htbp]
\noindent\textbf{19} \par 
\begin{longtable}{P{0.24452054794520545\textwidth}P{0.24452054794520545\textwidth}P{0.36095890410958903\textwidth}}
\tabcellsep With runtime as\tabcellsep Without runtime as\\
\tabcellsep a constraint\tabcellsep a constraint\\
Most effective\tabcellsep \tabcellsep \\
OpenCV\tabcellsep TELEA algorithm\tabcellsep FSR\textunderscore BEST\\
inpainting\tabcellsep \tabcellsep algorithm\\
algorithm\tabcellsep \tabcellsep \\
VI.\tabcellsep \tabcellsep \end{longtable} \par
 
\caption{\label{tab_17}Table 19 :}\end{figure}
 		 		\backmatter  			  				\begin{bibitemlist}{1}
\bibitem[Sreelakshmy and Kovoor ()]{b6}\label{b6} 	 		‘A Hybrid Inpainting Model Combining Diffusion and Enhanced Exemplar Methods’.  		 			I J Sreelakshmy 		,  		 			B C Kovoor 		.  	 	 		\textit{Journal of Data and Information Quality}  		2021. 13 p. .  	 
\bibitem[Singh and Shaveta ()]{b18}\label{b18} 	 		‘A Review on Patch Based Image Restoration or Inpainting’.  		 			K Singh 		,  		 			J Shaveta 		.  	 	 		\textit{International Journal of Computer Sciences and Engineering}  		2017. 5 p. .  	 
\bibitem[Farhan ()]{b1}\label{b1} 	 		‘A Review on Some Methods used in Image Restoration’.  		 			R Farhan 		.  	 	 		\textit{International Multidisciplinary Research Journal}  		2020. 10 p. .  	 
\bibitem[Chhabra et al. ()]{b12}\label{b12} 	 		‘An Analytical Study of Different Image Inpainting Techniques’.  		 			S Chhabra 		,  		 			R Lalit 		,  		 			S Saxena 		.  	 	 		\textit{Indian Journal of Computer Science and Engineering}  		2012. 3 p. .  	 
\bibitem[Telea ()]{b9}\label{b9} 	 		‘An Image Inpainting Technique Based on the Fast Marching Method’.  		 			A Telea 		.  	 	 		\textit{Journal of Graphics Tools}  		2004. 9  (1)  p. .  	 
\bibitem[Genser et al. ()]{b11}\label{b11} 	 		‘Demonstration of Rapid Frequency Selective Reconstruction for Image Resolution Enhancement’.  		 			N Genser 		,  		 			J Seiler 		,  		 			M Jonscher 		,  		 			A Kaur 		.  	 	 		\textit{the Proceedings of IEEE International Conference on Image Processing},  				2017.  	 
\bibitem[Hadhoud et al. ()]{b15}\label{b15} 	 		‘Digital Images Inpainting using Modified Convolution Based Method’.  		 			M M Hadhoud 		,  		 			K A Moustafa 		,  		 			S Shenoda 		.  	 	 		\textit{Optical Pattern Recognition XX},  				2009. 7340.  	 
\bibitem[Oliveira et al. ()]{b14}\label{b14} 	 		‘Fast Digital Image Inpainting’.  		 			M M Oliveira 		,  		 			B Bowen 		,  		 			R Mckenna 		,  		 			Y Chang 		.  	 	 		\textit{the Proceedings of International Conference on Visualization, Imaging and Image Processing},  				2001.  	 
\bibitem[Sethian ()]{b19}\label{b19} 	 		‘Fast Marching Methods’.  		 			J A Sethian 		.  	 	 		\textit{SIAM Review}  		1999. 41  (2)  p. .  	 
\bibitem[Yu et al. ()]{b8}\label{b8} 	 		‘Generative Image Inpainting with Contextual Attention’.  		 			J Yu 		,  		 			Z Lin 		,  		 			J Yang 		,  		 			X Shen 		,  		 			X Lu 		,  		 			T S Huang 		.  	 	 		\textit{the Proceedings of IEEE/CVF Conference on Computer Vision and Pattern Recognition},  				2018.  	 
\bibitem[Beniwal and Ahlawat ()]{b3}\label{b3} 	 		‘Image Inpainting Algorithms: A Survey’.  		 			A Beniwal 		,  		 			D Ahlawat 		.  	 	 		\textit{International Journal of Recent Research Aspects}  		2016. 3  (2)  p. .  	 
\bibitem[Vreja and Brad ()]{b13}\label{b13} 	 		‘Image Inpainting Methods Evaluation and Improvement’.  		 			R Vreja 		,  		 			R Brad 		.  	 	 		\textit{The Scientific World Journal}  		2014. 2014.  	 
\bibitem[Gaonkar et al. ()]{b7}\label{b7} 	 		‘Image Inpainting using Robust Exemplar-based Technique’.  		 			S R Gaonkar 		,  		 			P D Hire 		,  		 			P S Pimple 		,  		 			Y R Kotwal 		,  		 			B A Ahire 		.  	 	 		\textit{International Journal of Computer Sciences and Engineering}  		2014. 2 p. .  	 
\bibitem[Elharrous et al. ()]{b2}\label{b2} 	 		‘Image inpainting: A review’.  		 			O Elharrous 		,  		 			N Almaadeed 		,  		 			S Al-Maadeed 		,  		 			Y Akbari 		.  	 	 		\textit{Neural Processing Letters}  		2007-2028, 2019. 51.  	 
\bibitem[Hegadi ()]{b0}\label{b0} 	 		‘Image Processing: Research Opportunities and Challenges’.  		 			R S Hegadi 		.  	 	 		\textit{the Proceedings of National Seminar on Research in Computers},  				2010.  	 
\bibitem[Bertalmio et al. ()]{b10}\label{b10} 	 		‘Navier-Stokes, Fluid Dynamics, and Image and Video Inpainting’.  		 			M Bertalmio 		,  		 			A L Bertozzi 		,  		 			G Sapiro 		.  	 	 		\textit{the Proceedings of IEEE Computer Society Conference on Computer Vision and Pattern Recognition},  				2001.  	 
\bibitem[Algazin ()]{b20}\label{b20} 	 		‘Numerical Study of Navier-Stokes equations’.  		 			S Algazin 		.  	 	 		\textit{Journal of Applied Mechanics and Technical Physics}  		2007. 48  (5)  p. .  	 
\bibitem[Zhang et al. ()]{b4}\label{b4} 	 		‘Partial Differential Equation Inpainting Method Based on Image Characteristics’.  		 			F Zhang 		,  		 			Y Chen 		,  		 			Z Xiao 		,  		 			L Geng 		,  		 			J Wu 		,  		 			T Feng 		,  		 			P Liu 		,  		 			Y Tan 		,  		 			J Wang 		.  	 	 		\textit{Image and Graphics}  		2015. 9219 p. .  	 
\bibitem[Zhou et al. ()]{b5}\label{b5} 	 		\textit{Patch-based Texture Synthesis for Image Inpainting},  		 			T Zhou 		,  		 			B Johnson 		,  		 			R Li 		.  		 arXiv:1605.01576v1.  		2016.  	 
\bibitem[Awati and Patil ()]{b17}\label{b17} 	 		‘Review of Digital Image Inpainting Algorithms’.  		 			A S Awati 		,  		 			M R Patil 		.  	 	 		\textit{International Journal of Latest Trends in Engineering and Technology}  		2013. p. .  	 
\bibitem[Patel and Yerpude ()]{b16}\label{b16} 	 		‘Study and Analysis of Image Inpainting Algorithms’.  		 			K Patel 		,  		 			A Yerpude 		.  	 	 		\textit{International Journal of Engineering Research and Technology}  		2015. 3 p. .  	 
\end{bibitemlist}
 			 		 	 
\end{document}
