Keywords

1 Introduction

Tensor decompositions became recently the object of numerous research works [1]. The main kinds of the tensor decompositions could be divided into two basic groups: statistical and deterministic. In the group of the statistical methods for tensor decomposition are various multilinear extensions of the matrix-SVD, called Multilinear SVD (MSVD), or generalizations of the SVD matrix for higher-order tensors, called Higher-Order SVD (HOSVD) [2,3,4]. In [5] is offered a version of HOSVD, namely the multi-way tensor SVD. Such are also the famous methods: CANDECOMP/PARAFAC or Canonical Polyadic Decomposition (CPD) where the tensor is represented as a sum of rank-one tensors; the Tucker Decomposition (TD) [3]; the Tensor Train Decomposition (TTD) [6]; the Kruskal decomposition, etc. The statistical methods are implemented through applying various algorithms for calculation of the tensors eigen vectors, which have relatively high computational complexity. The tensor decomposition components are usually calculated by using iterative methods whose iterations stop, when the predefined accuracy is achieved. Such are: the tensor power iteration; the QR-factorization followed by the Householder transforms (or the Gram-Schmidt process), the Givens rotations; the Jacobi method; the Higher-Order Eigenvalue Decomposition (HOEVD); the SVD calculation based on its relation to PCA, etc. The tensor decomposition based on the use of iterative SVD methods needs significant number of computational operations. To overcome the problem, various hierarchical methods are already developed, based on the Hierarchical Tucker Decomposition (HTD) [7], the Sequentially Truncated HOSVD (ST-HOSVD) [8], the Sequential Unfolding SVD (SUSVD) [9] and Compositional Hierarchical Tensor Factorization [10]. To same group also belongs the non-iterative Hierarchical SVD algorithm for tensor decomposition offered in [11]. It has lower computational complexity and is based on SVD for elementary tensor of size 2 × 2 × 2.

In the group of the deterministic tensor decomposition methods are the pyramidal 3D transforms: the 3D Discrete Wavelet Transform (3D-DWT) [12], the 3D Curvelet and the 3D Contourlet Discrete Transform (3D-CDT) [13, 14] and the 3D Shearlet Discrete Transform (SDT) [15]. The methods from the first group overcome these from the second in respect of the decomposition components’ decorrelation degree, but these in the second group have much lower Computational Complexity (CC). The deterministic methods for tensor decomposition are usually executed by using various kinds of 3D orthogonal transforms. In publications [12, 14] are proposed algorithms for cubical decomposition based on the 3D separable discrete transforms: the 3D Discrete Fourier Transform (3D-DFT), the 3D Discrete Hartley Transform (3D-DHT), the 3D Discrete Cosine Transform (3D-DCT), etc.; the algorithm for hierarchical third-order tensor decomposition with low CC, based on the multi-level 3D Inverse Difference Pyramid (3D-IDP) and the 3D Walsh-Hadamard Transform (3D-WHT), presented in [16, 17]. The last-mentioned decomposition is not able to ensure sufficient decorrelation degree for its elements in the high hierarchical levels for high number of levels, i.e., for tensors of large size.

In this work is generalized the 3D-IDP tensor decomposition, called 3D Adaptive Branched IDP (3D-ABIDP). It is aimed at the achievement of high efficiency in the decomposition of large-size tensors (for example, sequences of 4K images) without significant increase of its CC.

2 Hierarchical Tensor Decomposition Through 3D Adaptive Branched IDP

The building unit in the offered decomposition is the n-level 3D-IDP, based on the 3D-WHT. The 3D-IDP/WHT pyramid is explained through an example for the hierarchical decomposition of the tensor X of size 8 × 8 × 8, for n = 3.

2.1 Hierarchical Decomposition for a Tensor of Size 8 × 8 × 8, Through 3D-IDP/WHT

The tensor X with elements x(i, j, k) and of size 8 × 8 × 8 could be represented through the 3-level 3D-IDP based on the Truncated 3D-WHT (3D-TWHT) for levels p = 0, 1, 2, as shown in Fig. 3.1.

Fig. 3.1
figure 1

3D-IDP for a tensor X of size 8 × 8 × 8

