Enhanced Signal Area Estimation in Radio-Communication Spectrograms Based on Morphological Image Processing

The concept of signal area (SA), de ﬁ ned as the rectangular time – frequency region in a spectrogram where a signal is detected, plays an important role in spectrum usage measurements. The need for signal area estimation (SAE) is justi ﬁ ed by its role in the process of allocating white space spectrum to secondary users in dynamic spectrum access systems as well as in other interesting applications such as compliance veri ﬁ cation and enforcement of spectrum regulations, signal interception


Introduction
The historic success of wireless communication systems and their various technologies [1] has been manifested in the large number of users and services that are currently deployed and are expected to grow in the near and far future.However, while wireless communication networks, operators, and services have been growing steadily, the amount of available spectrum-the main resource of wireless communication systems-has grown at much slower pace and, in many cases, has remained constant.While higher frequency bands have been made available for the new systems [2,3], these are usually characterised by the more challenging propagation conditions and more complex and expensive equipment.This has increased tremendously the pressure placed on the available spectral resources, in particular those in the lower region of the spectrum up to a few gigahertz, where the most favourable radio propagation conditions can usually be found.
In order to fully exploit the available spectrum, several ideas and principles for the dynamic spectrum access (DSA) [4][5][6][7] have been proposed.
When deploying DSA in real environments, the availability of smart techniques for an accurate, cost-effective, and low-latency assignment of the existing spectrum to users is crucial [8,9].Moreover, the presence of multiple radio technologies sharing the same spectrum has led to the development of spectrum usage detection (SUD) methods to help in identifying the level of usage of the spectrum as well as their users (technologies, networks, and services).One of the key techniques required to materialise SUD is the signal area estimation (SAE).The idea of signal area (SA) [10] has been proposed in the area of spectrum usage measurements [11] and is defined as the rectangular time-frequency region in a spectrogram where a signal is detected.The SA is treated as a set of one or more rectangular-shaped clusters of the tiles that are occupied by a transmitted signal.SAE methods, through different algorithms and techniques, determine the subsets of elements in the time-frequency domain in which a signal exists (i.e., the SA), where each of those elements represents a time-slot and frequency-bin.SAE has high efficiency, low cost of implementation, and represents an important source of useful information for DSA [8].Based on the spectrum measurements, SAE techniques can be used to generate statistical information that can then be used to identify the transmitters and their transmissions based on SUD [12] and in other spectrum-related applications such as compliance verification of the requirements for spectrum usage and enforcement of spectrum regulations (e.g., verifying that spectrum resources, an asset of societal value, are lawfully used as required by the spectrum regulators), or signal interception, and other signals intelligence related operations (e.g., to determine if unauthorised radio transmissions are present in a particular frequency band) as well as network planning and optimisation (e.g., to design network protocols and algorithms such that they efficiently match spectrum usage patterns) [13].
Various authors have identified different techniques and algorithms for implementing SAE.The most commonly explored and proposed techniques include energy detection utilising fast Fourier transforms (ED-FFT) [14], contourtracing (CT-SA) methods [15], and the simple signal area (SSA) strategy developed by Mizuchi et al. [8] and Umebayashi et al. [10,12].In this context, this research explores a different strategy where morphological operations (MOs) [16] from the field of image processing are utilised to improve the detection accuracy of the estimated SA.The use of MOs in SAE is motivated by the fact that the problem of estimating a SA in a time-frequency matrix of observed power samples (obtained from spectrum measurements) is similar to the problem of recognition of patterns in an image (in this case, rectangularly shaped areas).Image processing techniques can be utilised to identify shapes after separating them from their background.This principle can be applied in SAE by taking the entire time-frequency matrix of power samples and converting it into a binary matrix of idle/busy states (by comparing each power sample to a properly set decision threshold).The binary matrix of zero/one elements (where each element represents the detected idle/busy state of that element) can be seen as an image where each element of the time-frequency matrix is considered as a black/white pixel.The problem of SAE is then made equivalent to the problem of identifying rectangular shapes in noisy binary images.This viewpoint opens an entirely new line of research where the utility of many powerful tools available in the field of image processing for SAE can be explored.Image processing is a very mature field of knowledge where a diverse range of sophisticated and advanced tools have been developed to detect a broad range of shapes and patterns in images typically obtained in many application scenarios [17][18][19][20][21][22][23][24][25][26].Many existing techniques, despite generally have been proposed and developed in the different application scenarios, have the potential to effectively contribute to the problem of SAE considered in this work.Such tools are therefore potentially appropriate for the problem of SAE that is studied in this work and their applicability in this context is the focus of the research presented in this paper.In particular, the interest of this research is in investigating the viability of using MOs to enhance the accuracy and performance of SAE.The interest of considering MOs lies in their potential ability to handle and fix certain imperfections and degradations that are observed in real-life spectrum measurements.Certain MOs can remove small objects from an image (useful to remove signal false alarms), while other MOs can replete gaps between objects (useful to overcome the impact of signal missed detections).This suggests that MOs can help to overcome the degrading impact of the signal detection errors (i.e., false alarms and missed detection) that are present in the process of SAE.
There have been a few attempts in the literature to utilise or explore the utility of MOs in order to process spectrum power measurements.By Ready et al. [27], a technique for automatically estimating the noise floor in the presence of signals (i.e., without requiring spectrum noise-only measurements) is proposed based on the mathematical morphology.The work reported by Tom [28] and references therein proposes a method relying on the morphologic image processing and statistical analysis to automatically select a suitable energy detection threshold based on power spectrum measurements where radio-frequency signals are present as well.The applicability of mathematical morphology to the shortterm Fourier transform (STFT) is explored by Rivest [29], with a special focus on the detection of radar signals.A related STFT-based approach is proposed by Mankun et al. [30] to extract features from frequency-hopping signals (hopping carrier frequency, hop timing, and hop rate) based on MOs.A morphological algorithm is proposed by Offringa et al. [31] for radio-frequency interference detection (in the context of astronomy rather than radio communications).However, to the best of the authors' knowledge, this constitutes the first attempt in the open literature to apply morphological image processing methods to enhance the accuracy and performance of SAE.
The contribution of this research is multiple.First, it contributes a detailed analysis of the impact of the main As it will be shown, the proposed approach provides noticeable improvements in the accuracy of the detected SAs (compared to the scenario where the other SAE methods are applied alone without the aid of MOs) and without having a noticeable impact on the total computational cost (even reducing it in some cases).
The performance results obtained by the simulations are corroborated with experimental results obtained with a hardware prototype specifically used to this end.
It is worth clarifying that the objective of this work is not to provide novel contributions to the field of image processing, but to the field of wireless communications, by exploring the potential applicability of MOs to the resolution of the SAE problem.Therefore, this work considers standard MOs as defined in their standard form, without introducing variants or modifications to their classical theoretical definitions.
The rest of this paper is organised as follows.First, Section 2 describes the problem of SAE considered in this work and provides a brief survey of the existing techniques for SAE.Section 3 details the principle of image processing MOs through an exposition of its use in image processing applications and its relevance to the proposed SAE approach.Section 4 then presents the methodology followed in this research to evaluate the performance of the proposed MOs in the context of SAE.The analysed research findings from the conduction of the simulations are presented and discussed under Section 5, where a new MO-based SAE method is proposed based on the observed performance of MOs.In last, Section 6 concludes the study.

