Robust Tensor Factorization for Color Image and Grayscale Video Recovery

Low-rank tensor completion (LRTC) plays an important role in many fields, such as machine learning, computer vision, image processing, and mathematical theory. Since rank minimization is an NP-hard problem, one strategy is that it is converted into a convex relaxation tensor nuclear norm (TNN) that requires the repeated calculation of time-consuming SVD, and the other is to convert it into some product of two smaller tensors that are easy to fall into the local minimum. In order to overcome the above shortcomings, we propose a robust tensor factorization (RTF) model for solving LRTC. In RTF, the noisy tensor data with missing entries is decomposed into low-rank tensor and noisy tensor, and then the low-rank tensor is equivalently decomposed into t-products (essentially vectors convolution) of two smaller tensors: orthogonal dictionary tensor and low-rank representation tensor. Meanwhile, the TNN of low-rank representation tensor is adopted to characterize the low-rank structure of the tensor data for preserving global information. Then, an effective iterative update algorithm based on the alternating direction method of multipliers (ADMM) is proposed to solve RTF. Finally, numerical experiments on image recovering and video completion tasks show the effectiveness of the proposed RTF model compared with several state-of-the-art tensor completion models.

Kilmer and Martin [16], Kilmer et al. [20] first propose t-SVD and its related mathematical theoretical framework and apply it to image deblurring. By defining the tensor tubal rank, Zhang et al. [18] introduce a TNN minimization model for tensor completion achieving the state-of-the-art video inpainting results. The exact tensor completion conditions are then analyzed in [21]. On the basis of further perfecting the TNN theory, Lu et al. [14], [22] extend the robust principal component analysis (RPCA) to the tensor RPCA (TRPCA) and apply it to image inpainting. These methods complement the unknown entries in the tensor data while utilizing TNN to preserve the low-rank structures. Since t-SVD is calculated during each iteration, they have a shortcoming that is very time-consuming, especially when the tensor size is large.
When LRTC based on tensor factors fills in missing entries, a low-rank structure of tensor data is characterized by some product of multiple factors with smaller sizes. For methods related to t-SVD decomposition, tensor factorbased LRTC has two representative methods. One is that Tubal-Alt-Min [23], in which entry missing tensor is parameterized as the t-product of two small tensors, and these two small tensor factors are updated alternately using tensor least squares minimization. The other is tensor completion by tensor factorization (TCTF) [12], which completes tensor completion by decomposing each frontal slice of the unknown tensor into two small matrix factors. These two methods, especially TCTF, not only have a fast calculation speed but also have state-of-the-art completion performance. However, these two methods cannot maintain the global structure information and are prone to fall into local minima. Especially when the proportion of missing entries is large, the complete performance is very poor.
In this paper, we propose a robust tensor factorization (RTF) model that can effectively overcome the above shortcomings for LRTC. In the RTF model, we first decompose the noisy tensor data with missing entries into low-rank tensor and sparse noise tensor, and low-rank tensor is equivalently decomposed into the t-product of two smaller tensors called dictionary tensors and low-rank representation tensors respectively. This equivalent decomposition not only preserves the global low-rank structure in the tensor data but also inherits the property of fast computation of tensor factorization method. In addition, as a special case, if tensor data X reduces to a matrix, all the tensor factors reduce to the matrix cases. Our model reduces to the model of paper [24]. Therefore, our model is the tensor-based generalization of matrix-based factorization in [24]. The main contributions of this paper are summarized as follows: 1) On the basis of t-product, the low-tubal-rank tensor is equivalently decomposed into the t-product of dictionary tensor and low-rank representation tensor.
2) The TNN constraint on low-rank representation tensor can effectively describe the global structures of tensor data. Meanwhile, tensors with small sizes can improve the computational speed of the algorithm.
3) An efficient iterative update algorithm based on the alternating direction method of multipliers (ADMM) is used for our RTF optimization, and the convergence of the algorithm can also be guaranteed. 4) Compared with other state-of-the-art tensor completion methods, numerical experiments on image recovering and video inpainting tasks demonstrate the effectiveness of our method.
The rest of the paper is structured as follows. We give some notations and related work in Section II. Discrete fourier transformation (DFT) and preliminaries are shown in Section III. Section IV provides the RTF method, the optimization details, convergence and complexity analysis. Extensive numerical experiments on real data are described and analyzed in Section V. Finally, we conclude this work in Section VI.