In this case, the decomposed tensor X is presented as a sum of three tensors, \({\tilde{\mathbf{X}}}\,,{\tilde{\mathbf{E}}}_{0}^{{}} ,{\mathbf{E}}_{{1}}^{{}} ,\) each of size 8 × 8 × 8 [15]:

$${\mathbf{X}} = {\tilde{\mathbf{X}}}\, + \,{\tilde{\mathbf{E}}}_{{\mathbf{0}}} + \,{\mathbf{E}}_{{\mathbf{1}}}$$
(3.1)

where:

\({\tilde{\mathbf{X}}} = {\kern 1pt} (1/8^{3} )\sum\limits_{{{\text{u}} = 0}}^{1} {\sum\limits_{{{\text{v}} = 0}}^{1} {\sum\limits_{{{\text{l}} = 0}}^{1} {{\text{s(}}{\text{u,}}{\text{v}}{,}{\text{l)}}{\mathbf{W}}_{{{\mathbf{u,v,l}}}} } } }\) is the tensor which is the first approximation of the input tensor;

\({\mathbf{E}}_{{0}} = {\mathbf{X}} - {\tilde{\mathbf{X}}}\)—the difference tensor, which represents the error of the first approximation;

\({\tilde{\mathbf{E}}}_{{0}} = \bigcup\limits_{{{\text{t}} = {1}}}^{{8}} {{\tilde{\mathbf{E}}}_{{0}}^{{\text{t}}} }\)—tensor, which is the first approximation of the tensor E0, after uniting the sub-tensors \({\tilde{\mathbf{E}}}_{{0}}^{{\text{t}}}\) each of size 4 × 4 × 4, for t = 1, 2, …, 8. All they are obtained through dividing the difference sub-tensor E0 into 8 sub-tensors. Here, each tensor \({\tilde{\mathbf{E}}}_{{0}}^{{\text{t}}}\) is defined by the relation:

$$\widetilde{{\mathbf{E}}}_{0}^{{\mathbf{t}}} = \left( {{1 \mathord{\left/ {\vphantom {1 {4^{3} }}} \right. \kern-\nulldelimiterspace} {4^{3} }}} \right)\sum\limits_{{{\text{u}} = 0}}^{1} {\sum\limits_{{{\text{v}} = 0}}^{1} {\sum\limits_{{{\text{l}} = 0}}^{1} {{\text{s}}_{0}^{{\text{t}}} \left( {\text{u,v,l}} \right)} } } {\mathbf{W}}_{{{\mathbf{u,v,l}}}}^{{\text{t}}} \quad {\text{for}}\;t = 1,2, \ldots 8$$
(3.2)

Here \({\text{s}}_{0}^{{\text{t}}} ({\text{u,}}{\text{v}}{,}{\kern 1pt} {\text{l}})\) are the coefficients of the direct 3D-WHT, applied on the elements of the tensor \({\tilde{\mathbf{E}}}_{{0}}^{{\text{t}}}\).

$${\mathbf{E}}_{{\mathbf{1}}} = \bigcup\limits_{t = 1}^{8} {{\mathbf{E}}_{{\mathbf{1}}}^{{\mathbf{t}}} } .$$
(3.3)

where

$${\mathbf{E}}_{1}^{{\text{t}}} = {\mathbf{E}}_{0}^{{\text{t}}} - \widetilde{{\mathbf{E}}}_{0}^{{\text{t}}} \quad {\text{for}}\,{\text{t}} = 1,2, \ldots 8^{2}$$
(3.4)

In the relations above, \({\mathbf{W}}_{{{\mathbf{u,v,l}}}}\) is the basic tensor with frequency (u, v, l), which could be represented as the outer product of the vectors \(\vec{w}_{u} {\kern 1pt} ,\,\vec{w}_{v} ,{\kern 1pt} \vec{w}_{l} :\)

$${\mathbf{W}}_{{{\mathbf{u,v,l}}}} = \,\vec{w}_{u} {\kern 1pt} \circ {\kern 1pt} \vec{w}_{v} \circ {\kern 1pt} \vec{w}_{l} .$$
(3.5)