Problem Description and Formulation.
A radio spectrogram can be mathematically denoted as a matrix P 2 R M×N of M × N power values, where the vertical and horizontal sides of spectrogram P are related to the time and frequency dimensions, respectively, so that each element of the spectrogram matrix P, which can be denoted as P m; ½ n 2 R (m ¼ 1; …; M and n ¼ 1; …; N), is the power level that has been observed at the m th time slot and n th frequency bin, the vertical dimension or size M represents the number of temporal samples taken in the spectrogram and the horizontal dimension or size N corresponds to the number of frequency points in which the whole frequency span has been divided in the spectrum measurements.
To determine the potential existence of signal components in a spectrogram, an energy decision threshold λ 2 R is employed, which can be obtained based on the various techniques [32].The threshold is then utilised to convert the matrix of continuous powers P observed at the receiver into a binary matrix B 2 B M×N (with B ¼ 0; f 1g), each of whose elements B m; ½ n 2 B are calculated as follows: denoting whether a spectrogram element is assumed to include a signal component (B m; Let T 2 B M×N be a matrix whose elements T m; ½ n contain the true states of the elements B m; ½ n in the corresponding matrix B at the receiver (Figure 1).Some elements of B may be incorrect as a consequence of signal transmission and detection errors, which can be described in terms of the probability of false alarm Thus, B can be thought of as a deteriorated version of T, with random errors appearing with probabilities P fa and 1 − P d (i.e., B ≠ T).
Let's now define K 2 N as the number of unique signal transmissions in a spectrogram, where the k th transmission occurs between the low-and high-time indexes k and the low-and high-frequency indexes f …; Kg).Each signal transmission will produce a submatrix inside T with all its elements set to one (Figure 1(a)).Each of these submatrices can be seen as a rectangular group of points with height m to the k th signal bandwidth.Each of these groups of elements is called an SA in this work.The k th SA can be mathematically defined as a subset of elements Signal transmissions are assumed to follow some protocol to avoid interference, therefore all SAs in the same spectrogram are assumed not to overlap (∩ K k¼1 S k ¼ ∅).Note that, by virtue of definition, t m; n ¼ 08 m; ð nÞ∉S k 8k and t m; n ¼ 18 m; ð nÞ 2 S k 8k, however this condition is not always satisfied in general for the associated elements b m; n of matrix B owing to errors in the process of signal transmission and detection (Figure 1(b)).
The purpose of SAE methods is to process the binary spectrogram B obtained by applying a threshold to a radio spectrogram P of continuous-power values with the aim to estimate the ground truth matrix T, which is unknown, as closely as possible so it can help to identify signal transmissions within the spectrogram (i.e., the true SAs) as accurately as possible.This is ultimately the purpose and objective of SAE.
The idea of SAE comes from the consideration of spectrum as a two-dimensional region in the time-frequency domain.As discussed by Sohn and Park [33], the spectrum can be divided Wireless Communications and Mobile Computing into a discrete grid of tiles, with each tile corresponding to an element or a slot/bin in the time-frequency matrix.A single signal is considered to occupy a single rectangular area in the matrix or spectrum, however several signals and therefore several SAs may be present in the same time-frequency matrix.The SAE or SA detection process aims to determine the number and locations of present SAs and considers two types of tiles in determining the SA: H 0 (unused) and H 1 (used).The SA, therefore, is represented by a set of adjacent occupied tiles (H 1 ) that are adjacent to one another in a rectangular shape (certain types of radio transmissions may not generate SAs with a rectangular shape.This is particularly true for electromagnetic emissions created by systems that are not intended for wireless communication, including various types of radars [34, Figures 1 and 9], microwave ovens [35,Figure 2(b)], and diverse sources of man-made noise [36,Figure 4].These specific types of signals have a particular signal format that requires an individual and tailored study.Such study falls beyond the scope of this work, whose focus is on signals employed in wireless communication systems, which are normally characterised by rectangular SAs in the resulting spectrograms).The concept and considered system model are illustrated in Figure 2.

Existing SAE Methods.
From the existing literature on SAE, the most common approach that many authors have exploited is ED-FFT [14] owing to its simplicity and reduced computation cost.This approach requires the determination of the state of each tile (busy or idle) in the time-frequency domain employing ED-FFT on a tile-by-tile basis [45].While simple and convenient, ED-FFT methods produce no rectangular estimation of the SA in the spectrum and therefore tend to be less accurate.Nevertheless, ED-FFT will be considered as a baseline or reference for comparison with the existing and newly proposed SAE methods.A more sophisticated approach is CT-SA, in which the algorithm approximates a rectangular SA by means of contour tracing techniques [15].A more accurate SAE method is the SSA strategy developed by by Mizuchi et al. [8] and Umebayashi et al. [10,12]; this is an elaborated method designed to estimate the SA in a spectrogram following a series of steps.The SSA steps include a raster scan to determine the first corner of a possible SA, a horizontal scan to estimate the width of the SA, then a coarse estimation of the height of the SA, and finally a fine height estimation process aimed at determining the dimensions of the SA.More recently, a minesweeper algorithm (MA) has been presented by Alammar and Lopez-Benitez [46], which makes a decision on the final state of each tile according not only to its own state but also the state of the tiles in the immediate neighbourhood.The MA method has a heuristic nature and does not necessarily always outputs a rectangular SA but can provide significant accuracy improvements both as a standalone SAE method and combined with CT-SA and SSA as a pre-or postprocessing technique.The MA can be seen as a form of MO-based SAE.Motivated by this observation, this work provides a more detailed and rigorous analysis of the potentials of MOs in improving the accuracy of SAE.

Morphological Image Processing
Noticing that the readership of this periodical will typically have a background in the field of communications engineering, this section offers an overview of the most relevant image processing concepts involved in this research and shows as well some examples of how MOs affect the process of SAE.
3.1.Overview.Image processing refers to the procedure of extracting meaningful information from an object to generate reports and data for further analysis [47].The analysis of images is a necessity in different disciplines, including engineering.Thus, there is a need for accuracy in the image processing technique that is adopted for a specific function or operation [48].
Mathematical morphology is a set theory and collection of nonlinear operations and techniques that provide an approach to digital image processing based on the geometrical structures (i.e., morphological image processing is related to the shape or morphology of features in an image).Depending on the type of operation, specific features of the objects in an image, such as shape and size, can be given consideration.The morphological image processing approach is used in the identification of the characteristics and properties of an image by removing irrelevant background information [49].The background is considered to be noisy and is eliminated to allow a more clear analysis of the object under study depending on its morphology.After the elimination of the background, the process then involves an analysis of the morphology.

Structuring Element. Morphological techniques probe an
image with a small template referred to as the structuring element (SE).The SE is a small binary image (smaller than the processed image) represented as a small matrix of pixels, each with a value of zero or one.The SE is defined by three main configuration parameters, namely: (i) the shape, which is usually a discrete representation of a continuous shape and is defined by the specific pattern of ones and zeros; (ii) the size, which is specified by the SE's matrix dimensions; and (iii) the origin, which identifies the pixel on which the SE is superposed when probing the image.In general, the origin of the SE can be located anywhere (including outside the SE), however it is usually one of its pixels, most commonly the one lying at the geometrical centre of the SE (which is the case considered in this work).Table 1 shows some examples of typical shapes for the SE commonly used in MO-based image processing.

Wireless Communications and Mobile Computing
It is worth noting that, while the origin can be freely chosen for any SE, the shape and size are not always completely independent configuration parameters.For instance, Table 1 shows that for an SE size of 7 × 7 pixels the disk/circle and diamond shapes are almost identical (only 4 out of the 49 pixels differ between both SEs); for a 5 × 5 SE, both shapes would be completely identical, and for a 3 × 3 SE the disk/circle and the diamond would both converge to a cross.
Establishing the shapes and sizes of an SE is predominantly an experiential procedure.However, the universal designation of a SE relies on the graphic figures and patterns that one sets out to extricate from the image data [50].Since the SE is a shape used to probe or interact with a given image to draw conclusions on how this shape fits or hits the shapes in the input image, one usually sets a way of differentiating objects (or parts of objects) from others according to their shape or spatial orientation by choosing a particular SE accordingly [47].Therefore, when the target is to identify rectangular SAs in the image data, it seems reasonable to select a SE with a squared or rectangular shape rather than SEs in the shapes of disks, diamonds or circles, for instance.The impact of the SE shape and size on the accuracy of MObased SAE will be analysed and discussed in more detailed in Section 5.

Morphological Operations.
A MO is conceptually defined by moving the SE over the binary image to be modified in such a way that it is eventually centred over every image pixel (based on the defined SE's origin), where a local logical operation is performed.The SE is moved across each possible location in the image and then compared to the neighbourhood of pixels.Some operations are designed to test whether the SE fits within the neighbourhood, while other operations test if the SE hits or intersects such neighbourhood.Based on the outcome of the applied MO, the pixel at the origin of the SE is assigned a value according to the associated logical operation.Therefore, in a MO the value of each picture element (pixel) in the output image is dependent on a collation of the analogous image at the input with its bordering (i.e., every pixel in the original image is adjusted according to the value of other pixels in its neighbourhood) [50].For every input image, MOs produce an output image of matching dimensions and proportions.A MO on a binary input image (as it is the case in the context of SAE) creates a new binary image in which each pixel has a nonzero value only if the logical test is true at that location in the input image.
This work investigates the SAE accuracy of the four main basic and most commonly used MOs, namely erosion, dilation, opening, and closing.It is worth noting that the interest and focus of this work is not on image processing techniques themselves but on their application and the potential benefits they can bring to the SAE problem.Therefore, this work focuses on the main existing MOs; other MOs that can be constituted as sequential combinations of these main MOs and/or by combining (adding/subtracting) their output with the original image (such as the adjunct of a binary image or the convergence of two or more binary images [47]) are out of the scope of this work.For the objectives of this work, the four main MOs are sufficient as it will be shown in Section 5. A description of the considered MOs is provided below.
(1) Erosion: the erosion of an input image I by a SE S (denoted I ⊖ S) produces a new image I new ¼ I ⊖ S with ones at all the locations x; ð yÞ at which that SE S fits the input image I.In other words, I new x; ð yÞ ¼ 1 if S fits I at x; ð yÞ and 0 otherwise, repeating for every pixel coordinate x; ð yÞ.The SE S is said to fit I at location x; ð yÞ when the SE's origin is placed at x; ð yÞ and all the SE's ones are matched by corresponding ones in the same positions of the input image I.In a binary image (as it is the case in SAE), a pixel is set to one only if all the neighbouring pixels (as defined by the SE) have the value one, and set to zero if any of the neighbouring pixels (as defined by the SE) have the value zero.Morphological erosion removes islands and small objects in the input image, so that only substantive objects remain, and makes gaps between different regions become more pronounced.However it also reduces the size of regions of interest.An example of the impact of erosion on SAE is shown in Figure 3(c Wireless Communications and Mobile Computing by a corresponding one in the same position of the input image I.In a binary image (as it is the case in SAE), a pixel is set to one if any of the neighbouring pixels (as defined by the SE) have the value one, and set to zero if all the neighbouring pixels (as defined by the SE) have the value zero.Morphological dilation has the opposite effect to erosion: it adds more pixels to the boundaries of existing regions, making objects more visible and reducing gaps between them.An example of the impact of morphological dilation on SAE is shown in Figure 3(d).
(3) Opening: the opening of an input image I by a SE S (denoted ) is attained by first eroding and then dilating an image using the same SE for both operations.With morphological opening, any regions that survive the erosion are (almost) restored to their original size by the subsequent dilation.The visual result of morphological opening is that larger objects joined by thin lines of adjacent pixels are disconnected, thus opening up gaps between such objects, hence its name.Morphological opening can remove small entities from an image while conserving the dimensions and proportions of larger objects almost unaltered.Noteworthy, opening is an idempotent operation, meaning that once an image has been opened, subsequent morphological openings using the same SE will have no further effect on that image (i.e., I ∘ S ð Þ∘S ¼ I ∘ S).An example of morphological opening in SAE is shown in Figure 3(e).(4) Closing: the closing of an input image I by a SE S (denoted ) is attained by first dilating and then eroding an image using the same SE for both operations (this sequence is the inverse of the morphological opening).Morphological closing enlarges an image and then corrodes the expanded image, with the visual effect being the repletion of gaps in the image.Closing is also an idempotent operation, therefore once an image has been closed, subsequent morphological closings using the same SE will have no further effect on that image (i.e., ).An example of morphological closing in SAE is shown in Figure 3(f ).

Application of Morphological Operations to SAE.
As discussed above, MOs can help to remove small objects from images (useful to remove signal false alarms) or replete gaps between objects (useful to overcome the impact of signal missed detections).This suggests that MOs can potentially handle and fix imperfections and degradations that are observed in real-life spectrum measurements, by overcoming the degrading impact of the signal detection errors (i.e., false alarms and missed detection) that are present in the process of SAE, which motivates their application in the context of SAE.
The simplest form of SAE is based on ED, which converts a time-frequency matrix of continuous power samples obtained from measurements into a binary matrix with zero/one (idle/busy) elements.This conversion is achieved by comparing the input power samples to a properly set decision threshold [44].Other methods specifically envisaged for SAE (such as CT-SA and SSA) take as an input a binary matrix (already obtained as the output of ED such as Figure 3(b)) and produce as the final output another binary Wireless Communications and Mobile Computing matrix with a (hopefully) more accurate identification of the desired SAs. Figure 4 shows an example of the outputs generated by the CT-SA and SSA algorithms when the input is as shown in Figure 3(b).MOs could be applied in this context as another SAE method, which also takes and produces binary matrices; in this case, the output matrix is the result of executing MOs on the input matrix, which can help identify existing SAs according to the shape and spatial orientation of the employed SE [51].However, as observed in Figure 3(c)-3(f ), MOs by themselves do not seem to provide an estimation of the true SAs shown in Figure 3(a) as accurate as those provided by the methods specifically designed for SAE such as CT-SA and SSA depicted in Figure 4. On the other hand, Figure 4 also shows that existing SAE methods from the literature are imperfect and certain gaps and other imperfections in the estimated SAs could be handled and fixed by means of MOs.This suggests that a combination of existing SAE methods and MOs could provide an improved accuracy in the estimated SAs.To obtain some insights into how MOs can contribute to enhace the performance of SAE, two scenarios of application are explored in this work: (i) first, a scenario where MOs are employed as a standalone method for SAE taking as input information the binary matrix obtained from the use of an ED principle (Figure 3(b)) and producing its own final output (Figure 3 (c)-3(f )); (ii) second, a scenario where MOs are combined with other relevant methods for SAE from the literature (such as CT-SA and SSA) which are used as a pre-or postprocessing stage in which MOs can be used only before, only after, or both before and after the other SAE method.The investigation of these two different scenarios is expected to shed some light on how to best formulate an appropriate MO-based SAE method.In the simulation, the generated time-frequency matrices (refered to as test grids) include channelised SAs that have occupancy statuses generated randomly through clearly defined constraints and are corrupted through the addition of random noise and interference.MOs are then applied to the ED, CT-SA, and SSA algorithms to evaluate the accuracy of the estimated SAs in the corrupted test grids.The process takes place in four distinct steps, namely time-frequency test grid creation, corruption of test grids, estimation of SAs, and assessment of the accuracy of the estimated SAs.

Methodology
Step 1: create clean time-frequency test grids.
For each simulation, a set of 100 random test grids is created with a resolution of 50 × 100 tiles, which represents a medium size [44].The horizontal dimension of 100 tiles represents the number of frequency points, with the vertical dimension of 50 tiles is determined by the time resolution.A group of on/off transmissions randomly generated from exponential distributions with rate parameters λ on ¼ λ off ¼ 0:5 s −1 and minimum on/off durations of 10 and 5 s, respectively, are generated for three different frequency channels with the same bandwidth, where only the central one is in use.Guard bands equivalent to 5% of the channel bandwidth (represented by always-idle tiles between channels) are included as well.These test grids emulate the original transmission pattern of the transmitter before the signal passes through the wireless channel and is degraded by propagation as well as internal and external noise and interference.Figure 3(a) shows a simple example with one single transmitter (i.e., one channel) in the test grid.
Step 2: add errors to the test grids.This step involves the addition of errors to the clean test grids generated in Step 1.The errors are added in such a manner that they affect both the idle tiles (false alarms) and busy tiles (signal missed detections).In specific, idle (busy) tiles can randomly change to busy (idle) state with a certain false alarm probability P fa (missed detection probability 1 − P d ).These probabilities are computed assuming that the measured power samples are transformed to binary idle/busy states by using an ED approach with a fixed probability of false alarm P fa ¼ 0:01 (notice that the resulting P fa can be easily controlled by properly setting the ED threshold.Selecting high P fa values would in principle lead to a degraded SAE accuracy and therefore it is sensible to keep P fa at a relatively low value such as P fa ¼ 0:01, which is a very common choice in the literature.)and thus an SNR-dependent probability of detection P d [44], Equations ( 1) and ( 2)].These test grids represent the pattern observed by the receiver or spectrum-aware monitoring system after the desired signals have travelled through the wireless propagation channel and have been deteriorated by  Wireless Communications and Mobile Computing propagation as well as internal and external noise and interference.Figure 3(b) shows how the test grid of Figure 3(a) is seen at the receiver side after applying of ED with a decision threshold corresponding to P fa ¼ 0:01 and a receiving SNR of −7 dB, at which P d ≈ 0:39.
Step 3: estimate the SAs.
In this step, one of the SAE methods described in Section 2.2 are applied and/or one or more of the MOs described in Section 3.3 to the (corrupted) noisy test grids obtained in Step 2 to estimate the SAs existing in the clean test grid.When MOs are applied, these are used either as a standalone SAE method as in Figure 3(c)-3(f) or in combination with the CT-SA and SSA algorithms shown in Figure 4 as pre-or postprocessing techniques (i.e., only before, only after, or both before and after).It is worth mentioning that the performance of the SSA method is sensitive to its configuration parameters.In this work, the detection masks of the SSA method were configured as by Umebayashi et al. [10] (Equations ( 3) and ( 4)), while the values for the sensitivity thresholds were the same as those suggested by Umebayashi et al. [10].This choice is assumed to perform well but may not necessarily lead to a perfectly fine tuning of the SSA performance in the case of the particular spectrum dataset used in this research (an optimisation approach is discussed by Umebayashi et al. [10], which is beyond the scope of this work).
Step 4: assess the accuracy of the estimated SAs.
In this step, the accuracy of the estimated SA obtained from Step 3 is assessed.This is achieved by comparing each test grid obtained in Step 3 to the corresponding original clean test grid produced in Step 1.

Experimental Platform.
Software simulations are a convenient and efficient way to test the performance of multiple configurations of MOs on synthetic spectrum data and determine the best configuration for each operating condition.However, a convincing demonstration requires validation with experimental spectrum data obtained from a real transmitter and receiver acting as a spectrum monitoring device.To this end, the hardware platform shown in Figure 5 is employed to acquire experimental data to validate the final version of the proposed MO-based SAE method.The platform is composed of: (1) a vector signal generator as the signal transmitter (Signal Hound VSG25A); (2) a coaxial cable (Mini-Circuits HandFlex 141-4SM+) along with (3) a 20-dB power attenuator (a Mini-Circuits VAT-20+) both together emulating a radio propagation channel; and (4) a real-time spectrum analyser as the signal receiver or spectrum monitoring device (Tektronix RSA306B).A wired connection is used in the experiments to prevent undesired interference between the experimental platform and other wireless devices operating in the surrounding area.A Matlab tailored control script is used to control the operation of transmitter and receiver using Instrument Control Toolbox available in Matlab along with the manufacturer's provided library and application programming interface (API).A central control host is used to ensure a correct synchronisation between transmitter and receiver operation so that the spectrogram observed at the receiver can be compared to the ground truth at the transmitter.The experimental procedure is parametrised to follow the simulation conditions.A careful calibration of the relationship between power transmitted by the signal generator and the SNR level received at the spectrum analyser is performed in order to allow a fair comparison of simulation and experimental results.

Performance Metrics.
The performance of the MO-based SAE approach investigated in this work could be intuitively assessed based on the measure of the fraction of tiles, either idle or busy, that are correctly detected in their true original state.This measure can be obtained as the sum of true positive and true negative detection rates.The limitation of such accuracy metric is that the number of tiles in one state may outnumber those in the other state, thereby introducing a bias in the value of the metric.Thus, the preferred metric used here is the F1 score, which takes into account potential imbalances between the number of idle and busy tiles in the original test grid.The F1 score is defined as follows: where TP, FP, and FN are the number of true positive, false positive, and false negative detections, respectively [52].As opposed to the accuracy metric, whose range of values is affected by the ratio of idle/busy tiles in the original test grid, the F1 score always ranges within the interval [0, 1] and therefore is a more fair and useful metric when there is an imbalance in the amount of idle/busy tiles in the original image, which is usually the case in most practical contexts.Therefore, the F1 score metric will be considered in this work.
It is worth mentioning that the performance of SAE methods could also be assessed through the probabilities of false alarms and missed detections.However, in SAE, the focus is not on the accuracy of the detection of individual tiles but on the detection of the entire SA present in the time-frequency domain.Since the detected SA results from a reconstruction of the subsets of tiles that are associated together, the analysis of the probabilities of false alarms  It is for this reason that the present study does not use these probabilities as performance measures for the studied MObased SAE methods and instead relies on the F1 score, which provides a single numerical quantity to assess the overall accuracy of the estimated SAs.
The computation time of each SAE method is also evaluated in this study.This measure is important because it affects the overall performance of the SAE method when it is practically implemented.It was observed by Mizuchi et al. [14] that there exists a strong correlation between computation time and overall implementation cost.Consequently, in the practical implementation of SAE methods, it is convenient to adopt the method that yields the lower computation times as far as possible.

Performance of MOs in SAE.
The first investigated aspect is the impact of the SE's shape.To this end, a maximum reference size of 3 × 3 pixels is selected for all shapes for a fair comparison.For this maximum size, several shapes are defined (square, horizontal, and vertical rectangle both in thick and thin formats, diamond, cross, and disk/circle (notice that for a 3 × 3 SE the shapes of disk/circle, diamond Concretely, it can be noticed in Figure 6(a) that erosion results in an overall accuracy degradation over the whole SNR range, regardless of the employed SE shape.This can be explained by the aggressive removal effect of small objects that erosion has on the processed image.This effect could be beneficial to remove false alarms, but unfortunately also removes portions of the actual SA when it has been degraded by the radio transmission process.The overall net effect, as it can be appreciated, is a general accuracy degradation (with respect to the case where erosion is not applied, which is the ED curve).On the other hand, dilation has a different effect depending on the considered SNR range as shown in Figure 6(b).At high SNR, dilation has a degrading effect, which can be explained by its expanding effect on small objects; this effect does not provide a more accurate detection of the actual SA, which is already easy to detect at high SNR, however augments the sizes of regions resulting from false alarms, thus degrading the overall accuracy at high SNR.However, dilation can be helpful at low SNR: it still augments the size of regions resulting from false alarms but also helps filling gaps in the distorted original SA, thus resulting in a more accurate SA detection.The overall net effect is favourable in this case.The square SE provides here the best accuracy improvement at low SNR, followed by the thick rectangular (3 × 2 and 2 × 3) SE shapes.This is in agreement with the intuitive notion that the SE shape should be selected in accordance with the geometric shapes that are attempting to be detected from the input image [51].Figure 6(c) shows that morphological opening has in general a similar effect as erosion, however with a noticeable accuracy improvement at high SNR.This is because the initial erosion step of the morphological opening removes small objects both resulting from false alarms and found inside the original SA, however the subsequent dilation step fills the gaps opened within the original SA so that the net effect of morphological opening at high SNR is an effective reduction of the incidence of false alarms, without significant degradation of the original SA, and hence Wireless Communications and Mobile Computing an overall accuracy improvement.In this case, particular shape employed for the morphological opening at high SNR is not relevant as all them provide a similar level of accuracy very close to one.Finally, Figure 6(d) shows that morphological closing provides an improved level of accuracy over the whole SNR range with respect to ED alone for all SE shapes, again with the best accuracies achieved by the square and thick rectangular SE shapes (3 × 2 and 2 × 3).However, when compared to the other MOs, closing the image by itself does not outperform dilation at low SNR nor opening at high SNR.This observation suggests that a suitable choice for MOs is indeed dilation at low SNR (with square SEs) and opening at high SNR (in principle with any SE shape, however a square SE could also be chosen here for simplicity).
To determine the impact of the SE size, F1 scores were calculated for different SE sizes using the best performing combinations of SE shapes as discussed above, namely square and both horizontal/vertical rectangular SE shapes.The obtained results are shown in Figures 7 and 8 for the two MOs with potential to improve the SAE accuracy at low and high SNR, respectively (i.e., dilation and opening).The considered SE size categories are as follows: extra small (2 × 2 square, 1 × 2 horizontal rectangle, and 2 × 1 vertical rectangle), small (3 × 3 square, 2 × 3 horizontal rectangle, and 3 × 2 vertical rectangle), medium (6 × 6 square, 2 × 6 horizontal rectangle, and 6 × 2 vertical rectangle), and large (9 × 9 square, 4 × 9 horizontal rectangle, and 9 × 4 vertical rectangle).These size categories should not be interpreted in absolute sense but in relation to the overall image size (e.g., the large size category represents in this case 9% and 18% of the horizontal and vertical image dimensions, respectively).Figure 7 shows that the SE size has a significant impact on the performance of morphological dilation.In particular, looking at the region of low SNR (where the morphological dilation is of interest), one can see that the selected SE size should increase as the SNR decreases.For very low SNR (around −20 dB), a large SE size gives a higher F1 score, while for moderately low SNR (just below 0 dB), small or extra small SE sizes give a better F1 score.On the other hand, Figure 8 shows that the accuracy of morphological opening does not change significantly when the selected SE size varies and it remains close to one at high SNR for all SE sizes.
To further explore the impact of the SE size in these two MOs, some additional results are provided in Figures 9-11  Wireless Communications and Mobile Computing when the original SAs are as shown in Figure 3(a).First, Figure 9 shows the output of dilation at an SNR of −7 dB using a horizontal rectangular SE shape, which according to Figure 6(b) is the SE shape that provides the best accuracy at that SNR.Moreover, Figure 10 shows the output of dilation at a lower SNR of −10 dB using in this case a squared SE shape, which according to Figure 6(b) is the SE shape that provides the best accuracy at this other SNR.The discussion above concluded from Figure 7 that when applying dilation in the low-SNR regime, the SE size should increase at lower SNRs.However, observing the examples of Figures 9 and 10 one can see that selecting large SE sizes does not really lead to a useful SAE, even though the numeric value of the F1 score may be higher in some cases.At such very low SNR values (such as −10 dB in Figure 10), an accurate estimation of the SA is not feasible regardless of the selected SE size.However, at slightly higher SNR values (such as −7 dB in Figure 9, only 3 dB more) selecting an extra small SE can provide a reasonable SAE accuracy, which becomes evident by comparing Figures 3(a) and 9(a).Therefore, when applying a morphological dilation at low SNR values, the selected SE size should remain at a small or extra small size; this may not lead to a useful SAE at very low SNR (which may not be feasible anyway) but will provide significant accuracy improvements at moderately low SNR values.Since the selected SE size does not have a significant impact on the resulting accuracy when applying morphological opening at high SNR (as observed in Figure 8 and confirmed by Figure 11) the same SE size selected for dilation at low SNR may also be employed for opening at high SNR.
The results presented so far correspond to MOs applied as standalone SAE methods.Simulations were also conducted to evaluate the performance of the four MOs (erosion, dilation, opening, and closing) when applied as pre/postprocessing to the CT-SA and SSA methods.For comparison purposes, Figure 12 shows the performance of the four MOs as standalone SAE methods while Figures 13 and 14 show the counterparts for the combination of MOs with the CT-SA and SSA methods, respectively.An extra small (1 × 2) horizontal rectangular SE has been selected in this example for illustration purposes, however similar observations and conclusions are obtained for horizontal vertical and square SEs. Figure 12 shows that MOs, when executed as standalone SAE methods, may be able to improve the accuracy provided by ED in certain SNR regions but, in general, are unable to outperform or simply provide a comparable estimation accuracy when compared against other methods specifically designed for SAE such as CT-SA and SSA.Therefore, MOs by themselves cannot be used as a standalone SAE method.Nevertheless, the results shown in Figures 13 and 14 demonstrate that MOs can help improve the performance of other existing SAE methods when employed as pre/postprocessing techniques.In particular, it can be noticed that, in line with previous observations, erosion tends to have a degrading effect on the SAE accuracy, dilation tends to improve the accuracy in the lower SNR range (with higher improvements when applied both as a pre-and postprocessing technique to the other SAE methods), opening improves the accuracy in the higher SNR range (in this case it is enough when used as a preprocessing technique only (note that in Figures 13(c) and 14(c) the curves for preprocessing only overlap the curves for both pre-or postprocessing)), and closing has no significant impact on the final resulting accuracy.These observations can be exploited to formulate an MO-based SAE method as discussed below.for the SE).Dilation and opening both help in the morphological filtering process, which can be used to extract the useful SA from the noisy input [53,54].Based on these observations, a simple approach would be to set an SNR threshold such that any SNR value below (above) the threshold is considered to be low (high) SNR and the appropriate MO is applied.However, it can be shown that there exists a certain region of intermediate SNR values (between the so called regions of low and high SNR) where the optimum MO and pre-or postprocessing application may not be any of those observed at low or high SNR.This motivates a more flexible version of the method that distinguishes between low, intermediate, and high SNR ranges and selects the best MO for each.Accordingly, and based on the results presented above, the proposed MO-based SAE method is formulated as follows: th ): perform morphological opening only before the employed SAE method with an extra small SE of any appropriate shape (e.g., squared or rectangular).
The above proposed method is formulated by selecting the optimum MO along with its optimum application and configuration that is observed to provide the best SAE accuracy according to the results obtained and discussed in Section 5.1.The parameters SNR L th and SNR H th are thresholds that delimit the regions of low, intermediate and high SNR and therefore where each MO provides the best accuracy.To determine the optimum thresholds, F1 scores were calculated for threshold values between −10 and −5 dB (where the lowto-high SNR transition occurs).The exhaustive search concluded that SNR L th ≈ -8 dB and SNR H th ≈ -5 dB yield the best accuracy.
The formulation of the proposed algorithm is supported by the obtained simulation results and can be justified as follows.First, at low SNR one can expect a higher number 16 Wireless Communications and Mobile Computing of missed detections.Such missed detections will likely leave a reduced number of busy pixels where a SA was originally present, thus making those few busy pixels the only remaining vestige of the SA that was originally present in that region.Therefore, one can maximise the probability of detecting as much of the SA in that region as possible by following an aggressive detection approach where the presence of a single busy pixel in the neighbourhood of the SE is enough to set the pixel in the centre of the SE as busy.This can explain why a dilation is the most convenient morphological operation at low SNR values (below a properly set threshold).Moreover, due to the difficulty of detecting signal components at low SNR, the greatest benefits can be obtained by dilating the image both before and after the employed SAE method; recall that morphological dilation makes objects more visible and fills in small holes/gaps in the image, thus making SA detection easier for other SAE methods if applied beforehand (preprocessing) and making the SAs (or their portions) detected by the other SAE methods further visible if applied also afterwards (postprocessing).On the other hand, at high SNR the dilation operation should also enhance the detection accuracy by filling in gaps within SAs degraded by missed detections.However, the main problem of morphological dilation under high SNR conditions is that the filling of these Wireless Communications and Mobile Computing gaps does not compensate the amplification of false alarms, which are made more visible as a result of the dilation.For this reason, under high SNR it is more convenient to perform first a morphological erosion (in order to remove as many false alarms as possible) followed by a morphological dilation (to safely fill in gaps within degraded SAs once false alarms have been removed).This can explain why opening is the most convenient morphological operation at high SNR (above a properly set threshold).Moreover, due to the relatively easiness to detect signal components at high SNR, it is enough to perform this operation only before applying the other SAE method (results show that it could be applied afterwards as well but this does not provide any accuracy improvements while increases slightly the computational cost).Similarly, at intermediate SNR morphological opening is still the most convenient choice, however in this case performed only after the employed SAE method.
The results shown in Figure 15 provide supporting evidence for the discussion above, showing that the proposed MO-based SAE approach provides the best overall accuracy over the whole SNR range.The accuracy obtained in the transition area of intermediate SNR values is marginally above that of the original SAE methods without any MOs and comparable to that of the original SAE methods with the MA technique proposed in [46].However, the application of carefully selected and properly configured MOs can provide significant accuracy improvements both at low and high SNR.In the low-SNR region, the accuracy improvement (as quantified by the F1 score) can be as large as 40% (for CT-SA with and without MOs at −10 dB), while in the high SNR region the proposed method achieves a perfect accuracy of 100% (the only method that achieves this level of accuracy at high SNR).It can also be noted that CT-SA and SSA tend to have a noticeably different performance when applied without MOs, but become more similar when MOs are introduced (the same observation applies to the introduction of the MA method).The performance of SSA with MOs tends to be slightly better than that of CT-SA with MOs (in particular at low SNR), which is obtained at the expense of a greater computational cost as shown in Figure 16 resulting from the more complex algorithm associated with the SSA method.Interestingly, it can be noted that the introduction of MOs in the SAE process not only leads to significant accuracy improvements for both CT-SA and SSA as shown in Figure 15 but in some cases can even do so at a lower computational cost as shown in Figure 16.This can be explained by the benefits of using adequate MOs in SAE: these operations, when used properly, can reduce false alarms and fill gaps within the original SAs resulting from missed detections, which facilitates and simplifies the task of detecting SAs for both CT-SA and SSA.As a result, the CT-SA and SSA methods can detect the SAs more accurately and do so at a similar or even lower computational cost, because the enhancements introduced by the application of MOs beforehand reduces the number of computations required by both SAE methods (this is particularly true at high SNR).Therefore, it can be concluded that the proposed MO-based SAE method can help existing SAE methods provide a significantly more accurate estimation of the existing SA without increasing the computational cost and, in some cases, even reducing the associated computational workload.This can be seen in Table 2, which summarises the results shown in Figures 15 and 16.
Finally, Figure 17 validates the performance of the proposed MO-based SAE method by comparing the performance forecasted by simulations with the actual performance obtained based on experimental data collected with the experimental setup presented in Section 4.2.As it can be observed, simulation and experimental results match very closely over the whole range of SNR values, except perhaps for SNR values slightly 18 Wireless Communications and Mobile Computing below the low SNR switching threshold, SNR L th , where a maximum deviation between simulation and experimental results of around 1 dB is observed over a short SNR interval.In this SNR region, the actual experimental performance is indeed slightly better than predicted by the simulations.The results shown in Figure 17 indicate that the use of MOs can actually improve the performance of existing SAE methods significantly when implemented in practical systems.

