1 Using the PI ProcessBook to Monitor Activities of 2 Daily Living in Smart Home Care within IoT 3

This article describes the use of the PI ProcessBook software tool for visualization and 11 indirect monitoring of occupancy of SHC rooms from the measured operational and technical 12 quantities for monitoring of daily living activities for support of independent life of elderly persons. 13 The proposed method for data processing (predicting the CO2 course using neural networks from 14 the measured temperature indoor Ti (°C), temperature outdoor To (°C) and the relative humidity 15 indoor rHi (%)) was implemented, verified and compared in MATLAB SW tool and IBM SPSS SW 16 tool with IoT platform connectivity. Within the proposed method, the Stationary Wavelet Transform 17 de noising algorithm was used to remove the noise of the resulting predicted course. In order to 18 verify the method, two long-term experiments were performed, (specifically from February 8 to 19 February 15, 2015, from June 8 to June 15, 2015) and two short-term experiments (from February 8, 2


Introduction
At present, there is an increase in the use of modern technologies in the field of building automation (in accordance with European legislation of Directive 2010/31/EU on the energy performance of buildings and in accordance with Directive 2012/27/EU on energy efficiency and changes thereof).In order to provide a user-friendly environment for the management of the operational and technical functions along with providing support for the independent housing of senior citizens and disabled persons in buildings indicated as Smart House Care (SHC), it is necessary to make appropriate visualization of the technological process as required by the users with the possibility of indirect monitoring of the seniors' life activities based on the information obtained from the sensors used for the common management of the operational and technical functions in SHC.The properly devised visualization complements the final correct functionality of the intelligent building.
Beaudin describes the use of computational and sensor technology in intelligent buildings with a focus on health monitoring in the households.The work comprises a visualization for displaying health data and a proposal for improving the health and wellbeing of the users [1].Booysen explores machine-machine communication (M2M) to address the need for autonomous control of remote and distributed mobile systems in intelligent buildings [2].Basu uses miniature wireless sensors in the persons in context easy-to-use interaction models based on natural language processing development [24].Carvalko describes Medical technology verges on incorporating directly into our anatomy processors with the computational power of the Watson IBM computer and Internet-like communications within the eventual merging of synthetic DNA and artificial intelligence that together will bring new diagnostics, medical treatment, and smart nano-prosthetics well within the horizon of the next generation [25].The goal of Cervenka is to define various ways to apply cognitive systems for unstructured data analysis and management for further use in marketing analytics with IBM Analytics Tools for analyzing unstructured data found on social media [26].Chen answers the question how cognitive computing can be applied to big data challenges in life sciences research with IBM Watson for training to understand technical, industry-specific content and use advanced reasoning, predictive modeling, and machine learning techniques to advance research faster [27].
Coccoli goes in the direction of developing the smart university model, by using innovative and intelligent services to help to raise a new generation of software engineers but also to promote and disseminate a new way for designing and building innovative applications through hands-on labs on cognitive computing with a software development environment based on the Platform as a Service (PaaS) [28].Devarakonda developed problem-oriented Electronic Medical Records EMR summarization to address this issue, as a part of a larger effort of adapting IBM Watson to the medical domain with presentation building the next generation EMR, one that is based not on just keeping record but instead on a conceptual understanding of medicine, thereby crossing the threshold from record storage to an intelligent entity for clinical decision making [29].Guidi describes the main tools available on the market to perform Analytics as a Service (AaaS) using a cloud platform with a use case of IBM Watson Analytics, a cloud system for data analytics, applied to the following research scope: detecting the presence or absence of heart failure disease using nothing more than the electrocardiographic signal, in particular through the analysis of Heart Rate Variability [30].Kolker describes the PPT-DAM (People-Process-Technology empowered by Data, Analytics, and Metrics) implementation by the Benchmarking Improvement Program at the Seattle Children's Hospital with the results, that cognitive systems in general and IBM Watson in particular, if properly implemented, can bring transformative and sustainable capabilities in healthcare far beyond the current ones [31].
Murtaza discusses an effective strategy to train IBM Watson question answering system for Big Data Analytics where they have observed that if documents are well segmented, contain relevant titles and have consistent formatting, then the recall of the answers can be as high as 95% [32].AlFaris reviews the smart technologies; the interface and integration of the meters, sensors and monitoring systems with the home energy management system (HEMS) within IoT with the outline that the smart home in practice provides the ability to the house to be net-zero energy building.Especially that it reduces the power demand and improve the energy performance by 37% better than ASHRAE standards for family villas sector [33].Alirezaie presents a framework called E-care@home, consisting of an IoT infrastructure, which provides information with an unambiguous, shared meaning across IoT devices, end-users, relatives, health and care professionals and organizations and demonstrates the proposed framework using an instantiation of a smart environment that is able to perform context recognition based on the activities and the events occurring in the home [34].Bassoli introduced a new system architecture suitable for human monitoring based on Wi-Fi connectivity, where the proposed solution lowers costs and implementation burden by using the Internet connection that leans on standard home modem-routers, already present normally in the homes, and reducing the need for range extenders thanks to the long range of the Wi-Fi signal with energy savings of up to 91% [35].Catherwood presents an advanced Internet of Things point-of-care bio-fluid analyzer; a LoRa/Bluetooth-enabled electronic reader for biomedical strip-based diagnostics system for personalized monitoring, where are solved highlights practical hurdles in establishing an Internet of Medical Things network, assisting informed deployment of similar future systems [36].The source of CO2 concentration in residential buildings is primarily the human being [37].Due to the high cost of SHC sensor equipment, there is an effort to reduce investment costs by using appropriate SC methods, while using available information from existing sensors to ensure management of the operational and technical functions in SHC.In this article, to monitor the presence of persons in SHC rooms, a method for predicting the CO2 course using the multi-layered forward ANN using the BRM from the measured indoor temperature values Ti (°C) and the relative humidity indoor rHi (%), with the subsequent use of trend signal detection based on WTA is revised and verified [38].
The objective of the article is the performance of a new method for prediction CO2 course from the measured temperature variables Tindoor (°C), the relative humidity rHindoor (%) and the temperature Toutdoor (°C) within monitoring the presence of persons in an SHC room using the SW Tool PI System (PI-Plant Information enterprise information system) and SPSS IBM IoT platform SW Tool.
The main contribution of the article is to verify the assumption of improving the accuracy of the The aim of the fourth part of the article is to use ANN to predict the measured quantities for the purpose of monitoring the ADL in a real-world SHC environment using of SPSS IBM SW Tool within IoT platform implementation.To predict the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior of the SHC in the selected room R204 and from the outdoor temperature readings To (°C), with the ANN Radial Basis Function (RBF) network, which is a feed-forward network that requires supervised learning.For the classification of prediction quality, a correlation analysis (correlation coefficient R), calculated MSE (Mean Squared Error) and Mean Absolute Error (MAE) are used.

Decription of used technologies in SHC
SHC is located at VŠB-TU Ostrava in Czech Republic and was created on the basis of a requirement for creating a platform where research and monitoring of current technologies in the field of intelligent buildings could be conducted.The purpose of this platform is, in particular, to verify the efficient energy management and the reduction of the operational costs of the building in real conditions.This is a two-storeyed wooden building with an area of 12.1 x 8.2 m, built in a passive standard.The BACnet technology, which works on the BACnet/DESIGO PX PXC 100-E.D process station, is used for HVAC (Heating, Ventilation and Air Conditioning) management.On the other hand, the KNX technology provides control of lighting, blinds and switching on and off of the socket circuits in the building.The existing security electronic system (EZS) is connected to the KNX technology via binary inputs [24].To visualize the operational and technical functions in SHC, the Desigo Insight software tool, which contains a database for storing measured values from individual technologies, is used in this building.This software also provides a visualization section for displaying control and regulation of individual functions in the building.However, the Desigo Insight software tool is not suitable for the actual processing of the measured data.Therefore, the OPC BACnet server was used to implement connectivity between the PI System SW tool and the Desigo Insight software tool (Fig. 1).The PI System includes SW tools such as PI ProcessBook for user-friendly data readout with the ability to create an application for visualization and monitoring of SHC residents activities (Fig. 2, Fig. 3) [39][40].

Visualization for the SHC created in the PI ProcessBook tool
Visualization of the wooden house in the PI ProcessBook tool is divided into several screens, which is possible continuously access from the main screen (Fig. 2).The SHC control technology is integrated on each visualization screen in accordance with the Building Management System (BMS).
These screens further comprise buttons for entry into individual rooms.After clicking on the relevant room button, a new window, containing a detailed description of the technology used in the specific room shown in the individual charts, will appear.Each technological element is illustrated in the chart, wherein the individual charts are sorted in accordance with the groups of elements used (Fig. 3).The individual technology units are then displayed on separate screens and can also be viewed from the main screen.This solution was chosen because it is not possible to place all the information about the technologies implemented on one screen so that the screen remained well-arranged.Additional distribution of the technologies into individual screens will allow the user to get a better insight into what elements belong to the individual technologies and which do not anymore.Thanks to this solution selected, orientation in The visualization, monitoring, and processing of the measured values of non-electric variables, such as measurement of temperature, humidity, CO2 for monitoring the quality of the indoor environment of the selected room in the building described, are implemented using the PI System software application and MATLAB R2014b SW Tool. Figure 4 shows the process of measuring and processing data in connection with the use of the PI System SW tool (PI ProcessBook) in the SHC.

Bayesian regularization backpropagation algorithm -Backpropagation algorithm
Back propagation or the error back-propagation algorithm is a gradient algorithm for the adaptation of multi-layer feed forward networks.Organizational dynamics in the error backpropagation is equivalent to the multi-layer Perceptron.The network is formed by fixed acyclic topology with an input and output layer and one or two inner layers of hidden neurons.A universal solution for the number of neurons in the hidden layer so that the computing time is minimized and provides the most accurate result, has not yet been found.There is Bayes Regulation Method (BRM) offered for an optimizing training method.The BRM differs from the previous two in that it does not work with the validation set.It can be said about BRM in general that it generalizes small or complex datasets or datasets containing noise rather well.The training ends with the minimizing of weights.
In the next step the neural network itself is set up, specifically the number of neurons in the hidden layer.The parameters of the neural network are selected sequentially with 10, 50, 100, 150, 200, 250, 300, 350, 400, 450 and 500 neurons in the hidden layer (Tables 1-8).
For the hidden layer, the hyperbolic tangent function was used and linear functions for the output layer.(Tables 1-8) lists the calculated parameters of MSE, correlation coefficient R, Euclidean distance (ED), City Block distance (CB) in order to compare the quality of learning of BRM.(Tables 1-8) shows that the results gradually improve with an increasing number of hidden neurons.
Although this behaviour does not represent a rule in the field of neural networks (it often happens that the setup of algorithms and data and the results are not unconditionally in direct proportion), ANN (BRM) using measurement data exhibit behaviour naturally expected for the task.The lowest values of MSE and at the same time the largest values of correlation coefficients R are shown in BRM.
The disadvantage for BRM is the relatively long time in learning ANN.The designed application for monitoring technological processes in the SHC can be used for obtaining information about the current state of the measured variables from common operating sensors (temperature T, rH, CO2) for further practical applications in the context of operational and technical functions in the SHC.

Implementation of predictive analysis using IBM SPSS modeler
IBM SPSS offers two type of neural networks: Multilayer Perceptron (MLP) and Radial Basis Function (RBF), where MLP is categorized as a feed-forward, supervised learning network that can support up to two hidden layers.Basically, MLP is a function of one or more predictors that provides minimized prediction error for the targets.Additionally, there is an option of choosing between automatic or manual setting for the number of units

Materials and Methods
In this section, we introduce a method for the CO2 concentration course noise cancelation based on the Wavelet transformation.In the signal processing, we assume that each signal y(t) is composed from two essential parts, namely they are the signal trend T(t) and a component having a stochastic character X(t) which is perceived as the signal noise and details.Based on this definition, we can use the following signal formulation (3): The major problem, when the signal trend is being extracted, is the noise detection.There are many applications of the trend detection including the CO2 measurement.Such signal may be influenced by the glitches which should be removed to obtain a smooth signal for the further processing.The wavelet analysis represents a transformation of the signal y(t) to obtain two types of the coefficients, particularly they are the wavelet and scaling coefficients.These coefficients are completely equivalent with the original CO2 signal.It is supposed that wavelet coefficients are related to changes along a specific defined scale.The main idea of the signal trend detection is to perform an association of the scaling coefficients with the signal trend T(x), on the other hand the wavelet coefficients are supposed to be associated with the signal noise, which is mainly represented by the glitches, when processing the CO2 signal.In our analysis we consider an uncorrelated noise, adapting the wavelet estimator in order to works as a kernel estimator.Advantage of such approach is formulating an estimator based on the sampled data irregularity.In this method, we are using the scaling coefficients as estimators of the signal trend.We suppose that the sampled CO2 observations are represented by ( ), thus the CO2 estimator is given by the formulation (4): Integration is done over a set of the intervals ( ( )), their union forms perform partitioning interval covering all the observations , where ∈ .Consequently, is defined as: In this expression ( ) represents the scaling function.This function is defined as follows: The wavelet function is defined by the equation: The first crucial task is an appropriate selection of the mother's wavelet for the predicted CO2 signals filtration.Supposing the Daubechies wavelets can well reflect morphological structure therefore, this family is used for our model.Particularly, in our approach we are using the Daubechies wavelet (Db6), with the D6 scaling function utilizing the orthogonal Daubechies coefficients.

Validation ratings used
In order to carry out the objective comparison, the following parameters are considered: Mean Absolute Error (MAE) represents estimator measuring of difference between two continuous variables.The MAE is given by the following expression: Mean squared error (MSE) represents estimator measuring the average of the error squares between two signals.The MSE represents a risk function which corresponds with the expected value of the squared or quadratic error loss.The MSE is given by the following expression: Euclidean distance (ED) represents an ordinary straight-line distance between two points lying in the Euclidean space.Based on this distance, the Euclidean space becomes a metric space.The lower Euclidean distance we achieve, the more similar are two signal samples.In our analysis we consider mean of the ED.The Euclidean distance is given by the following expression: City Block distance (CB) represents a distance between two signals , in the space with the Cartesian coordinate system.This parameter can be interpreted as a sum of the lengths of the projections of the line segments between the points onto the coordinate axes.CB distance is defined as follows:  The practical implementation and ANN learning process together with the verification of the ANN BRM learned on the test data is carried out in the following steps: Step 1. Measurement of non-electrical variables Ti, T0, rH a CO2 in the SHC room in interval from February 8 to February 15, 2015, from June 8 to June 15, 2015, using operating sensors in a selected SHC room 204 (BACnet technology sensors, Desigo Insight SCADA system, PI System (Fig. 1)).
The actual experiments were carried out as follows:        where the configured number of neurons was 100 (Tab.5).

Third party -Testing and Quantitative Comparison (WT additive noise canceling)
In our research, we are analyzing signals representing the CO2 signals.We have a set of the estimated (predicted) signals being compared against the real measured signal CO2, which is perceived as a reference.In our analysis, we are comparing two samples of day course CO2 prediction and further two samples of week course CO2 prediction.Based on the observations, it is apparent that the predicted CO2 signals do not have a smooth process.They are frequently influenced by rapid oscillations, so-called glitches and also signal fluctuations (Fig. 12).Such signal variations represent the signal noise, impairing the real trend of the CO2 prediction, which should be reduced.In our analysis, we are using the wavelet filtration to eliminate such signals to obtain the signal trend for further processing.As we have already stated above, we are using the mother's wavelet Db6 for the   Based on the results, the wavelet filtration is capable of filtering rapid signal changes, whilst preserving the signal trend.In order to justify this situation, we report selected situations showing the glitches deteriorating a smooth signal trend, and a respective wavelet approximation largely reducing such signal parts (Fig. 14, 15, 16).As it is obvious, the CO2 signal contains lots of significant occurrences represented by the glitches and spikes, significantly deteriorating a smoothness of the analyzed signal.Wavelet appears to be a reliable alternative for reduction such signal's parts.On the other hand, we are aware that trend detection, in some cases, reduces the peaks thus, the original signal's amplitude is reduced, such situations are reported on Fig. 15 and 16.
In the last part of our analysis, the objective comparison is carried out.As we have already stated,   The ANN used RBF model with various number of neurons (10,50,100,150,200,250,300,350,400), (Tab.9 -Tab.12).In order to verify the results, it is necessary to cross-validate the models.In the other words using two different set of data for training and validating.In the first case of crossvalidation, period of 8. similar linear correlation has significantly lower MAE and MSE.Therefore, it had been selected as the best result for this implementation.The Figure 21 shows that for every rise on the reference signal, the predicted signal rises as well, which could provide an indication of human activity with appropriate filtering.Overall, this validation indicates a poor result.trained using this period of time hold lower accuracy in predictions.In the case of cross-validation, the difference is even more significant (Fig. 22).For the last cross-validation, the data from 8.6.2015 was chosen as training period and data from 8.2.2015 for cross-validation.Table 12 shows that except for order of measurement number 9 all other measurement represent very poor result.The prediction result from the measurement number 9 may significantly increase by appropriate filtering method (see figure 24).

Discussion
As it is obvious, the predicted CO2 signals contain lots of significant occurrences represented by February.In the cross-validation of cross-validation of 15.2.2015 with 16.2.2015, it provided a very accurate result.This improvement of the result is caused by the similarity of the relationship between the data from these two days, therefore, a significant reduction of quality will appear in case of choosing different data form different times of the year.This case was examined in the last crossvalidation case for a day from June for training and day from February for validation, which resulted from invalid results for this measurement.By comparing the results from cross-validations performed with measurement 1, it can be observed that for periods of times that share similar conditions and smaller size of data, it performs the best but in other cases, the accuracy significantly drops.This is also could a good indication of overfitting which results in a bad generalization.Other measurements also share similar conditions with measurement number 1 but with more significant inconsistency in the results.

Conclusions
The article describes visualization of the operational and technical functions in Smart Home Care using the PI Process Book software tool.In the context of ADL monitoring in the individual rooms, a method for predicting the CO2 course from the measured temperature and humidity courses using ANN BRM with signal trend detection based on WT for additive noise cancellation from the predicted signal was introduced and verified.
In the first part of the article were used and processed information from operationally measured non-electrical quantities determining the indoor environment in the SHC using operational technological units for the determination of the ADL in a real-world SHC environment for obtain an overview of the ADL of individual rooms of the SHC (time of arrival, time of departure), the indirect measurement of CO2 concentration (ppm) with operational CO2 (ppm) sensors was used.
In the second part of the article were used ANN BRM structures to predict the measured quantities for the purpose of monitoring the ADL in a real-world SHC environment.There was described the process of using the multilayer forward ANN to predict the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior of the SHC in the selected room R204 and from the outdoor temperature readings To (°C), with the gradient algorithm of error backpropagation using the BRM prediction.For the classification of prediction quality, a correlation analysis (R), calculated MSE, ED, CB were used.
In the third part of the article were made verifications and comparisons of WT additive noise cancelation in ANN BRM prediction of the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior of the SHC in the selected room R204 and from the outdoor temperature readings To (°C).For the classification of prediction quality with WT additive noise cancelation, a correlation analysis (R), calculated MSE, ED, CB were used.Based on the results, the WT is capable of filtering rapid signal changes, whilst preserving the signal trend.
In the fourth part of the article were ANN RBF structures to predict the measured quantities for the purpose of monitoring the ADL in a real-world SHC environment using of SPSS IBM SW Tool within IoT platform implementation to predict the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior of the SHC in the selected room R204 and from the outdoor temperature readings To (°C) with the ANN RBF structure.For the classification of prediction quality, a correlation analysis (R), calculated MSE and MAE were used.
The IBM SPSSS Modeler provides a strong software tool for predictive analytics that includes many predictive models.By observing the result from all cross-validations performed, it is clear that the ANN RBF model used in IBM SPSS Modeler has a poor generalization.In future works with IBM SPSS within IoT, the results form varies types of decision trees will be examined and compared.
Additionally, different predictive models can be implemented using IoT IBM Watson analytics, which can provide online analytics with possibilities of near real-time data streaming.

Preprints
(www.preprints.org)| NOT PEER-REVIEWED | Posted: 3 December 2018 CO2 prediction method using ANN BRM with the Wavelet Transformation filter algorithm to remove additive noise from the predicted CO2 course.The aim of the first part of the article is the use and processing of information from operationally measured non-electrical quantities determining the indoor environment in the SHC using operational technological units for the determination of the ADL in a real-world SHC environment.To obtain an overview of the ADL of individual rooms of the SHC (time of arrival, time of departure), the indirect measurement of CO2 concentration (ppm) with operational CO2 (ppm) sensors is used.The aim of the second part of the article is to use ANN BRM to predict the measured quantities for the purpose of monitoring the ADL in a real-world SHC environment.It describes the process of using the multilayer forward ANN to predict the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior of the SHC in the selected room R204 and from the outdoor temperature readings To (°C), with the gradient algorithm of error backpropagation using the Bayesian Regulation Algorithm (BRA) prediction.For the classification of prediction quality, a correlation analysis (correlation coefficient R), calculated MSE (Mean Squared Error), Euclidean distance (ED), City Block distance (CB) are used.The aim of the third part of the article is verification and comparison of WT additive noise cancelation in ANN BRM prediction of the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior of the SHC in the selected room R204 and from the outdoor temperature readings To (°C).For the classification of prediction quality with WT additive noise cancelation, a correlation analysis (correlation coefficient R), calculated MSE (Mean Squared Error), Euclidean distance (ED), City Block distance (CB) are used.

Figure 1 .
Figure 1.A block diagram of data transfer from the PI OPC interface to the PI Server and PI ProcessBook.

Figure 2 .
Figure 2. The main visualization screen in SW tool PI ProcessBook.

Preprints 227 Figure 3 .
Figure 3.A screen for room 204 with a detailed description of individual technologies and individual charts in SW tool PI ProcessBook.

Figure 4 .
Figure 4. Simplified block scheme of utilized technology in SHC with prediction of CO2.

Figure 5 .
Figure 5.The architecture of the designed ANN.
[41].The radial basis function (RBF) network is a feed-forward network that requires supervised learning.Unlike multilayer perceptron's (MLP), this network consists of only one hidden layer.Overall, there are three layers in the RBF network, IBM SPSS algorithm guide describes mathematical models of these layers[42]  as following: Input layer: = , : , … , : with : = RBF layer: , , : , … : ; with : = ∅ ( ) Preprints (www.preprints.org)| NOT PEER-REVIEWED | Posted: Input vector I: Number of layers (for RBM = 2) Ji: Number of units in layer i ∅ ( ( ) ): jth unit for input ( ) , = 1, … , .µj: Center of ∅ σj: Width of ∅ : : Unit j of layer i : weight connecting r th output unit and j th hidden unit of RBF layer The training of RBF can be divided in two stages.The first stage, determines the basis function by clustering methods and the second stage determines the weights given to the basis function.The SPSS measures the accuracy of neural networks by calculating the percentage of the records for which the predicted value matches the observed value.For the continues values the accuracy is calculated by 1 minus the average of the absolute values of the predicted values minus the observed values over the maximum predicted value minus the minimum predicted value (the following formula) [43].Accuracy = ∑ (

) 4 .
Correlation coefficient (R) measures a level of the linear dependency between two signals.The more are considered signals linearly dependable, the higher correlation coefficient is.In a comparison with the previous parameters, the correlation coefficient represents a normative parameter.Zero correlation stands for the total dissimilarity between two signals, measured in a sense of their linear dependency.Contrarily, 1, respectively -1 stands for the full positive, respectively negative correlation.Preprints (www.preprints.org)| NOT PEER-REVIEWED | Posted: 3 December 2018 As we have already stated above, in our work we are analyzing samples of day courses and week courses CO2 prediction.In each measurement, we have a prediction from the neural network with 10, 50, 100, 150, 200, 250, 300, 350, 400, 450 and 500 neurons.Thus, we completely analyze 11 predicted signals for each measurement.These signals are compared against the reference, based on the evaluation parameters stated above.In a term of the Euclidean, City Block distance and MSE lower values indicate a higher agreement between the predicted course CO2 and reference measurement course CO2 thus, better result.Contrarily, a higher number of correlation coefficients indicates better results.In the following part of the analysis, we report the results of the quantification comparison.All the tests are done for the Wavelet Db6, with 6-level of decomposition and the Wavelet settings: threshold selection rule -Stein's Unbiased Risk and soft thresholding for selection of the detailed coefficients.The experimental practical part 4.1.First Part ADL information from CO2 concentration course This section contains the description of the experiments performed, the setting of the individual parameters, the calculated and measured results.In the first long-term experiment CO2 (ppm) concentration indoor, temperature T(°C) indoor, temperature T(°C) outdoor and relative humidity rH(%) indoor measurement were performed in a spring month, from June 8 to June 15, 2015.The measured course of CO2 concentration in Figure 6 indicates the occurrence of persons in the monitored area in SHC room 204 (Fig.3).