II. RELATED WORK
Some notations used in this paper are summarized in Table 1 and then review previous work. There are various techniques for tackling the LRTC problem. According to the different decomposition methods of tensor and the definition of tensor rank, the current popular LRTC method can be roughly divided into three categories.
LRTC based on CP decomposition is to complete missing entries under the constraint of low CP rank. Due to CP rank is generally NP-hard to compute [28], [29], the LRTC problems of rank minimization are often converted into factor problems to predict missing entries. By expanding the given tensor into matrices along all modes, Xu et al. [10] propose the TMac model to recover the missing entries. Subsequently, Bengua et al. [30] suggest the TMacTT model complete missing elements. The difference from TMac is that the tensor rank is first estimated by using tensor train technology. In order to take into account uncertainty information of latent factors, Zhao et al. [9] present fully Bayesian CP factorization (FBCP) and its extension using mixture prior (FBCPMP). However, the CP factorization scheme is prone to overfitting which resulting in severe deterioration of predictive performance. Besides, the CP rank is generally NP-hard to compute.

B. TUCKER DECOMPOSITION
Tucker decompositoin methods [7] based on Tucker rank [31]. The Tucker decomposition of tensor X as following where U (i) ∈ R n i ×m i , and G ∈ R m 1 ×m 2 ×...×m k is the core tensor, the symbol × i is the i-way (matrix) product. For example, if i = j, for above tensor G and a matrix U (j) ∈ R n j ×m j where Y ∈ R m 1 ×...×m j−1 ×n j ×m j+1 ×...×m k . The Tucker rank of the tensor X is a k-dimensional vector determined by the rank of tensors mode-i matricization X (i) , denoted as rank tc = (rank(X (1) ), . . . , rank(X (k) )).
Using multilinear operations, a k-way tensor can be represented as k factor matrices and a core tensor by Tucker decomposition. Due to the Tucker rank defined on the matrix rank, most LRTC methods based on Tucker rank are closely related to the low-rank matrix completion method. Liu et al. [8] define the TNN as the weighted sum of traces norms of flattening matrices and propose three LRTC models to complete visual data. By performing Riemannian optimization techniques on the manifold of tensors, Kressner et al. [7] propose a geometric nonlinear conjugate gradient (GeomCG) for fitting the factors of Tucker decomposition. In order to obtain a compact representation with the smallest core tensor, Yang et al. [32] utilize a group-based log-sum penalty function to discover the structural sparsity of core tensor. In order to reduce the computational cost, Tan et al. [33] suggest a multi-linear low-n-rank factorization model that only requires solving a linear least squares problem per iteration. However, a conceptual drawback of Tucker rank is that its entries are ranks of flattening matrices of the tensor. Due to the upper bound of each rank is usually independent and small, Tucker rank may not be suitable for capturing global (spatial and temporal) information of the tensor.

C. T-SVD DECOMPOSITION
T-SVD decomposition methods [12], [14] based on tubal rank [20]. For the definition of t-SVD, refer to Section III. Compared with the first two categories of LRTC methods, t-SVD-based methods have been shown to be superior in capturing the spatial correlation in real-world data [16]- [20], [34]. Similar to the matrix SVD, t-SVD decomposes a tensor into three tensors on the basis of tensor-tensor product (t-product). Based on the t-product [16] and associated algebraic constructs, any tensor has the t-SVD [20] motivates a new tensor rank referred to as the tubal rank [16], [17], provide a new framework to measure the low-rank structure of tensor. Semerci et al. [35] introduce two TNNs as regularization for the energy selective multi-energy computed tomography problem. Zhang et al. [18] propose tensor completion based on TNN achieves state-of-the-art video inpainting, and the exact tensor completion conditions are demonstrated in [21]. Apart from these, Lu et al. [22] present a solution to tensor decomposition using t-SVD and demonstrated the multi-linear data recovery from sparse noise. Subsequently, a more complete theoretical framework and experiments are presented in [14]. However, these methods all require iterative calculations to obtain the final result, and each iteration has to perform more than one time-consuming SVD.