Practical Implementation
Remarks.The proposed SAE method decides the optimum procedure to be followed based on the SNR of the signal whose area is to be detected and estimated.In practical system implementations, this information may or may not be available depending on a broad range of technical and practical aspects.Several options can be proposed when the SNR information is not available and cannot be estimated directly by the spectrum monitoring receiver.In some cases it may be possible to make an educated guess of the expected SNR; for instance, if the transmitter location is known and its transmission power is constant and known (or can be estimated), then the use of a suitable path loss model can give a good approximation to the expected SNR (or expected range of SNR values if the transmission power is variable).Note that, in general, the SNR does not need to be known or estimated to a great level of accuracy since the relevant aspect is whether the SNR is greater or lower than the thresholds SNR L th and SNR H th .In a worst-case scenario where nothing is known about the signals that may be present, the solution would be to apply the three procedures described in Section 5.2 for the low, intermediate and high-SNR regimes and select the output with the highest response.This approach increases the chances of a more accurate result for completely unknown signals at the expense of an increased computational cost.

Conclusion
The concept of SA (defined as a set of contiguous occupied tiles that are adjacent to one another forming a rectangular shape within a time-frequency matrix of spectrum measurements) is relevant in dynamic spectrum access, verification and enforcement of spectrum regulations, and network planning and optimisation.This work has explored the applicability of MOs from the field of image processing in the context of SAE, analysing their individual impacts when applied both as standalone SAE methods and as pre/postprocessing techniques to other existing SAE methods (such as CT-SA and SSA).When used as standalone SAE techniques, the optimum choice has been shown to be morphological dilation in the low-SNR regime and morphological opening in the high-SNR regime, where the SE used by MOs should be configured to adopt a square shape with a small size in relation to the overall image dimensions (e.g., around 5% or less).However, MOs as standalone SAE techniques are usually unable to achieve high levels of accuracy.On the other hand, the obtained results have demonstrated that MOs can provide significant accuracy improvements in the accuracy of the detected SAs when combined with other SAE methods as pre-or postprocessing stages with carefully selected and properly configured MOs for each SNR regime.This has been exploited in this work to propose an optimised MO-based SAE method that selects the best combination of MO an pre-or postprocessing application for each SNR range, concretely by applying dilation at low SNR (both as pre-or postprocessing stages simultaneously), opening at intermediate SNR (only as a postprocessing stage) and opening at high SNR (only as a preprocessing stage).The corresponding optimum SNR thresholds between the three operating regions have been determined to be −8 and −5 dB, respectively, based on the extensive search simulation results.The application of the proposed MO-based SAE approach can provide significant accuracy improvements  Wireless Communications and Mobile Computing both at low SNR (with gains of up to 40%) and high SNR (reaching 100% accuracy levels).This is achieved without having a noticeable impact on the associated computational cost (and even reducing it by up to 15% at high SNR).When used properly as indicated above, MOs can reduce false alarms and fill gaps within the original SAs, which facilitates and simplifies the task of detecting SAs for both CT-SA and SSA methods.As a result, the proposed MO-based SAE method can help existing SAE methods provide a significantly more accurate estimation of the existing SAs without increasing, and in some cases even reducing, their computational cost.
The results presented in this work have demonstrated that the use MOs from the field of image processing have the potential to provide significant performance improvements in the problem of SAE.This motivates the investigation of other image processing techniques to further improve the SAE accuracy, which is suggested as future work.The development of additional new variants aimed at reducing the presence of false alarms before the application of SAE methods, which has been shown in the previous work to improve the SAE accuracy, is another idea worth investigating in detail in the future work.