Figure 8a illustrates theFigure 8a .
Figure 8a illustrates the reference measured course of CO2 concentration from February 8 to February 15, 2015, and the predicted course of CO2 concentration using the ANN BRM learned (Step 5a) on the data (from June 8 to June 15, 2015) and predicted within the cross-validation (Step 4a), (with the data from February 8 to February 15, 2015) using the ANN BRM (number of neurons 50), (Tab.1).The red circles indicate the predicted CO2 values that were incorrectly calculated within the prediction error using the ANN BRM. Figure 8b illustrates the reference measured course of CO2 concentration from February 8 to February 15, 2015.Figure 8b further illustrates the predicted filtered course of CO2 concentration using the WT (the ANN BRM learned on the data (from June 8 to June 15, 2015) and predicted within the cross-validation (Step 4a) with the data from February 8 to February 15, 2015, using the ANN BRM (the number of neurons -50), (Tab.2)).

Figure 8b .
Figure 8b.The reference (measured course of CO2 concentration (from February 8 to February 15, 2015)) and predicted filtered course of CO2 concentration using the WT (the ANN BRM learned on the data (from June 8 to June 15, 2015) and predicted within the cross-validation with the data from February 1 to February 28, 2015, using the ANN BRM (the number of neurons -50), (Tab.2).

Figure 9a illustrates the
Figure 9a illustrates the reference measured course of CO2 concentration from June 8 to June 15, 2015, and the predicted course of CO2 concentration using the ANN BRM learned on the data (from February 8 to February 15, 2015) and predicted within the cross-validation (with the data from June 8 to June 15, 2015) using the ANN BRM (number of neurons 100), (Tab.3).

Figure 9 .Figure 9 .
Figure 9. a) The reference measured course of CO2 concentration from June 8 to June 15, 2015, and the predicted course of CO2 concentration using the ANN BRM learned on the data (from February 8 to February 15, 2015) and predicted within the cross-validation (with the data from June 8 to June 15, 2015) using the ANN BRM (number of neurons 100), (Tab.3)