Here the vectors \(\vec{w}_{u} {\kern 1pt} ,\,\vec{w}_{v} ,{\kern 1pt} \vec{w}_{l}\), which represent the tensor \({\mathbf{W}}_{{{\mathbf{u,v,l}}}}\), are defined by the relations below (Fig. 3.2):

$$\vec{w}_{u} = [( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (0)u_{r} } }} ,( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (1)u_{r} } }} ,...,( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (7)u_{r} } }} ]^{{\text{T}}} ;$$
(3.6)
$$\vec{w}_{v} = [( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (0)v_{r} } }} ,( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (1)v_{r} } }} ,...,( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (7)v_{r} } }} ]^{{\text{T}}} ;$$
(3.7)
$$\vec{w}_{l} = [( - 1)^{{\sum\limits_{r = 0}^{21} {q_{r} (0)l_{r} } }} ,( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (1)l_{r} } }} ,...,( - 1)^{{\sum\limits_{r = 0}^{2} {q_{r} (7)l_{r} } }} ]^{{\text{T}}} .$$
(3.8)
Fig. 3.2
figure 2

Examples for the basic tensors \({\mathbf{W}}_{u,v,l}\) of size 4 × 4 × 4

The size of the basic tensors \({\mathbf{W}}_{{{\mathbf{u,v,l}}}}\) in Eq. (3.5) is 8 × 8 × 8, and of tensors \({\mathbf{W}}_{{{\mathbf{u,v,l}}}}^{t}\) in Eq. (3.2) when t = 1, 2, …, 8, it is 4 × 4 × 4, respectively. The 3D-WHT coefficients in levels p = 0, 1, 2 of 3D-IDP/WHT are defined by the relations:

$${\text{s}}\left( {\text{u,v,l}} \right) = \sum\limits_{{{\text{i}} = 0}}^{7} {\sum\limits_{{{\text{j}} = 0}}^{7} {\sum\limits_{{{\text{k}} = 0}}^{7} {{\text{x}}\left( {\text{i,j,k}} \right)} } } {\text{wal}}\left( {{\text{i,u}},8} \right){\text{wal}}\left( {{\text{j,v}},8} \right){\text{wal}}\left( {{\text{k,l}},8} \right)\,{\text{for}}\;p = 0;$$
(3.9)
$$\;{\text{s}}_{{\text{p}}}^{{\text{t}}} ({\text{u,}}{\text{v}}{\text{,l}}){\kern 1pt} {\kern 1pt} = \sum\limits_{{{\text{i}} = 0}}^{{2^{{3{\text{ - p}}}} - 1}} {\;\sum\limits_{{{\text{j}} = 0}}^{{2^{{3 - {\text{p}}}} - {1}}} {\sum\limits_{{{\text{k}} = 0}}^{{2^{{3{\text{ - p}}}} - 1}} {\;\;{\tilde{\text{e}}}_{{\text{p}}}^{{\text{t}}} ({\text{i,}}{\text{j,k}})\,} } } {\text{wal}}({\text{i,}}{\kern 1pt} {\text{u,}}{\kern 1pt} 2^{{3{\text{ - p}}}} ){\text{wal}}({\text{j,}}{\kern 1pt} {\text{v}}{,}{\kern 1pt} 2^{{3{\text{ - p}}}} ){\text{wal}}({\text{k}}{\kern 1pt} {\text{,l,}}{\kern 1pt} 2^{{3{\text{ - p}}}} )$$
(3.10)

for t = 1, 2, …, 8p+1 and p = 1, 2,

where \({\tilde{\text{e}}}_{{\text{p}}}^{{\text{t}}} ({\text{i,}}{\text{j,k}})\) are the elements of the sub-tensors \({\tilde{\mathbf{E}}}_{{0}}^{{\text{t}}}\). The Walsh-Hadamard (WH) functions which correspond to the frequency-ordered transform WH matrices, are defined in accordance with the relations:

