3.1. Laboratory Test Stand and Experiments
The proposed measurement system (
Figure 2) based on [
2] allows for performing Data Acquisition (DAQ) with the frequency between a couple kHz to a single MHz. It consists of two computers working as DAQ modules and software for processing the collected data. The first computer (MF unit) is used to acquire samples with the frequency
= 62.5 kHz on 16 channels simultaneously with 16-bit resolution. The second computer (HF unit) allows for the DAQ with
up to 10 MHz on two channels at the same time, with the 12-bit resolution. Signals representing values of the total current in the main power line
and the
-th socket (
)
are measured using the current transformers (indicated in
Figure 2 as
and
).
The key for automatically describing measurement data is the simultaneous current measurement for each appliance connected to the network. In the presented system, it is possible thanks to sensors attached to each socket. The MF unit allows for acquiring samples of currents consumed by the particular appliances connected to sockets. The identification algorithms use data derived from the aggregated current (signal) and supply voltage (signal ).
Measurements by both computers (MF and HF) are implemented in the LabVIEW-based software [
2]. In the HF setup, measurements are performed with
= 250 kHz, while for the MF,
=12.5 kHz. Descriptions of the measured data (labeling the actual appliances state in the particular time instants) are added automatically after acquisition using the Matlab script. Characteristics of the measured appliances (including the number of events recorded during the laboratory tests) are in
Table 1. The column “
” contains the appliance identifier. The column “Number of events” presents the number of events recorded during laboratory tests, which is caused by the change of this particular appliance’s state.
Experiments were conducted for 15 typical devices used in the household. In our research, we focused on two-state appliances, as it is easy to determine their actual configuration, enabling unambiguous verification of the results. In the case of multi-state appliances (such as a washing machine or dishwasher), it is often difficult to isolate their specific operational states. The fridge measured on channel no. 14 was not identified, working constantly in the background to verify the ability of the EA identification with additional signal components present. The fridge operation is characterized by the periodical changes in the current consumption.
The problem of identifying appliances with the non-zero background was introduced in [
38]. Disaggregation algorithms in the configuration of multiple devices working simultaneously were considered in [
42,
43,
44] but disregarding the influence of the background on the appliances’ identification. This makes the proposed research the next step of the NIALM systems’ development.
The data collection consisted of repeatedly turning the single device on or off and acquiring samples related with the state change. As a result, the training data set was created, containing examples representing particular events with the following elements:
Event type (on or off);
The actual device identifier;
Time instant of the event occurrence;
Recorded current samples;
Recorded supply voltage samples;
Other information regarding the appliance identification methods (such as the number and type of appliances operating in the background).
To include all appliances into the data set, the currents were measured in all sockets simultaneously. During the online implementation, the information about the sockets to which the devices are connected is not given, but during the training, the actual configuration of the network is known.
3.2. Appliance Signature Construction
During the stable operation of the appliance, the recorded instantaneous current values repeat in the periodically recurring time instants (
). The period is determined using the timestamps
, i.e., the moments when the fundamental voltage component crosses zero (changes from negative to positive). The index
is number of the period in the supply voltage fundamental component. When adding the appliance to the network, turning it on or off, or changing its state, the instantaneous values of the current change. Steps required to extract the vector of changes
occurring in the
-th period are presented in
Figure 3. To describe the event,
and
samples are needed. They are the result of sampling signals
and
by the HF unit (see
Figure 2).
The proposed method can be used independently of the supply voltage frequency, so it is applicable for both European and American households. The idea is to determine the difference between instantaneous values of the current in the specific periods of the voltage fundamental component, which were measured at the time instants
in different periods
. The nominal frequency of the supply network signals is assumed constant, but in practice, small changes are present around fractions of the single Hz [
45]. To suppress any deviations, the time instant
must be determined for each consecutive period. The proper selection of time instants
requires low-pass filtering (LPF in
Figure 3) of the original voltage signal
with the cut-off frequency of 70 Hz, outputting the signal
. This is needed to eliminate the influence of harmonics higher than the fundamental component. In
Figure 4a, the current pattern during the event of turning the sconce with four LED bulbs on (device with identifier
a = 3) is presented. The method for extracting the appliance signature from the red fragment of
Figure 4a is in
Figure 4b. Time instants
, for which the voltage samples
change signs from negative to positive are indicated by red dots. They show initial moments for subsequent periods
. Here, the turn-on event is detected in the 23rd period.
Time instants
are used for transforming collected current samples
into the array
. Its particular elements represent the instantaneous current values occurring in the same time position within each period
. The latter contains
samples, which are identified by the index
. The period’s duration is 20 ms (50 Hz supply voltage) for the sampling frequency
fs = 24,900 Hz, while the
IP array contains
rows, each processed by the median filter (of the 15th order), leading to the array
Figure 5a presents the first 250 samples in each row of
, while
Figure 5b shows corresponding rows
(1) of
. These constitute the first halves of the current periods (see
Figure 4a). Comparison between
Figure 5a,b shows the effect of the median filtering (elimination of the high pitch indicated by the blue dot). Differences between two neighboring periods (
= 23 and 24) reveal changes in the instantaneous current values caused by the appliance state change (the respective green and red dots).
The last step is determining the vector of changes
(2) after the appliance state change. For this purpose, the difference between vectors equally distant in time from the
-th vector of the array
is calculated. The distance (number of periods) is defined by the value
set individually (see
Table 2 and
Table 3) for each of
appliances
(a = 1, …,
A). It is obtained by subtracting samples of all periods’ pairs (such as
k = 1 and
k = 2,
k = 3 and
k = 5 and so on) in the steady state of the appliance operation. The difference
(3) is calculated for each sample
m in the periods preceding (
k − o) and succeeding (
k + o) the period of interest (
k).
The set of changes
is the feature vector, which is used to classify the appliance’s state
. It is identified by comparing the currently analyzed vector and all dictionary entries
representing appliances recognized in the network.
Figure 6 shows vectors
calculated for the signal from
Figure 5a and
for the signal from
Figure 5b.
Similarly to [
27], the proposed method allows for identifying the specific appliances with all possible combinations of devices working in the background. Recording only the single state change of each appliance is required for this purpose. During the event from
Figure 4 and
Figure 5, the transient state lasts for less than one period of the voltage signal, which is enough in our case. Vectors of samples’ changes
obtained when turning the selected appliances on are presented in
Figure 7. Black patterns extracted from the filtered array
are visible with original, green vectors from the
array in the background. Similar patterns were observed while turning the devices on: LED Philips 13 W—
Figure 7c and LED Osram 13 W—
Figure 7e.
Filtering allowed for highlighting the signal components’ characteristics.
3.3. Event Detection and Appliance Identification
The event detection in the proposed method is carried out independently for each appliance. Subsequent steps taken during each period are presented in
Figure 8. Selected 14 devices can be in 2 states (ON or OFF), which gives 28 categories to identify.
Table 2 shows the most useful values of
for specific subsets of devices. To detect the appliance change, the differences between vectors
(2) are calculated to determine the similarity
(5) between the analyzed pattern
and all patterns in the dictionary. The minimum Euclidean distance
identifies the event
}, i.e., device
changing state into
. The average absolute value
σ (4) of
normalizes values of
in (5) for different devices. Calculation of the Euclidean metric facilitates visualization of the values of
SF. When
exceeds the threshold value
for the device
and state
, it means that in the
k-th period, the event
occurs. The thresholds are experimentally set to either 2 or 5, the former being enough for devices with power below 50 W.
To indicate the potential time instants of events in the system, the detection array
is calculated:
Summing columns of
produces the detection vector
, indicating how many appliances potentially changed state in the
k-th period.
Potential errors of the algorithm are due to the similar patterns for different appliances. For instance, events a,s = {5,ON} (turning the LED Philips 13 W on) and a,s = {9,ON} (turning the LED Osram 13 W on) are difficult to distinguish. In particular, it is possible that for more than one device, the value of exceeds the threshold value . In such a situation, the device with the highest value of is considered to be the one that changed its state.
To limit false-positive detections, it was assumed that two subsequent events have to be separated by at least 0.2 s. Secondly, the duration of the event (number of consecutive periods during which the value of is greater than threshold value ) must last longer than half of the value . That eliminates false detections resulting from short-term changes in the signal during which the vector of changes is similar to any pattern .