Figure 9b illustrates the 4 . 2 . 3 .
Figure 9b illustrates the reference measured course of CO2 concentration from June 8 to June 15, 2015, and the predicted filtered course of CO2 concentration using the WT (the ANN BRM learned on the data from February 8 to February 15, 2015) and predicted within the cross-validation (with the data from June 8 to June 15, 2015) using the ANN BRM (number of neurons 450), (Tab.4).

Figure 10a illustrates theFigure 10a .
Figure 10a illustrates the reference measured course of CO2 concentration from February 8, 2015, and the predicted course of CO2 concentration using the ANN BRM learned (Step 4c) on the data (from June, 2015) and predicted within the cross-validation (Step 4c), (with the data from February 8, 2015) using the ANN BRM (number of neurons 450), (Tab.5).The red circles indicate the predicted CO2 values that were incorrectly calculated within the prediction error using the ANN BRM.

Figure 10b .
Figure 10b.The reference (measured course of CO2 concentration (from February 8, 2015)) and the predicted course of CO2 concentration with WT.(The ANN BRM learned (from June 8, 2015), the predicted ANN with the data from February 8, 2015 -the number of neurons -450, (Tab.6).

Figure 10b illustrates the
Figure 10b illustrates the reference measured course of CO2 concentration from February 8, 2015.

Figure 10b further illustrates
Figure 10b further illustrates the predicted filtered course of CO2 concentration using the WT filtration (the ANN BRM learned on the data (from June 8, 2015) and predicted within the crossvalidation (Step 4c) with the data from February 8, 2015, using the ANN BRM (the number of neurons -450), (Tab.6)).

Figure 9a illustrates the
Figure 9a illustrates the reference measured course of CO2 concentration from June 8 to June 15, 2015, and the predicted course of CO2 concentration using the ANN BRM learned on the data (from February 8 to February 15, 2015) and predicted within the cross-validation (with the data from June 8 to June 15, 2015) using the ANN BRM (number of neurons 100), (Tab.3).

FigureFigure 11 . 8 )
Figure 9b illustrates the reference measured course of CO2 concentration from June 8 to June 15, 2015, and the predicted filtered course of CO2 concentration using the WT (the ANN BRM learned on the data from February 8 to February 15, 2015) and predicted within the cross-validation (with the data from June 8 to June 15, 2015) using the ANN BRM (number of neurons 450), (Tab.4).