$${\text{wal}}{(}{\text{i,}}{\kern 1pt} {\text{u,}}{\kern 1pt} {\kern 1pt} {8}{\text{)wal(}}{\text{j,}}{\text{v,}}{\kern 1pt} {8}{\text{)wal(}}{\text{k,}}{\kern 1pt} {\text{l,}}{\kern 1pt} {8}) = ( - 1)^{{\sum\limits_{{{\text{r}} = {0}}}^{{2}} {[{\text{q}}_{{\text{r}}} {\text{(i)u}}_{{\text{r}}} + {\text{q}}_{{\text{r}}} {\text{(j)v}}_{{\text{r}}} + {\text{q}}_{{\text{r}}} {\text{(k)l}}_{{\text{r}}} ]} }} ,$$
(3.11)

where

\({\text{i}}{\kern 1pt} = \sum\limits_{{{\text{r}} = {0}}}^{{2}} {{\text{i}}_{{\text{r}}} {2}^{{\text{r}}} } {\text{, u}}{\kern 1pt} = \sum\limits_{{{\text{r}} = {0}}}^{{2}} {{\text{u}}_{{\text{r}}} {2}^{{\text{r}}} } ;\) \({\text{j}}{\kern 1pt} = \sum\limits_{{{\text{r}} = {0}}}^{{2}} {{\text{j}}_{{\text{r}}} {2}^{{\text{r}}} } {\text{, v}}{\kern 1pt} = \sum\limits_{{{\text{r}} = {0}}}^{{2}} {{\text{v}}_{{\text{r}}} {2}^{{\text{r}}} } ;\) \({\text{k}} = \sum\limits_{{{\text{r}} = {0}}}^{{2}} {{\text{k}}_{{\text{r}}} {2}^{{\text{r}}} } {\text{, l}}{\kern 1pt} = \sum\limits_{{{\text{r}} = {0}}}^{{2}} {{\text{l}}_{{\text{r}}} {2}^{{\text{r}}} } ;\)

\({\text{q}}_{{0}} {\text{(i)}}{\kern 1pt} = {\kern 1pt} {\text{i}}_{{2}} {\text{, q}}_{{1}} {\text{(i)}}{\kern 1pt} = {\kern 1pt} {\text{i}}_{{2}} \oplus {\kern 1pt} {\text{i}}_{{1}} {\text{, q}}_{{2}} {\text{(i)}}{\kern 1pt} = {\kern 1pt} {\text{i}}_{{1}} \oplus {\kern 1pt} {\text{i}}_{{0}} {;}\)

\({\text{q}}_{0} \left( {\text{j}} \right) = {\text{j}}_{2} ,{\text{q}}_{1} \left( {\text{j}} \right) = {\text{j}}_{2} \oplus {\text{j}}_{1} ,{\text{q}}_{2} \left( {\text{j}} \right) = {\text{j}}_{1} \oplus {\text{j}}_{0} ;\)

\({\text{q}}_{{0}} {\text{(k)}}{\kern 1pt} = \,{\text{k}}_{{2}} {\text{, q}}_{{1}} {\text{(k)}}{\kern 1pt} = {\kern 1pt} {\text{k}}_{{2}} \oplus \,{\text{k}}_{{1}} {\text{, q}}_{{2}} {\text{(k)}}{\kern 1pt} = {\kern 1pt} {\text{k}}_{{1}} \oplus {\kern 1pt} {\text{k}}_{{0}} {.}\)

In result of the 3-level 3D-IDP/WHT transform, the tensor X is represented as an inverse pyramid in the spectral domain. In the lowest pyramid level (p = 0), it is represented by the spectrum tensor \({\tilde{\mathbf{S}}}\) of size 2 × 2 × 2; in the next level (p = 1)—by the spectrum tensor \({\tilde{\mathbf{S}}}_{{\mathbf{0}}}\) of size 4 × 4 × 4, and in the last level (p = 2)—by the spectrum tensor \({\mathbf{S}}_{{\mathbf{1}}}\), of size 8 × 8 × 8. The tensors \({\tilde{\mathbf{S}}}\) and \({\tilde{\mathbf{S}}}_{{\mathbf{0}}}\) are the spectrum approximations of tensors \({\tilde{\mathbf{X}}}\) and \({\tilde{\mathbf{E}}}_{{0}} = \bigcup\limits_{{{\text{t}} = {1}}}^{{8}} {{\tilde{\mathbf{E}}}_{{0}}^{{\text{t}}} }\), and the tensor \({\mathbf{S}}_{{\mathbf{1}}}\) is the spectrum transform of the tensor \({\mathbf{E}}_{1}\). The elements of the spectrum tensors are the coefficients \(\;{\text{s(u,}}{\text{v}}{,}{\kern 1pt} {\text{l)}}\) and \({\text{s}}_{{\text{p}}}^{{\text{t}}} ({\text{u,}}{\text{v}}{\text{,l}})\), calculated in accordance with Eqs. (3.9) and (3.10). Each spectrum tensor \({\tilde{\mathbf{S}}}\,,\,{\kern 1pt} {\tilde{\mathbf{S}}}_{{\mathbf{0}}} ,\,{\kern 1pt} {\mathbf{S}}_{{\mathbf{1}}}\) is of size 2 × 2 × 2, 22 × 22 × 22, and 23 × 23 × 23 respectively.