III. PRELIMINARIES
In this part, we first introduce the discrete fourier transform that is closely related to the t-product, and then present t-SVD and tensor nuclear norm.

A. DISCRETE FOURIER TRANSFORMATION
The Discrete Fourier Transformation (DFT) plays a core role in t-product between tensors, For a vector v ∈ R n , its DFT is denoted asv and is given bȳ where F n is the DFT matrix defined as where ω = exp(−2πi/n) and i = √ −1. Then Thus F −1 n = F * n /n. Moreover, F n / √ n is an orthogonal matrix. Indeed, we can computev directly by the Matlab command fft, i.e.,v = fft(v), and use the inverse DFT to obtain v = ifft(v). Denote the circulant matrix of v as It is known that it can be diagonalized by the DFT matrix, i.e., where Diag(v) denotes a diagonal matrix with its i-th diagonal entry asv i .

B. T-SVD AND TENSOR NUCLEAR NORM
For a tensor X ∈ C n 1 ×n 2 ×n 3 , letX ∈ C n 1 ×n 2 ×n 3 represent the result of DFT of X along the 3-rd dimension, i.e., each tubeX (i, j, :) ofX is obtained by DFT of the corresponding tube X (i, j, :) of X .X ∈ C n 1 n 3 ×n 2 n 3 is used to denote a block diagonal matrix with its i-th block on the diagonal as the i-th frontal sliceX (i) of X , i.e., where bdiag(·) is an operator which maps the tensorX to the block diagonal matrixX. We further define the block circulant matrix bcirc(X ) ∈ C n 1 n 3 ×n 2 n 3 of X as . . . X (2) X (2) X (1) . . . X (3) Illustration of the t-SVD of an n 1 × n 2 × n 3 tensor.
where the unfold(·) operator maps a tensor X to a matrix and fold(·) is its inverse operator. Definition 1 (T-Product [16]): Let X ∈ R n 1 ×l×n 3 and Y ∈ R l×n 2 ×n 3 . Then the t-product X * Y is defined to be a tensor of size n 1 × n 2 × n 3 , (6) Lemma 1 [36]: Suppose that X ∈ R n 1 ×l×n 3 , Y ∈ R l×n 2 ×n 3 are two arbitrary tensors, and Z = X * Y. Then, the following properties hold.
1) X 2 F = X 2 F ; 2) Z = X * Y andZ =XȲ are equivalent to each other. Definition 2 (Transpose and F-Diagonal Tensor [36]): The transpose of a tensor X ∈ R n 1 ×n 2 ×n 3 is the tensor X * ∈ R n 2 ×n 1 ×n 3 obtained by transposing each of the frontal slices and then reversing the order of transposed frontal slices 2 through n 3 and a tensor is called f-diagonal if each of its frontal slices is a diagonal matrix. Definition 3 (Identity and Orhtogonal Tensor [36]): The identity tensor I ∈ R n×n×n 3 is the tensor with its first frontal slice being the n × n identity matrix, and other frontal slices being all zeros and a tensor Q ∈ R n×n×n 3 is orthogonal if it satisfies Q * Q * = Q * * Q = I. Now we introduce the recently propsed t-SVD which based on t-product, a new tensor decomposition framwork. See Figure 1 for an illustration.
Theorem 1 (T-SVD [16]): Assume that X ∈ R n 1 ×n 2 ×n 3 is a 3-way tensor. Then it can be factored as where U ∈ R n 1 ×n 1 ×n 3 and V ∈ R n 2 ×n 2 ×n 3 are orthogonal tensors, and S ∈ R n 1 ×n 2 ×n 3 is a f-diagonal tensor. Definition 4 (Tensor Tubal Rank and Nuclear Norm [14]): For tensor X ∈ R n 1 ×n 2 ×n 3 , let X = U * S * V * be the t-SVD of X , the tubal-rank rank t (X ) is defined as the number of nonzero singular tubes of S, i.e., The tensor nuclear norm X * is defined as where r = rank t (X ). Lemma 2 [14]: For tensor X ∈ R n 1 ×n 2 ×n 3 , the following properties hold.