CO2
signal trend detection.Firstly, take advantage of the fact that different level of the decomposition allows perceiving more or less the signal details represented by the detailed coefficients.Since we need to perceive the signal trend by eliminating the steep fluctuations, we need to consider an appropriate level of the decomposition.An experimental comparison of individual wavelet settings is reported in Figure 12.Based on the experimental results, we are using 6-level decomposition for the CO2 signal trend detection.The filtration procedure utilizes the further following settings: threshold selection rule -Stein's Unbiased Risk and soft thresholding for selection of the detailed Preprints (www.preprints.org)| NOT PEER-REVIEWED | Posted: 3 December 2018 coefficients.

Figure 13 .Figure 14 .
Figure 13.Example of two samples one-day prediction of CO2 signal.Filtration is done by using the Db6 wavelet with 6-level decomposition), (ANN BRM trained with data (8.6.2015),cross validation prediction with data (8.2.2015)).

Figure 16 .
Figure 16.Day prediction of the CO2 signal containing several glitches and signal spikes, marked as black RoI, (ANN BRM trained with data (8.6.2015),cross validation prediction with data (8.2.2015)).

4. 4 .
Fourth part -practical implementation prediction of CO2 using ANN RBF IBM SPSS (IoT) SW ToolFor practical implementation of ANN RBF to predict the measured quantities for the purpose of monitoring the ADL in a real-world SHC environment was selected SPSS IBM SW Tool within IoT platform implementation.To predict the course of CO2 concentration from the measured temperature Ti (°C), relative humidity rH (%) in the interior in the selected SHC room R204 and from the outdoor temperature readings To (°C), with the ANN Radial Basis Function (RBF) network, which is a feedforward network that requires supervised learning.For the classification of prediction quality, a correlation analysis (correlation coefficient R), calculated MSE (Mean Squared Error) and Mean Absolute Error (MAE) were used.A data type selection operator was used to set default target to CO2 and default inputs (in this case inputs were used as predictors) to humidity, indoor temperature and outdoor temperature.The transformed data were fed to a neural network for training a ANN model.The developed stream using IBM SPSS is shown in the Figure 17.
the glitches and spikes, significantly deteriorating a smoothness of the analyzed signals.Such steep fluctuations may have significant impact on the CO2 accuracy.Wavelet appears to be a reliable alternative for reduction such signal's parts.On the other hand we are aware that trend detection, in some cases, reduce the peaks thus, the original signal's amplitude is reduced, such situations are reported on the Fig.15and 16.In our work, we have studied the Daubechies wavelet family.This wavelets, as it is known, are able to well reflect morphological structure of the signals.We are particularly using Db6 wavelet for the trend detection.In the last part of our analysis, the objective comparison is carried out.As we have already stated, we are comparing originally measured CO2 signals with predicted signals being filtered out by the wavelets.In order to carry out the objective comparison, the following parameters are considered: when considering the MSE, we are getting better results for the wavelet trend detection.It means that we have minimized the difference between the gold standard and filtered signals.The correlation coefficient gives higher values for the predicted CO2 signals.Anyway, we have achieved just slight differences.The reason might be caused by the fact that the trend detection largely omits higher peaks, therefore, the linear dependence for wavelet filtration is smaller, when compared with the predicted signals.Generally speaking, using the Wavelet filtration lead to more accurate results against the predicted signals, and signals are much more smoothed, not containing steep fluctuations.On the other hand we are aware a certain loss of the amplitude.Therefore, in the future time it would be worth investigating the frequency features of the CO2 signals in order to objectively determine frequency modifications while filtering by the wavelets.By reviewing the results from measurement performed using radial basis function networks developed in IBM SPSS modeler, it can be observed that however, the measurement number 1 showed the poorest accuracy in initial training, it provided the most accurate result for case of crossvalidation of 8.6.2015 to 14.6.2015with 15.2.2015 to 21.2.2015 which could lead to possible human activity recognition with proper filtering technique.By swapping the training and validation periods the prediction accuracy significantly the dropped.This drop was a direct result of the lower quality of training data due to the smaller amount of abnormities caused by the presence of humans during Preprints (www.preprints.org)| NOT PEER-REVIEWED | Posted: 3 December 2018 (www.preprints.org)| NOT PEER-REVIEWED | Posted: 3 December 2018