In the general case, the number of coefficients in the levels p = 1, 2, …, n −1 of the n-level 3D-IDP/WHT could be reduced on the basis of the next relation [16, 17]:

$${\text{s}}_{p}^{1} \left( {0,0,0} \right) = - \sum\limits_{{{\text{t}} = 2}}^{8} {{\text{s}}_{p}^{t} \left( {0,0,0} \right)} \quad {\text{for}}\;{\text{t}} - 1,2, \ldots 8^{p + 1} .$$
(3.12)

Then, the number of the retained coefficients for the pyramid shown in Fig. 3.1 in the level p = 1 is 56, and in the level p = 2 it is 448, respectively. The so obtained pyramid with reduced coefficients \(\;s_{{\text{p}}}^{{1}} ({0,}{\kern 1pt} {0}{\text{,0}})\) is called 3D Reduced IDP/WHT (3D-RIDP/WHT) [16]. The number of operations, O (additions and multiplications), needed for the calculation, is defined by the relation [17]:

$${\text{O}}_{{{\text{3D}} - R{\text{IDP}}{/}{\text{WHT}}}} ({\text{n}}){\kern 1pt} \approx {\kern 1pt} 8^{{\text{n}}} \times 2.5{\text{n}}.$$
(3.13)

The detailed comparison of the CC of 3D-RIDP/WHT with these of the orthogonal 3D transforms DFT, DCT, DWT and CDT, given in [17], proves its lower value. For the same value of n, the CC of 3D-FFT is minimum and is defined by the relation \({\text{O}}_{{{\text{3D}} - {\text{FFT}}}} ({\text{n}}){\kern 1pt} = {\kern 1pt} 8^{{\text{n}}} \times 7.5\,{\text{n}}\). Hence, the CC of 3D-RIDP/WHT is three times lower than that of 3D-FFT.

2.2 Hierarchical Decomposition of a Tensor of Size M × N × P Through 3D Adaptive Branched IDP

The principle of the hierarchical decomposition of a 3D tensor of size M × N × P through branched IDP is shown in Fig. 3.3 for the case, when M = N = P = 16, and the 3D-IDP is built for sub-tensors of size 8 × 8 × 8 (n = 3). For the building of the 3D branched spectrum pyramid (3D-BIDP) should be defined the way used to calculate its branches. The process is illustrated for the tensor X of size 16 × 16 × 16. This tensor is divided into 8 sub-tensors of size 8 × 8 × 8, and each is represented as a 3D-IDP pyramid of n = 3 levels. In the initial level (p = 0) of each pyramid are calculated 8 spectral coefficients with frequencies (0, 0, 0) to (1, 1, 1), whose basic functions are shown in Fig. 3.2. From the group of coefficients of same frequency (u, v, l) for u, v, l = 0, 1, are created 8 tensors of size 2 × 2 × 2.

Fig. 3.3
figure 3

Hierarchical decomposition for a tensor of size 16 × 16 × 16 through 3D branched IDP, based on the spectral coefficients in IDP level p = 0, using sub-tensors of size 8 × 8 × 8