IV. RTF MODEL
In this section, we first give the proposed robust tensor factorization model for LRTC, then introduce an iterative alternating method for RTF optimization, and finally discuss the relationship between RTF and related low-rank tensor methods and analyze its complexity.

A. ROBUST TENSOR FACTORIZATION MODEL
Given a tensor X ∈ R n 1 ×n 2 ×n 3 that only knows some entries, if we use to denote the set of the index of the observed entries, the general model of low-rank tensor completion problem is to find a low-rank tensor to fill in the missing values of tensor X under the of its entries If we use the tubal tank to measure the low-rankness of tensor, the tensor completion problem is to solve an optimization problem as follows where P is the linear operator that extracts entries in and fills the entries not in with zeros, L ∈ R n 1 ×n 2 ×n 3 is the estimated tensor. It has been proved that tubal rank minimization is a good measure of three-dimensional sparsity. However, due to the discrete nature of the tubal rank function, the optimization problem of (11) is NP-hard. Like solving the rank optimization problem for matrices, an efficient and tractable approach is to relax the tensor tubal rank rank t (L) into tensor nuclear norm L * . In addition, considering the noise in the model, the problem (11) is changed over to the following robust optimization problem where tensor 1 -norm · 1 used to measure the noise, E is the noise tensor, and λ ≥ 0 is a regularization parameter to balance the tubal rank of the estimated tensor and the noise. If all entries in X are observable, Eq. (12) is the objective function of TRPCA [14]. Inspired by the equivalent transformation of matrix factorization in the matrix nuclear norm, we expect that the lowtubal rank tensor L ∈ R n 1 ×n 2 ×n 3 is equivalently converted into the t-products with two small low-rank tensors A ∈ R n 1 ×d×n 3 , and Z ∈ R d×n 2 ×n 3 , i.e., L = A * Z, where d is an upper bound on the tubal rank of L, i.e., d ≥ r = rank t (L).
In this decomposition, A is always regarded as a dictionary, Z is the new representation tensor of the tensor X under the dictionary A, if dictionary A is an orthogonal tensor, i.e., A * * A = I. Then, by using the Lemma 3, the problem (12) is converted to the following equivalent problem In the above model, the results of two small tensor t-product are used to estimate the low-rank structure of tensor data, and the 1 -norm that is robust to noise is used to measure the model error. Therefore, we call the tensor completion model (13) as the robust tensor factorization (RTF) model.
In fact, the solution of our proposed RTF in model (13) is equivalent to the solution of model (12), which is proved in Theorem 2.
Lemma 3: Let X ∈ R n 1 ×d×n 3 and Y ∈ R d×n 2 ×n 3 are two tensors, where X is a orthogonal tensor, i.e., X * * X = I, then we have X * Y * = Y * .
Proof: Let the t-SVD of Y be Y = U * S * V * , according the definition of the tensor nuclear norm, we can easily obtain Theorem 2: Suppose (L , E ) is a solution of the model (12) with rank t (L ) = r, then there exists the solution Z ∈ R d×n 2 ×n 3 and E ∈ R n 1 ×n 2 ×n 3 to the model (13) with d ≥ r, such that (A * Z , E ) is also a solution to the model (12), where A ∈ R n 1 ×d×n 3 is an orthogonal tensor, i.e., A * * A = I. Proof: If (L , E ) is a solution to the optimization problem (12), and rank t (L ) = r, by implementing t-SVD on tensor L , we can easily find an orthogonal tensor A ∈ R n 1 ×d×n 3 and a tensor Z ∈ R n 1 ×d×n 3 satisfying A * Z = L and P (X ) = P (A * Z + E ), where d ≥ r, E = E . In addition, according to Lemma 3, we have The proof is completed.