preprints.org) | NOT PEER-REVIEWED | Posted: 3 December 2018 the
training when the generalization stopped improving.Testing -15%, 173 samples, which have no effect on the training and, therefore, they provide an independent measure of the network performance during and after the training.The prediction of CO2 concentration using the ANN BRM was implemented by, firstly, using the measured values of rH (%) indoors, temperature indoors Tin (°C), temperature outdoors Tout (°C) on the cross-validation (Step 4a) used the training data (rH (%) indoors, temperature indoors Tin (°C), temperature outdoors Tout (°C)) that was measured from February 8 to February 15, 2015.Table1shows the calculated values of R and MSE parameters for the number of neurons (10 to 500) set within the testing of the ANN BRM (from June 8 to June 15, 2015) for predicting (Step 6a) the course of CO2 using the ANN BRM without WT on the data measured in the interval from February 8 to February 15, 2015.The best calculated minimum value of MSE parameter (MSE = 0.002) and maximum value of R correlation coefficient (R = 0.839), for predicted courses of CO2 are for trained ANN BRM with 50 neurons (Cross Validation).Table 2 shows the calculated values of R and MSE parameters for the number of neurons (10 to 500) set within the testing of the ANN BRM (from June 8 to June 15, 2015) for predicting (Step 6a) the course of CO2 using the ANN BRM with WT (step 4) on the data measured in the interval from February 8 to February 15, 2015.The best calculated minimum value of MSE parameter (MSE = 0.0019) and Training ANN, BRM (Step 4a) for neuron counts in an interval of 10-500, measuring the time t(s) of learning, the MSE calculation, and the correlation coefficient R for data from June 8 to June 15, 2015, (Tab.1).The total number of samples was 1152.Training -70%, 806 samples, which are presented to the network during the training, and the network is adjusted according to its error).Validation -15%, 173 samples, which were used to measure the network generalization, and to halt Preprints (www.maximumvalue of R correlation coefficient (R = 0.854), for predicted courses of CO2 are for trained ANN BRM with 50 neurons (Cross Validation).

Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 3 December 2018 4
.2.2.The long-term experiment -8 days.Training the ANN BRM was implemented on the data (from February 8 to February 15, 2015), (Tab.3,Tab.4).Training ANN, BRM (Step 4b) for neuron counts in an interval of 10-500, measuring the time t(s) of learning, the MSE calculation, and the correlation coefficient R for the data from February 8 to WT using the ANN BRM was implemented by the cross-validation (Step 5b) used the training data (rH (%) indoors, temperature indoors Tin (°C), temperature outdoors Tout (°C)) that was measured from June 8 to June 15, 2015, (Tab.4).The minimum value of MSE parameter is MSE = 0.0024 and maximum value of correlation coefficient R = 0.957 were calculated for ANN BRM where the configured number of neurons was 450 (Tab.4).

Table 5 .
Comparison of prediction quality ANN (BRM) [8.6.2015], with the Cross validation tested data from the interval 1 day [8.2.2015].

Table 6
shows the calculated values of R and MSE parameters for the number of neurons (10 to 500) set within the testing of the ANN BRM with WT (from June 8 2015) for predicting (Step 5c) the course of CO2 using the ANN BRM with WT on the data measured in the interval from February 8, 2015.The best calculated minimum MSE parameter (MSE = 0.0024) and maximum R correlation coefficient (R = 0.957), (Table6) for predicted courses of CO2 (Fig.10b) are for trained ANN BRM with 450 neurons (Cross Validation).

Table 6 .
Comparison of prediction quality ANN (BRM) [8.6.2015], with the WT noise cancelling of Cross validation tested data from the interval [8.2.2015].

Table 7 .
Comparison of prediction quality ANN (BRM) [8.2.2015], with the Cross validation tested data from the interval 1 day [8.6.2015].

Table 8 .
Comparison of prediction quality ANN (BRM) [8.2.2015], with the WT noise cancelling of Cross validation tested data from the interval [8.6.2015].

Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 3 December 2018
6.2015 to 14.6.2015was used for training of the neural networks and period of 15.2.2015 to 21.2.2015 was used for cross validation.From Table 9, it can be observed that the measurement number 4 holds the highest linear correlation, but the measurement number 1 with

Table 9 .
Trained ANN RBF model with data 8.6.2015 to 14.6.2015,within cross-validation with data (15.2.2015 to 21.2.2015).

Table 10
represents the ANN RBF model trained with data from 15.2.2015 to 21.2.2015 and crossvalidated with data from 8.6.2015 to 14.6.2015.It was shown in trainings stage, the models that are
Figure 22.Order of measurement number 2 (Tab.10),trainedANNRBFmodel with data 8.2.2015 to 14.2.2015, within cross-validation with data (15.6.2015 to 21.6.2015).A third cross-validation was performed by using 15.2.2015 as training data and 16.2.2015forvalidation.These periods of times share similar conditions and smaller data size, therefore an improvement in cross-validation results were expected and achieved.The table14indicates that similar to the first implementation, the measurement number 1 holds the best results in terms of linear correlation, mean absolute error and mean square error.Additionally, almost identical (with minor glitches) reference values and predicted values can be observed from Figure23.