FIGURE 3 :
FIGURE 3: Several versions of the same time/frequency grid: (a) original generated by transmitter, (b) observed at receiver after ED (with threshold set for P fa ¼ 1%) at SNR = -7 dB (P d ≈ 0:39), (c) eroded at the receiver with a 1 × 2 rectangular SE, (d) dilated at the receiver with a 1 × 2 rectangular SE, (e) opened at the receiver with a 1 × 2 rectangular SE, and (f ) closed at the receiver with a 1 × 2 rectangular SE.

4. 1 .
Simulation Procedure.This experimental study adopts the use of simulation to test SAE techniques based on MOs.

FIGURE 4 :
FIGURE 4: Outputs generated by: (a) CT-SA algorithm, and (b) SSA algorithm, when the input is as shown in Figure 3(b).

FIGURE 7 :
FIGURE 7: F1 score for dilation with different SE sizes and shapes: (a) square, (b) horizontal rectangle, and (c) vertical rectangle.

FIGURE 10 :
FIGURE 10: Dilation at SNR = -10 dB using a squared SE for the SAs shown in Figure 3(a): (a) extra small, (b) small, (c) medium, and (d) large.

FIGURE 11 :
FIGURE 11: Opening at SNR = +5 dB using a squared SE for the SAs shown in Figure 3(a): (a) extra small, (b) small, (c) medium, and (d) large.