B. OPTIMIZATION OF RTF
In order to solve the problem conveniently, we set the unknown entries in the given tensor data X to zeros, i.e., X ⊥ = 0, where ⊥ is the complement of . This means that any value can be taken in X ⊥ such that P ⊥ (X ) = P ⊥ (A * Z + E). Therefore, the constraint with the operator P in (13) is simplified into X = A * Z + E. Hence, the problem (13) is transformed into the following equivalent problem min E,Z,J Then, we resort to augmented Lagrangian multiplier method and the corresponding Lagrangian function as following where µ is a penalty parameter improve convergence, Y 1 and Y 2 are Lagrange multipliers. Then, we carry out the alternating direction method of multipliers (ADMM) [37] to update E, Z, and J sequentiality, i.e. updating one of the three variables while fixing others. Update J : The Lagrangian function (16) is unconstrained, so the minimization of Eq. (16) with respect to J involves the following where P = (Z + Y 2 /µ). The above problem (17) can be transformed into the complex number domain and solved. By the properties of Lemma 1, the equivalent problem of problem (17) as follows SinceJ is a block-diagonal matrix, the problem (18) can be solved by the following equivalent problem min J (i) which can be solved by the singular thresholding (SVT) operator. The SVT operator S η is defined as where X = U V * is the singular value decomposition, and η (x) = sgn(x) max(abs(x) − η, 0) is the shrinkage operator. Then, the closed-form solution of problem Eq. (19) arē then, we finally get J = ifft(J , [], 3).
Update Z: Optimization Eq. (15) with respect to Z as follows where R 1 = X − E + Y 1 /µ, and R 2 = −J + Y 2 /µ. Problem (22) is a convex function for the variable Z. Therefore, let Eq. (22) directly differentiate the variable Z and make its result equal to zero. We can get the following equation From the above equation, it is easy to get the solution about the variable Z as following Update E: Optimizing Eq. (15) with respect to E is converted to the following problem where Q = X − A * Z + µ −1 Y 1 . The problem (24) can be solved by the following two subproblems with respect to E and E ⊥ , respectively. For E , the optimization problem (24) is formulated as following By the element-wise shrinkage operator η (x), the closed form solution of problem (25) as follows For E ⊥ , the subproblem with respect to E ⊥ as following which is a convex function with respect to E ⊥ , we can obtain the closed-form solution by zeroing the gradient of the objective function (27), i.e., Update Y 1 , Y 1 , and µ: (29) VOLUME 8, 2020 Algorithm 1 Robust Tensor Factorization for Low-Rank Tensor Completion (RTF) 1: Input: data tensor X ∈ R n 1 ×n 2 ×n 3 , dictionary tensor A ∈ R n 1 ×d×n 3 observed set , parameter λ, = 1e − 4. 2: Output: Z ∈ R d×n 2 ×n 3 . 3: Initialize: Z 0 , E 0 , J 0 , Y 1 0 , and Y 2 0 ; 4: While not converged do; 5: Update each frontal sliceJ (i) , and parameter µ t+1 by Eq. (29); 9: check the convergence conditions: After updating, we check the stopping criterion that the maximum updating difference is less than a predefined threshold .
In summary, the whole procedure of ADMM for solving Eq. (15) is given by Algorithm 1.

C. CONVERGENCE AND COMPLEXITY
In this section, we analyze the convergence property and the complexity of the proposed method. For convenience, we rewrite the objective function (13) of RTF by assuming the fully-observed data, i.e., w ijk = 1 for all i, j, k, the Eq. (13) is changed to follows which is the model of TLRR and its convergence has been proved [38]. According to Lemma 3, and let E = X − L, then Eq. (30) is coverted to the following min L,E The Eq. (31) is the objective function of TRPCA [14]. Therefore, if all the entries in the tensor data are known, the objective functions (30) of RTF or TLRR and TRPCA are essentially equivalent. In fact, the proof of TRPCA and TLRR convergence are also valid for tensor completion problems (12) and (13) where only a part of the entries are known.
The main cost of ADMM for solving (15) is to compute J , Z, and E. Assuming without loss of generality that X ∈ R n 1 ×n 2 ×n 3 and n 1 > n 2 , the time compexity for J involves the n 3 SVD on matrices with size d × n 2 , the total cost is O(d 2 n 2 n 3 ). The update of Z in Eq. (23) involves t-product and inversion of tensor, the total computational cost is O(d(n 1 + n 2 )n 3 log(n 3 ) + dn 1 n 2 n 3 ). The computation cost for E involves the calculation of A * Z and the update which is O(n 1 n 2 n 3 (d +log n 3 )). The total time complexity for solving the RTF problem is O(tn 1 n 2 n 3 (d + log n 3 )), where t is the number of iterations.