In Fig. 3.4 is shown the graph of the full tree for the level p = 0 in all 3D-IDP, which represents the tensor of size 16 × 16 × 16. This graph corresponds to the hierarchical tensor decomposition, shown in Fig. 3.3. From the tree branches 1, ..., 8, which correspond to sub-tensors of size 8 × 8 × 8, are obtained 64 branches (tensors), each of size 2 × 2 × 2. Then, the total number of branches of the full 3D-BIDP tree for the level p = 0 is S0 = 64 × 8; for the level p = 1 it is S1 = 64 × 82; and for the level p = 2, it is S2 = 64 × 83. Then, the total number of the branches in the full tree is:

$$N_{B} = 64(8 + 8^{2} + 8^{3} ){\kern 1pt} = {\kern 1pt} 37376.$$
(3.14)
Fig. 3.4
figure 4

The 3D-BIDP graph of the full tree-like representation for a tensor of size 16 × 16 × 16

In the general case, for a tensor of size M × N × P, divided into sub-tensors of size 2n × 2n × 2n, the number of the branches of the full tree in the level k of the hierarchical tensor decomposition, taking into account the sum \(S = \sum\limits_{k = 1}^{n} {8^{k} } = (8/7)(8^{n} - 1)\), is:

$${\text{N}}_{{{\text{Bk}}}} = \left\lfloor {2^{{ - {\text{kn}}}} {\text{M}}} \right\rfloor \left\lfloor {2^{{ - {\text{kn}}}} {\text{N}}} \right\rfloor \left\lfloor {2^{{ - {\text{kn}}}} {\text{P}}} \right\rfloor \times 8 \times {\text{S}} \approx \left( {{{8^{2} } \mathord{\left/ {\vphantom {{8^{2} } 7}} \right. \kern-\nulldelimiterspace} 7}} \right)\left\lfloor {{\text{MNP}} \times 8^{{ - {\text{nk}}}} } \right\rfloor \left( {8{\text{n}} - 1} \right)$$
(3.15)

for k = 1, 2, …, s; s—the number of the levels in the branched tensor decomposition.

Hence, the number of branches in the full tree for a tensor of size M × N × P built on the basis of the s-level 3D-BIDP taking into account that \(\sum\limits_{k = 1}^{s} {8^{ - kn} } = \frac{{1 - 8^{ - sn} }}{{8^{n} - 1}}\), is defined by the relation:

$$N_{B} = \sum\limits_{k = 1}^{s} {N_{{B_{k} }} } = \sum\limits_{k = 1}^{s} {\left\lfloor {MNP\, \times 8^{ - kn} } \right\rfloor \,\,} \times 8 \times S \approx \,[(8^{2} /{\kern 1pt} 7)(1 - 8^{ - sn} )]\,MNP$$
(3.16)

For example, for M = N = P = 16 and n = s = 3, from Eq. (3.16) it follows that for the full tree NB ≈ 37,449.

The branches of the full tree which could be cut-off, should satisfy at least one of the following requirements:

  • to correspond to spectral coefficients equal to zero;

  • the modules of the spectral coefficients in a given branch must be smaller than a predefined threshold value;

  • the coefficients in a given branch should correspond to the spatial frequencies in which is concentrated the energy of the noise, contained in the decomposed tensor.

After applying the above criteria, the number of tree branches could be significantly reduced. The further reduction depends on the requirements imposed by the tensor decomposition application.

3 Algorithm for Third-Order Tensor Decomposition Through 3D ABIDP/WHT

The main steps of the 3D-ABIDP/WHT algorithm for tensor decomposition, are:

Start: input tensor X of size M × N × P, with non-negative elements \({\text{x(i,}}{\text{j,}}{\kern 1pt} {\text{k)}}\) and defined thresholds for decomposition branches truncation in accordance with coefficients energy and signal-to-noise relation.

Step 1. Divide the tensor X into sub-tensors \({\mathbf{X}}_{k}\) of size 2n × 2n × 2n, for k = 1, 2, …, K1.

(\(K_{1} = \,\left\lfloor {MNP/8^{n} } \right\rfloor\)—total number of the sub-tensors, \({\mathbf{X}}_{k}\));