FIGURE 17 :
FIGURE 17: Experimental validation of the proposed method.

2
Wireless Communications and Mobile ComputingMOs on the accuracy of SAE.To the best of the authors' knowledge, this has not been considered before in the open technical literature.By means of simulations, the result of employing a diverse range of MOs in the context of SAE is investigated under multiple configurations of the MOs and various operating conditions.The analysis is carried out over a sufficiently large interval of signal-to-noise ratio (SNR) values that are representative of the typical operating conditions in wireless communication systems.In such analysis, the performance of MOs is analysed when used both as a stand-alone SAE technique and together with other SAE methods that have been proposed in the literature (as preor postprocessing stages).Based on the outcomes of this study, a suitable MO-based SAE method is formulated, which employs MOs as pre-or postprocessing techniques to other existing SAE methods.
). (2) Dilation: the dilation of an input image I by a SE S (denoted I ⊕ S) produces a new image I new ¼ I ⊕ S with ones at all the locations x;ð yÞ at which that SE S hits the input image I.In other words, I new x; ð yÞ ¼ 1 if S hits I at x; ð yÞ and 0 otherwise, repeating for every pixel coordinate x; ð yÞ.The SE S is said to hit I at location x; ð yÞ when the SE's origin is placed at x; ð yÞ and at least one of the SE's ones is matched 0

TABLE 2 :
Performance summary for the proposed MO-based SAE method.