V. EXPERIMENTS
In this section, we conduct numerical experiments to evaluate the effectiveness of our method RTF. We compare it with other state-of-the-art tensor completion methods on color image recovering and grayscale video recovering tasks. The recovering task is to fill in the missing pixel values of a partially observed image or video. All the simulations are conducted on the platform Matlab 2019a under Windows 10 with an Intel Xeon E3-1505M 3.00 GHz CPU and 64 GB memory.

A. COMPARISON METHODS
In each dataset, we evaluate the effectiveness of the proposed RTF and the following state-of-the-art low-rank tensor completion methods on color image recovering and grayscale video recovering tasks. 1) GeomCG 1 : [7] performs tensor completion by developing a Riemannian optimization on the low-rank tensor manifold based on Tucker decomposition. 2) TenALS 2 : [11] presents a novel alternating minimization method to efficiently and exactly reconstruct a lowrank tensor based on CP decomposition. 3) TMac 3 : [10] recovers a low-rank tensor by simultaneously performing low-rank matrix factorizations to the all-mode matricizations of the underlying tensor. 4) TMacTT 4 : [30] firstly estimates the tensor rank by the tensor train technology, and then factorizes each modular matrix to complete the tensor completion. 5) LRTC 5 : [8] generalizes the matrix trace norm to tensor trace norm and presents a convex optimization problem for tensor completion. 6) FBCP and FBCPMP 6 : [9] proposes two versions: FBCP and FBCPMP, the former is fully Bayesian CP factorizaton using a hierarchical probabilistic model while the lattter is its extension using mixture prior. 7) TRPCA 7 : [14] firstly defines the tensor tubal rank to measure the low-rankness of tensor, and then generalizes the matrix RPCA to the tensor RPCA for tensor completion. 8) TCTF 8 : [12] proposes a novel low-rank tensor completion method by factorizing the tensor into the t-product of two tensors with smaller sizes.
The code of all these compared methods are provided by their corresponding authors. Assume thatX is the recovered tensor of X ∈ R n 1 ×n 2 ×n 3 , the peak signal-to-noise ratio (PSNR), i.e., is employed to evaluate these methods.

B. PARAMETERS SETTING
In these comparison algorithms and our proposed RTF, there are some parameters that need to be set in advance. For a given 3-way tensor X ∈ R n 1 ×n 2 ×n 3 , before sampling missing values we first generate a noise tensor E whose entries are sampled from Gaussian distribution N (0, σ 2 ), and then add E on X as testing tensor. For testing tensor, entries with sampling rate θ are randomly selected as known entries, and the remaining entries are unknown entries and set to zero. The sampling rate θ ranges from 10% to 50% in steps of 10%. In the experiment, the standard deviation σ takes values of 0, 5, and 10. It is obviously a noiseless situation if σ = 0. Following [7], the Tucker rank is set as rank tc = (10, 8, min(6, n3)). CP rank is set as rank cp = 5 like in [11]. For TMac [10], the weights parameter are set as α 1 = α 2 = α 3 = 1/3, the minimum and maximum CP rank are set as r min = 5 and r max = 30, respectively. The weight parameter α = γ /|γ | 1 , where γ = [1, 1, 10 −3 ], and the penalty coefficient β is set as β = [0.1, 0.1, 0.1] for LRTC [8]. The initial rank is set to 100 in FBCP and FBCPMP [9]. In [12], the minimum and maximum rank are set to r min = (25, 5, 5) and r max = (50, 20, 20), respectively. The regularization parameter λ in TRPCA [14] and our proposed RTF is set as λ = 1/ √ max(n 1 , n 2 )n 3 . For all compared methods, the tolerable error is set to = 1e − 4.

