The WHT is known for its important computational advantages. For instance, it is a real (not complex) transform, it only needs addition and subtraction operations and if the input signal is a set of integer-valued data (as in the case of digital images), it only uses integer operations. Furthermore, there is a fast algorithm for Walsh transforms proposed in [23]. The transform matrix, usually referred to as Hadamard matrix, can also be saved in the binary format resulting in the memory requirements reduction [24]. Moreover, hardware implementation of WHT is rather easier than other transforms [25].

Inspired by oriented/multi-band structures of Gabor filters [26], novel DWHT is recommended by Monadjemi and Moallem [21]. The algorithm of DWHT is capable of extracting texture features in different directions and sequency scales. As mentioned before, DWHT keeps all the advantages of WHT. Furthermore, the DWHT preserves the directional properties of texture. The DWHT can be defined as

{\mathrm{DWHT}}_{\alpha}\left(A\right)={A}_{\alpha}\times {H}^{\prime}

(10)

In which, *H* is *sequency-ordered Hadamard* (SOH) matrix [25, 27] where the rows (and columns) are ordered according to their sequency. In other words, while there is no sign of change in the first row, there are *n* – 1 sign changes in the *n* th row. As an example, see Figure 2 in which SOH matrix is shown for a rank is 3 (or 8 × 8).

In fact, for a Hadamard matrix, *H* is always equal its transpose, *H*^{′}. In this article, we use the second rank of Hadamard matrix (4 × 4).

In Equation (10), *A*_{α}, *α* = {0°, 45°, 90°, 135°}, is the rotated version of *A*. The rotation is applied to each element in the top row of the image matrix. At border pixels, corresponding elements are used from a repeated imaginary version of the same image matrix (i.e., image is vertically and horizontally wrapped around).

The full rotation set where *α* = {0°, 45°, 90°, 135°} can be defined for a simple 4 × 4 image matrix as follows

\begin{array}{c}{A}_{0\xb0}=\left[\begin{array}{cccc}\hfill a\hfill & \hfill b\hfill & \hfill c\hfill & \hfill d\hfill \\ \hfill e\hfill & \hfill f\hfill & \hfill g\hfill & \hfill h\hfill \\ \hfill i\hfill & \hfill j\hfill & \hfill k\hfill & \hfill l\hfill \\ \hfill m\hfill & \hfill n\hfill & \hfill o\hfill & \hfill p\hfill \end{array}\right]{A}_{45\xb0}=\left[\begin{array}{cccc}\hfill a\hfill & \hfill f\hfill & \hfill k\hfill & \hfill p\hfill \\ \hfill b\hfill & \hfill g\hfill & \hfill l\hfill & \hfill m\hfill \\ \hfill c\hfill & \hfill h\hfill & \hfill i\hfill & \hfill n\hfill \\ \hfill d\hfill & \hfill e\hfill & \hfill j\hfill & \hfill o\hfill \end{array}\right]\hfill \\ {A}_{90\xb0}=\left[\begin{array}{cccc}\hfill a\hfill & \hfill e\hfill & \hfill i\hfill & \hfill m\hfill \\ \hfill b\hfill & \hfill f\hfill & \hfill j\hfill & \hfill n\hfill \\ \hfill c\hfill & \hfill g\hfill & \hfill k\hfill & \hfill o\hfill \\ \hfill d\hfill & \hfill h\hfill & \hfill l\hfill & \hfill p\hfill \end{array}\right]{A}_{135\xb0}=\left[\begin{array}{cccc}\hfill a\hfill & \hfill h\hfill & \hfill k\hfill & \hfill n\hfill \\ \hfill b\hfill & \hfill e\hfill & \hfill l\hfill & \hfill o\hfill \\ \hfill c\hfill & \hfill f\hfill & \hfill i\hfill & \hfill p\hfill \\ \hfill d\hfill & \hfill g\hfill & \hfill j\hfill & \hfill m\hfill \end{array}\right]\hfill \end{array}

(11)

Note that this is not an ordinary geometrical rotation. For example, we create the rows of *A*_{45°} image by considering the pixels that sit in a 45° direction in the image *A*_{0°} and so on. This means that the resulting horizontal rows capture the information at the specified angles. In fact, it looks more like a pixel rearrangement rather than a geometrical rotation.

This rotation means that after applying the DWHT transform we need only extracting the row sequency information, corresponding to the direction used. As Equation (12) shows, the operation DWHT_{
α
}(*A*) = *A*_{
α
} × *H*^{′} is computed and gathers the sequency information of input matrix rows into transformed matrix columns. Hence, the same half transform for a rotated matrix (e.g., *A*_{45°}) will give us the sequency information of pixels with a 45°-orientation, again into the columns of transformed matrix. In transfer matrix, the number of sign changes in each column of the sequences is the same and it increases from left to right. In other words, the transformed matrix columns from left to right correspond to the lower to higher sequency elements.