Step 2. Transform each sub-tensor \({\mathbf{X}}_{k}\) into the corresponding n-level 3D-IDP/WHT pyramid which comprises a sequence of spectral sub-tensors, as follows:

  • in the level p = 0—the sub-tensor \({\tilde{\mathbf{S}}}_{k}\) of size 2 × 2 × 2, which comprises 8 coefficients sk(u, v, l), for u, v, l = 0, 1;

  • in the level p = 1—the sub-tensor \({\tilde{\mathbf{S}}}_{{{\mathbf{0}},k}}\) of size 22 × 22 × 22, which comprises 64 coefficients \({\text{s}}_{{\text{0,k}}}^{{\text{t}}} {\text{(u,}}{\text{v,}}{\kern 1pt} {\text{l)}}\), for u, v, l = 0, 1 and t = 1, 2, …, 8;

  • in the level p = n-1—the sub-tensor \({\mathbf{S}}_{n - 2,k}\) of size 2n × 2n × 2n, which comprises 8n coefficients \({\text{s}}_{{\text{n - 2,k}}}^{{\text{t}}} {\text{(u,}}{\text{v,}}{\kern 1pt} {\text{l)}}\) for u, v, l = 0,1 and t = 1, 2, …, 8n−1;

Step 3. Unite coefficients of same frequency (u, v, l) from each level p = 0, 1, …, n − 1 from all pyramids into corresponding spectrum sub-tensors \({\mathbf{S}}_{k} (1)\) of size \(\left\lfloor {M/2^{n} } \right\rfloor \times \left\lfloor {N/2^{n} } \right\rfloor \times \left\lfloor {P/2^{n} } \right\rfloor\), for k = 1, 2, …, K1;

Step 4. Transform each sub-tensor \({\mathbf{S}}_{k} (1)\) into the corresponding n-level 3D-IDP/WHT pyramid comprising a sequence of spectral sub-tensors in levels p = 0, 1, …, n − 1, in accordance with Step 2;

Step 5. Unite the coefficients of same frequency (u, v, l) from level p of all pyramids for the corresponding spectral sub-tensors \({\mathbf{S}}_{k} (2)\) of size \(\left\lfloor {M/2^{2n} } \right\rfloor \times \left\lfloor {N/2^{2n} } \right\rfloor \times \left\lfloor {P/2^{2n} } \right\rfloor\), for k = 1, 2, …, \(K_{2} = {\kern 1pt} \left\lfloor {MNP/8^{2n} } \right\rfloor\);

Step 6. Divide the sub-tensor \({\mathbf{S}}_{k} (m)\) which corresponds to a certain branch m, into sub-tensors \({\mathbf{S}}_{k} (m + 1)\) of size \(\left\lfloor {M/2^{(m + 1)n} } \right\rfloor \times \left\lfloor {N/2^{(m + 1)n} } \right\rfloor \times \left\lfloor {P/2^{(m + 1)n} } \right\rfloor\) for k = 1, 2, …, \(K_{m + 1} = {\kern 1pt} \left\lfloor {MNP/8^{(m + 1)n} } \right\rfloor\);

Step 7. Stop the dividing of sub-tensors \({\mathbf{S}}_{k} (m + 1)\) and cut-off the corresponding decomposition branches for the cases, when at least one of the following 4 conditions is satisfied:

  • at least one of their dimensions is equal to 2;

  • they are built of spectral coefficients, equal to zero;

  • they are built of spectral coefficients, whose modules are lower than a predefined threshold value;

  • they are built of coefficients with spectral frequencies, in which is concentrated the main part of the noise energy, in correspondence with the accepted statistical model for their distribution (respectively—the value of the relation signal/noise).

Step 8. Go to step 8 after the division of all decomposition branches is finished. Else, each branch corresponding to the sub-tensor \({\mathbf{S}}_{k} (m + 1)\) which does not satisfy at least one of the conditions from Step 7, is not cut-off and for it are executed sequentially steps 1–5 by analogy with the processing of the input tensor, X;

Step 9. End.

As a result of the execution of the algorithm, presented above, is obtained a truncated tensor decomposition in the spectrum domain of 3D-WHT, from which the input tensor X could be restored with a predefined accuracy. The number of the 3D-AIDP/WHT levels is chosen in the range 2–4 depending on the data, contained in the input tensor (for example, a video sequence, a group of multispectral images, X-ray images, etc.). The so described algorithm could be also applied in the cases when instead of 3D-WHT is used some other famous deterministic 3D transform, for example, DCT, DST, DHT, etc.