C. COLOR IMAGE RECOVERING
Color images are nature 3-way tensors. The Kodak dataset 9 contains a wide variety of natural scenes. This dataset is often used to evaluate various tasks of image processing, such as image denoising, image inpainting, and image segmentation. It has a total of 24 color images with size 768 × 512 × 3. We cropped all images to size with 500 × 500 × 3 in the experiment. As pointed out by many works [8], [19], [39], [40], image approximately lie on a low-rank subspace and low-rank constraints can effectively reveal the low-rank structure of visual data. Therefore, the recovering performance 9 http://r0k.us/graphics/kodak/ is evaluated by comparing the PSNR values between the repaired image obtained by various algorithms and the ground truth.
The average PSNR values of all methods with different sample rates are shown in Figure 3, the corresponding average PSNR values are displayed at the top of each bar. Due to FBCP and FBCPMP are from the same paper [9], and the PSNR of FBCP for images is higher, we only show the recovering results of FBCP. In Figure 3, we can find that the average PSNR value of the proposed RTF is consistently higher than other comparison algorithms at five different sample rates. When the sample rate θ changes from 10% to 50%, the average PSNR corresponding to RTF is higher than the second TRPCA by 0.40 dB, 0.54 dB, 0.64 dB, 0.68 dB, and 0.60 dB, respectively. According to the corresponding average PSNR value, from high to low, under these five sample rates, the second place is TRPCA, and the third and fourth places are FBCP and TMacTT, respectively. The two worst algorithms are GeomCG and TMac.
For noisy situations, due to space constraints, we only give the PSNR values obtained by all comparison algorithms for recovering 4 images when the sample rate θ = 20%, 30%, and σ = 0, 5, 10 in Table 2. The running time with sampling rate 20% for these 4 noiseless images are demonstrated in Table 3. Figure 4 shows the recovering results of the frist two testing images. It can be seen from Table 2 that the repair performance of RTF has always been higher than other algorithms on all images. The algorithm in the second place has changed for different types of images, some are TRPCA, some are FBCP, and some are TMacTT. However, the worst algorithm has always been GeomCG and TMac. From the recovering results in Figure 4, the proposed RTF corresponds to the highest PSNR value, and the clearest repair images are also obtained, which is also very good for small targets, such as eyes and trees. In general, the four algorithms RTF, TRPCA, FBCP, and TMacTT can restore clearer images. The images restored by the three algorithms TCTF, TenALS, and LRTC have obvious streaks, and TMac cannot estimate a large number of missing pixels.

D. VIDEO RESTORATION
A grayscale video is essentially a 3-order tensor. We conduct experiments on the YUV Video Sequences 10 database which is widely used in video recovering. All 18 videos with provided QCIF format in the dataset are used to evaluate the recovering ability of the proposed RTF and comparison algorithms to repair the video data. Each video sequence contains at least 150 frames, we only utilize 30 frames of sequence for the experiment due to the computational limitation. In experiments, we convert color each frame into grayscale, and thus the sequences can be formated as 3-way tensors with size 144 × 176 × 30. See the first column on the left Figure 6 for four video sequences.  The generation method of the video testing tensor is consistent with the image restoration method. For a video with n 3 sequences and each frame has size n 1 × n 2 , we construct a testing tensor X ∈ R n 1 ×n 2 ×n 3 and randomly set θn 1 n 2 n 3 entries to be observed. In the case of 5 sampling rates, the average PSNR values corresponding to the restoration results of all 18 noiseless videos by various algorithms are shown in Figure 5. Table 4 demonstrates the PSNR values  Comparison of the noiseless video recovering performance. We apply the compared methods to recover the videos by 10% ∼ 50% sample ratio in YUV dataset and report the average PSNR values on the 18 videos. Best viewed in ×2 sized color pdf file.
corresponding to the recovering results of all algorithms on 4 videos with different sampling rate and Gaussian noise. The noiseless restoration results of one frame in 4 videos are shown in Figure 6, and the corresponding running times are exhibited in Table 5. It should be pointed out that the TMacTT algorithm needs to train a core tensor of unknown size and order when processing video, and different videos require different core tensors. Therefore, in the comparison experiment of video inpainting, the TMacTT was replaced with the FBCPMP. Regardless of the change in sample rate VOLUME 8, 2020   θ or standard deviation σ of Gaussian noise, it can be seen from Figure 5 and Table 4 that consistent with the image recovering results, in most cases, the proposed RTF can obtain the highest PSNR value in video restoration in these comparative algorithms. When the sample rate is 20%, it can be found from Figure 5 that RTF can get the best results in these 18 video recovering experiments. The worst performing algorithms in video repair are GeomCG and TCTF. From the recovering results in Figure 6, we can find that RTF and TRPCA can get the best recover results, and FBCP can also get better recovering frames, but there are more mosaics in the recovery of the fourth complex video Mobile. The repair results of FBCPMP are all blurred, the recover frames of TMac are greatly blurred, and the repair frames of LRTC are more streaked. GeocCG and TCTF cannot get the correct repair results.