\begin{array}{c}{\mathrm{DWHT}}_{0\xb0}\left(A\right)={A}_{0\xb0}\times {H}^{\prime}=\left[\begin{array}{cccc}\hfill a\hfill & \hfill b\hfill & \hfill c\hfill & \hfill d\hfill \\ \hfill e\hfill & \hfill f\hfill & \hfill g\hfill & \hfill h\hfill \\ \hfill i\hfill & \hfill j\hfill & \hfill k\hfill & \hfill l\hfill \\ \hfill m\hfill & \hfill n\hfill & \hfill o\hfill & \hfill p\hfill \end{array}\right]\times \left[\begin{array}{cccc}\hfill 1\hfill & \hfill 1\hfill & \hfill 1\hfill & \hfill 1\hfill \\ \hfill 1\hfill & \hfill 1\hfill & \hfill -1\hfill & \hfill -1\hfill \\ \hfill 1\hfill & \hfill -1\hfill & \hfill -1\hfill & \hfill 1\hfill \\ \hfill 1\hfill & \hfill -1\hfill & \hfill 1\hfill & \hfill -1\hfill \end{array}\right]\hfill \\ \phantom{\rule{12em}{0ex}}=\left[\begin{array}{cccc}\hfill a+b+c+d\hfill & \hfill a+b-c-d\hfill & \hfill a-b-c+d\hfill & \hfill a-b+c-d\hfill \\ \hfill e+f+g+g\hfill & \hfill e+f-g-h\hfill & \hfill e-f-g+h\hfill & \hfill e-f+g-h\hfill \\ \hfill i+j+k+l\hfill & \hfill i+j-k-l\hfill & \hfill i-g-k+l\hfill & \hfill i-g+k-l\hfill \\ \hfill m+n+o+p\hfill & \hfill m+n-o-p\hfill & \hfill m-n-o+p\hfill & \hfill m-n+o-p\hfill \end{array}\right]\hfill \end{array}

(12)

In the Hadamard-based feature extraction procedure, we exploited the mentioned rotation and transformation for four different orientations:

\{\begin{array}{l}\mathit{DWH}{D}_{0\xb0}\left(A\right)={A}_{0\xb0}\times {H}^{\prime}\hfill \\ \mathit{DWH}{D}_{45\xb0}\left(A\right)={A}_{45\xb0}\times {H}^{\prime}\hfill \\ \mathit{DWH}{D}_{90\xb0}\left(A\right)={A}_{90\xb0}\times {H}^{\prime}\hfill \\ \mathit{DWH}{D}_{135\xb0}\left(A\right)={A}_{135\xb0}\times {H}^{\prime}\hfill \end{array}

(13)

Since the relative arrangement of pixels is essential in texture analysis [28], sequency-based features which represent the number of zero-crossing of pixels in a particular direction can convey a notable amount of textural information. We can measure the DWHT energy in DWHT_{
α
}(*A*) as the absolute value of the DWHT output along each column. Columns can be divided into a few groups that represent different *sequency bands*. Then the statistics of each band can be extracted to configure a feature vector with reasonable dimensionality. So, a DWHT output and feature vector can be defined as

\begin{array}{c}H\left(\alpha ,b\right)={\mathrm{DWHT}}_{\alpha}\left(A\right){|}_{i,j},1\le i\le N,j\in b,\mathrm{and}{F}_{\mathrm{DWHT}}\hfill \\ \phantom{\rule{3.5em}{0ex}}=M\left(H\left(\alpha ,b\right)\right)\hfill \end{array}

(14)

where *H* is the transform’s output matrix, *N* is the matrix size, *F* is the feature vector, *M* indicates the applied statistical function, and *b* is the desired sequency band. Again, log_{2}or semi-log_{2}bandwidth scales could be applied. However, we mostly use a simpler \left\{\frac{1}{4},\frac{1}{4},\frac{1}{2}\right\} division for a three-band and a \left\{\frac{1}{4},\frac{1}{4},\frac{1}{4},\frac{1}{4}\right\} division for a four-band feature sets. For example, in three-band division of four-column transform matrix, the band *b* 1 is determined by a first column sequency, the band *b* 2 is determined by a second column sequency, and the third and fourth columns generate band *b* 3. For example, the sequency bands of DWHD_{0°} (*A*) are defined as follows:

\begin{array}{c}b1=\left[\begin{array}{c}\hfill a+b+c+d\hfill \\ \hfill e+f+g+h\hfill \\ \hfill i+j+k+l\hfill \\ \hfill m+n+o+p\hfill \end{array}\right],\mathrm{to}b2=\left[\begin{array}{c}\hfill a+b-c-d\hfill \\ \hfill e+f-g-h\hfill \\ \hfill i+j-k-l\hfill \\ \hfill m+n-o-p\hfill \end{array}\right],\hfill \\ \mathrm{to}b3=\left[\begin{array}{cc}\hfill \begin{array}{c}\hfill a-b-c+d\hfill \\ \hfill e-f-g+h\hfill \\ \hfill i-j-k+l\hfill \\ \hfill m-n-o+p\hfill \end{array}\hfill & \hfill \begin{array}{c}\hfill a-b+c-d\hfill \\ \hfill e-f+g-h\hfill \\ \hfill i-j+k-l\hfill \\ \hfill m-n+o-p\hfill \end{array}\hfill \end{array}\right]\hfill \end{array}

(15)