4 Analysis of 3D ABIDP/WHT Properties

The main objective at which the 3D-ABIDP is aimed, is to enhance the efficiency of the use of the correlation between tensor elements, so that to achieve maximum energy concentration into minimum number of spectrum coefficients. The branched tree-like decomposition based on the 3D-ABIDP/WHT, differs from 3D-IDP/WHT in the following:

  • it ensures better decomposition efficiency for tensors of large size, due to the low CC of 3D-RIDP/WHT pyramid for small number of levels (n = 2/4), used to transform each sub-tensor (decomposition branch);

  • it ensures higher energy concentration in the spectrum sub-tensors of reduced size (branches of the tree-like structure), built by the spectrum coefficients of same spatial frequency (u, v, l).

The properties of 3D-ABIDP/WHT depend on the configuration of the truncated tree, which represents the input tensor. The number of the cut-off tree branches grows together with the energy concentration in the retained branches (respectively—the retained spectrum coefficients). The energy concentration is highest in the group of retained spectrum coefficients with spatial frequency (0, 0, 0) in level p = 0 of each 3D-IDP/WHT which represent the corresponding sub-tensor. The sub-tensors built of such coefficients, are copies of the input tensor (the root of the tree), but their size is reduced.

The use of the new 3D-WHT decomposition with frequency-ordered transform matrices leads to additional concentration of the tensor energy into small number of spectrum coefficients in the initial levels of each inverse pyramid. The degree of the tensor energy concentration in selected spectrum coefficients depends on the correlation between its elements.

One important property of the non-negative tensor decomposition through adaptive 3D-BIDP/WHT, is the low computational complexity. The detailed analysis given in [17] proves that the CC of 3D-RIDP/WHT (which is the basic building unit of the branched adaptive pyramidal decomposition) is lower than that of the famous 3D orthogonal transforms: DFT, DHT, DCT, DWT, CDT and SDT.

The CC of 3D-BIDP/WHT is defined by the product of the CC for 3D-RIDP/WHT in accordance with Eq. (3.13), and the number of the branches in the full tree-like structure from Eq. (3.16), i.e.:

$${\text{O}}_{{{\text{3D}} - B{\text{IDP}}{/}{\text{WHT}}}} ({\text{n}}){\kern 1pt} \approx {\kern 1pt} 8^{{\text{n}}} \times {\kern 1pt} 2.5{\text{n}}{\kern 1pt} \times {\kern 1pt} {\text{N}}_{{\text{B}}} = \,8^{n} \times 22.8\,n{\kern 1pt} {\kern 1pt} \times {\kern 1pt} {\kern 1pt} MNP.$$
(3.17)

The value of \({\text{O}}_{{{\text{3D}} - B{\text{IDP}}{/}{\text{WHT}}}}\) for the case when the 3D-BIDP/WHT is based on the 3D-RIDP/WHT (whose CC is the lowest, compared to the famous deterministic 3D orthogonal transforms), is minimum too.

The adaptation of 3D-ABIDP/WHT toward the values of the tensor elements and the reduction of the part of the coefficients of the basic 3D-RIDP/WHT permits significant reduction of the branches in the tree-like structure after the “truncation”. In result is achieved lower CC of the decomposition, compared to that of the full tree, defined by Eq. (3.17).

5 Conclusions

In this work is offered a new approach for adaptive hierarchical decomposition of third-order tensors in the spectrum area of 3D-WHT, which has higher efficiency in respect of the tensor energy concentration into a small number of spectrum coefficients, and together with this, ensures low CC. These advantages of the offered tensor decomposition open many possibilities for its application in various areas, such as: compression of sequences of correlated images, improvement of their quality through filtration and contrast enhancement, analysis and pattern recognition, accelerated search in databases of tensor images, analysis of multidimensional tensor signals, etc.

The future development of the offered decomposition is aimed at the investigation of the possibilities for its application in the statistical orthogonal transforms (the tensor KLT, and SVD), and also, in the neural networks with deep learning, for the optimization of the tree-like structure truncation.