E. RESULTS AND ANALYSIS
The following conclusions can be drawn from the above tables and figures.
1) Whether in the image recovering or in the video restoration, the proposed RTF can always get the highest PSNR value among all the comparison algorithms. This shows that the proposed RTF can well describe the essential low-rank structure of tensor data, and simultaneously fill the unknown entries.
2) These methods can be divided into four categories: i.e., a) Tucker decomposition, GeomCG; b) CP factorization, TenALS, TMac, TMacTT, FBCP, and FBCPMP; c) Matrix nuclear norm, LRTC; d) t-SVD decomposition, TRPCA, TCTF, and proposed RTF. Essentially, both TRPCA and RTF use TNN that can effectively maintain global information to characterize the low-rank structure of tensor data, while TCTF only uses tensor factorization.
3) Since t-SVD can effectively describe the spatial information between different dimensions of tensor data, the performance of RTF and TRPCA based on t-SVD are better than other algorithms. The performance of TCTF is poor although it is also based on t-SVD decomposition, because factorization destroys the global structure of tensor data. Especially if the sample rate is low. In terms of running time, RTF is nearly 4 times faster than TRPCA in image restoration, while in video restoration they are almost the same. 4) Regardless of the matrix nuclear norm or TNN to describe the low-rank structures of data, these algorithms can effectively maintain the global information of the data and have good recovering ability. The algorithm that characterizes low-rank structure only by factor decomposition tends to have poor data recovery ability because it is easy to fall into local minima.

F. CONVERGENCE ANALYSIS
In section IV, we analyze that the optimal solution of our proposed RTF and TRPCA are equivalent. In addition, when all the entries of data are known, the objective function of RTF is essentially consistent with TLRR. Since TRPCA and TLRR have been proven to be able to convergence to the optimal solution, therefore, the proposed RTF must converge. In Figure 7, we give the convergence error of RTF in each iteration of the first 6 images and the first 6 videos. The error is defined as the maximum value of changes in convergence conditions in algorithm 1. According to Figure 7, we can discover that the error decreases rapidly with the number of iterations. When tolerable error = 1e − 4, whether it is an image or a video, our algorithm can converge in 70 iterations. The error keeps decreasing with the increase of iterations, especially when the number of iterations is greater than 30, the error decreases quickly and is stable. In fact, we found that when the number of iterations is greater than 30, the PSNR value corresponding to the tensor data recovered by RTF is almost in a stable state. In other words, if the number of iterations is set to 30 or the convergence error is set to 1e − 2, RTF can achieve the results given in the experiment. It is set to 1e − 4 in the paper, just to be consistent with the comparison algorithms.

VI. CONCLUSION
In this paper, we propose a robust tensor factorization (RTF) framework for the tensor completion problem. Unlike existing low-rank tensor factorization methods, the proposed RTF can not only address large-scale tensor completion problem by using tensor factorization but can also preserve the global information of tensor data. Firstly, on the premise of considering the existence of sparse noise in tensor data, we characterize the low-rank structures of tensor data by the t-product of two tensors with small sizes for tensor completion. Then, we propose an iterative algorithm based on ADMM to solve RTF. While giving the relationship between RTF and existing algorithms, we also analyze the convergence of RTF. Finally, the effectiveness of the RTF is verified in comparison with the state-of-the-art methods in both real-world image restoration and video recovering.