1 Introduction and necessity of the work

Cognitive impairment because of Alzheimer's disorder and different types of dementia impacts the patient's capacity to keep up daily living exercises by day living (ADL). Impeded ADL work is also the primary determination behind the expanded requirement for healthcare consideration or standardization. ADL alludes to self-care assignments, including exercises performed every day that an individual wish to perform independently. Cognitive impairment has life-threatening ramifications on the patient's autonomy and quality of life. ADL is characterized in two clusters; those including center assignments of regular daily existence, for example, eating, dressing, and washing, named as essential ADL, and those including convoluted higher-level task, as well as usage and interaction with instruments, for example, planning suppers, overseeing funds and utilizing the phone, named as Instrumental ADL (IADL) [1,2,3].

To live protected and individualistically at home, an individual needs to consistently perform ADL from the two gatherings and self-sufficiently. Even though both fundamental ADL and IADL are imperative for protected and independent living, fitness in IADL is an essential criterion for living autonomously in the community-dwelling arrangement [4]. The present research article uses ADL, for the most part, to allude to both the cluster. ADLs are critical indicators of personal satisfaction and are surveyed by clinicians to benchmark patients' physical and subjective capacities, decide care needs, distinguish hazards in everyday living, screen sickness movement, or the impact of hostile to dementia treatment. Generally, ADL is surveyed utilizing self-evaluated patient polls or witness-based polls [5] by directly perceiving the patient while completing an undertaking. Undertaking perceptions are tedious and inclined to exchange mistakes from the laboratory to the real world. A drawback of polls lies in their dependence on abstract evaluations of members or relatives and, consequently, subject to inclination and mistakes connected to intellectual weakness or absence of knowledge into hindrances. Additionally, several patients live alone and are supported for a couple of hours weekly; it is hard to get a consistent and exhaustive clinical image of the patient's ADL status [3, 6]. Sensor-based advancements for measuring ADL can add new measurements to existing clinical evaluation.

With the application of regular ADLs monitoring, it can help in preceding ailment and hazard recognition. Additionally, it reduces hospital admission by modifying care to the patient's requirements and bringing down the expenditure of therapeutic consideration. Such sensor-based acknowledgment frameworks refer to assistive technology for drawing out autonomous living in one's own home. The essential parts of sensor-based acknowledgment frameworks are the sensors that gather the patient's indoor environment information [2]. In contrast, wireless technology and IoT are in charge of exchanging gathered information to the receptor unit and the central processing unit with necessary information translation and investigation calculations. Perceiving ADL in-home settings utilizing sensor frameworks has been very much announced in writing, grouping them into five primary sorts of monitoring advancements: passive infrared movement sensors (PIR), body-mounted sensors, force sensors, video observing, and multi-component sensors. Of these, encompassing sensor frameworks and body-mounted frameworks are broadly revealed for perceiving ADL. Simultaneously, just a couple of studies have attempted to consolidate information from both or different sensors. Encompassing sensors, for example, PIR sensors, are sensitive to body-radiated infrared light and identify the nearness of occupants in rooms, therefore permitting acknowledgment of trends in the day-by-day movement [2,3,4].

In contrast, body-mounted sensors frameworks can quantify action and versatility, specifically on the patient's body. A few creators propose that the ease of use and acknowledgment of surrounding sensors is better contrasted with body-mounted frameworks since patients do not directly contact the sensors. The utilization of sensor-based estimation creates much information, which requires acknowledgment strategies to deduce an action. ADL detection from ambient information is customarily done utilizing training datasets or early learning-based methodologies, for example, probabilistic based, rule based, Naïve Bayes, K-Means grouping, and Random Forest [6]. Another general way to deal with action acknowledgment is to plan and utilize machine learning techniques to outline sensor occasions' succession to compare movement names [7].

Smart home innovation gives a broad scope of well-being services, particularly for the older and individuals with incapacities. It gives personal satisfaction benefits through what is known as ADLs pattern generation and trend forecasting—perceiving an occupant's exercises for creating AAL services by anticipating inhabitants' practices and behavior. This is attained by ADL modeling utilizing a training dataset of the indoor home environment [8,9,10,11]. A contest encountered in this field is the capability of such frameworks to transfer DSOH models to HSOH. For example, a smart home's conventional organization requires sensor data acquisition, data mining-handling, and the design of a behavioral pattern recognition model for every activity. From a logical and economic point, developing new homes for AAL system deployment is costly and disappointing, as most elderly subjects live in their existing homes. For the present research, the wireless sensor networks are deployed in the elderly subjects' existing houses.

2 Related work

ADL recognition, the way toward anticipating the home's inhabitants' action through the succession of activities they perform. ADL has pulled in numerous analysts keen on creating strategies and methods to upgrade the procedure's accuracy and create general models appropriate for various conditions and settings. Building the models has been founded on numerous methodologies, including the Naive Bayes classifier, support vector machine (SVM), hidden Markov model (HMM), Conditional Random Field (CRF), and K-nearest neighbor [3, 11,12,13,14]. Different endeavors concentrated on extracting further semantic data from the ambient to advance the feature space, for example, pattern attributes and privacy attributes. Past research has concentrated on the data acquisition strategies, annotations, and how to segment the data stream that is received from the sensing units to model significant activities with clear distinguishers for the sub-activities performed for every activity.

In [2], the author proposed a system that plans to characterize a flag for every action. The action flag is an impression of the reflection of activities performed for every movement. Action recognition faces a primary issue in the presence of blemishes in the sensory datasets and is dimensioned by the labeled datasets' accessibility for model building. This issue has been tended for all three supervised, semi-supervised, and unsupervised models in [3] by accepting a similar circulation for the labeled and unlabeled datasets. However, these procedures did not address the diversity standing between the HSOH and the DSOH. Moreover, it neglects to confirm its unwavering quality and deliver invariant dissemination of data models.

In this unique situation, transfer learning, as a technique for enhancing the learning procedure for one area utilizing the information gained from various areas, has been enormously utilized for ADL recognition. Transfer learning [15] enables the exchange between ambient with diverse areas, allocations, and objectives. Transfer learning systems for ADL recognition have been differing, as indicated by the source and target situations' setting. In [16, 17], the authors accepted divergences in the activity’s timestamp between the source and target datasets, while in [7, 12], the researchers expected differences in conducting the activities individual's habits. As a procedure for transfer learning, feature mapping has been generally utilized for activity discovery in smart homes that used heterogeneous ambient sensing units [13, 15, 17]. The method depends on mapping the objective space's attributes onto the source space's attributes or the other way around. The mapping is also performed by fitting both the source and the objective spaces into a typical feature space [15, 18].

The primary feature space, also known as meta-feature space, is presented and structured dependent on the data accessible about the two areas. The features of the sources and target areas are mapped into the meta-feature space. As displayed in [19, 20], the procedure begins with source annotated data from which the action formats are recovered. The activity layouts show that timestamp, location, and context. The equivalent is performed for the target home; the unlabeled datasets and data mining methods create activity layouts. The subsequent stage is to outline source action formats onto the target formats. With the ongoing advances in cloud design, smart homes dependent on distributed computing are presently appropriate for execution [12]. There are several existing transfer learning-based dementia research uses focused on medical image processing, not the unobtrusive ambient assistive sensor technology that we are proposing in SAMEDR [21,22,23,24,25,26,27].

The majority of smart aging home arrangements are laboratory or the controlled trial setup. Additionally, these existing smart home systems aim to monitor the ADL; they did not emphasize cognitive impairment and correlation with the risk of potential illness [12,13,14,15]. The primary issue is the inadequate dataset for training the model for cognitive impairment recognition and prediction. Transfer learning is the method toward learning a mapping (display) between source spaces and objective circumstances, where just a little or NO labeled training datasets presently exist [28,29,30]. Annotating home movements is a fundamental undertaking for modeling the ADL. In the present work, transfer learning has been linked to actuate modeling parameters of target ambient. This research plans to exchange information from trained models into a domain with absenteeism of prepared ones. The present research paper discovers the issue of exchanging an ADL recognition model from a source DSOH into an objective one HSOH to develop healthcare data services to the objective ambient environment. Our concept expresses that if the system has metadata depicting the objective space, the system can alter source models to a customized model for the objective indoor ambient. So, the pledge of this work is to recommend a practice that underpins our theory. Our proposed philosophy depends on breaking down the source area's attributes for planning them into a standard shape. The following stage includes proposing a solution for determination varieties in data distribution since source homes have distinctive sensors' conveyances as designated by their plan. Such dispersal results in data dissimilarity that should be settled before associating chosen attributes in the feature mapping stage between the source and the target domain. Accordingly, the preferred features are exploited to build up a classification model based on the target home's metadata. The proposed research philosophy's significance is its capacity to profit from the metadata to transfer a source model into a target model.

Current work utilized unobtrusive heterogeneous wireless sensors networks (WSN) to capture the indoor movements and interactions with household objects in the daily routine from twelve DSOH and twenty HSOH age-matched elderly individuals. Home setups and living laboratories use a controlled environment with healthy living subjects. Simultaneously, the present research scope is committed to conducting trials with moderate to severe dementia patients living alone in their existing premises. Implicit color ambulatograms view the recognized ADLs for the collective measurement period to obtain activity maps. The present research used a recurrence plot to quantify ADLs modeling performance. Moreover, it quantitatively categorizes and distinguishes the ADL.

3 ADL model transfer framework

This segment demonstrates the investigation for bringing models at DSOH using models generated at HSOH. We determine to achieve the optimum accuracy of produced datasets. Additionally, the produced datasets must characterize the DSOH setting so that zero ambiguity happens with its native metadata. The proposed model starts with the metadata feature selection and analysis (MFSA) [31]. MFSA has the accountability to conduct meta-feature space analysis for straddling the source datasets. This straddling is done in such a way so that datasets consider the diversity in feature spaces among various sources of the data.

Moreover, the later phase research study applies dimensionality reduction as there are several cohesive features from various sources. Overlapping and grouping of related features are done to shorten the feature lengths. These reduced features are then applied for divergence analysis among source and target. They were followed by feature mapping to produce novel feature space that could be supplied to HSOH ambient. The target domain characteristics further influence this recently received novel feature space to consider all modalities of the target. Finally, activity recognition and anomaly forecasting models have been utilized for ADL monitoring-based preventive healthcare. We use our previously designed Wellness Sensors Network protocol for sensor deployment, data collection, and ADL recognition [31,32,33].

System stretches out the fundamental calculation to build the number of turns between the source and target by considering the Jensen–Shannon disparity (JSD) between the annotation distributions recorded over the areas. The current work additionally talks about the outcomes of the tests on HSOH. The proposed system incorporates into our correlation of cutting-edge calculations heterogeneous feature augmentation (HFA) [18, 34] a proposed methodology as of late. Moreover, the research study explores whether re-preparing in the source/target area is beneficial over reusing the source model (Sect. 3.1). Aside from related work area, results, and discourse segment, the other remarkable commitments incorporate learning an increasingly robust mapping by using the conditions between the target features (Sect. 3.2) and measuring the designed mapping (Sect. 3.3).

3.1 Wellness metadata feature selection and analysis:

This approach is based on the selection of critical features locally inside the feature space of each class. Let \(M\) is the set of models, \(= \left\{ { m_{1} , m_{2} , \ldots \ldots .. m_{n} } \right\}\), so each given model is presented by feature space with the associated environment

$$m_{i} = FX_{E } .$$
(1)

The activity set \(A = \left\{ { A_{1} , A_{2} , \ldots \ldots .. A_{K} } \right\}\) of K activity classes and the set of feature \(F = \left\{ { F_{1} , F_{2} , \ldots \ldots .. F_{JK} } \right\}\) represents the parameters of activities of AAL environment \(E\). The environment \(E\) is represented by,\(E = \left\{ { E_{1} , E_{2} , \ldots \ldots .. E_{e} } \right\}\). Each activity class \(A_{K}\) contains \(J\) activity instances, \(I = \left\{ { I_{1K} , I_{2K} , \ldots \ldots .. I_{JK} } \right\}\). Activities instances \(I_{JK}\) are observed by sensors \(= \left\{ { S_{1} , S_{2} , \ldots \ldots .. S_{L} } \right\}\), \(I_{JK} { }\) is defined by features set \(F_{JK }\) of \(L\) sensors,

$$F_{JK} = { }\left\{ {{ }\mathop \sum \limits_{l = 1}^{L} F_{JK}^{l} { }} \right\}$$
(2)

The experimental deployment sensing units have similar design characteristics and configurations for activity recognition, so they have more or less the same feature space linked to each of them. There are slightly fewer chances of getting different feature spaces of a sensor used for similar purposes in more than one smart home, though present MFSA considers these distinctive spaces.

In the current smart home deployment approach, all the sensors installed at a different home and premises locations have the same manufacturer, configuration, specification, and produces the same formats of data. However, when the system imports data from a third-party smart home and apply previously designed models, it fails. So it is MFSA, which consolidated datasets and transformed into an understandable format of different frameworks. The number of features in the feature space is proportional to the deployed sensing units. Characterizing conceptual and significant data at an abstract and high level of data processing and learning encourages settling this issue.

Mining meta-feature space (MFS) of features from the given training data is the fundamental commitment of this examination. The customary procedure of separating MFS is focused on area specialists to label them or utilizing a philosophy to characterize at an abstract level. The present framework is targeting self-MFS mining with a characterized hypothesis. On the other hand, cosmology requires field information that is not accessible to different smart home environments.

Sensing unit characterization is the best way to understand and unify one sensor unit's feature space deployed in two different home environments. For example, in one smart home, they have listed all activities as kitchen activities. In contrast, in another one, they differentiate between dishwashing activity (as both are implemented in the kitchen). By sensing unit characterization proposed work links that sensor to particular localization and activity usage. Usually, the feature that appears the most number of times in \(A_{K}\) is considered a key feature. The feature contains the information on the frequency of sensor unit activation frequency for the inactivity of a sensor unit (which corresponds to a particular sub-activity) \(F_{JK}^{l} = 1.\) So the feature value is better presented by \(0 \le F_{JK}^{l} \le 1\). The feature set \(F_{JK} {\text{ for I}}_{JK }\) instances is shown by,

$$F_{JK} = { }\left\{ {\mathop \sum \limits_{l = 1}^{L} F_{JK}^{l} } \right\} = \left\{ {\mathop \sum \limits_{l = 1}^{L} \frac{{F_{JK}^{l} - {\text{ S}}^{{\text{l}}} }}{{{\text{S}}^{{\text{l}}} - {\text{ s}}^{{\text{l}}} }}} \right\}{ }$$
(3)

where \({\text{S}}^{{\text{l}}} = { }\) maximum value of \(F_{JK}\) for all instances noted by \({\text{ l}}^{{{\text{th}}}}\) sensor in K activity classes.

\({\text{s}}^{{\text{l}}} = { }\) Minimum value of \(F_{JK}\) for all instances noted by \({\text{ l}}^{{{\text{th}}}}\) sensor in K activity classes.

Let us assume \(ID_{K}\) is a set of identification numbers of the defined features. At time \(t = 0, ID_{K} = \emptyset { }\left( {{\text{empty}}} \right).\) To locate key features, research checks the occurrence of activity events, which have nonzero values for the \({\text{ l}}^{{{\text{th}}}}\) feature.

$$\propto_{K}^{l} = F_{JK} = \left\{ {\mathop \sum \limits_{l = 1}^{L} F_{JK}^{l} } \right\} > 0 \ge \mu_{user}$$
(4)

where \({ } \propto = { }\) frequency of occurrence of feature in the instances of \(A_{K}\).

\({\upmu } = { }\) The minimum number of event instances to calculate key features in that environment (it may vary from one smart home to another).

Each key feature of \(A_{K}\) is allotted to a defined weight value \(W_{aK}^{l}\). \(W_{aK}^{l}\) is a set of values that shows the weight of key features linked to the sensor \(S_{L}\) appears in the activity set \(A_{K}\) such that,

$$W_{aK}^{l} = { }\frac{1}{{\left| {ID_{K} } \right|}}$$
(5)

The weight value of one feature can be changed when its activity class changes. Moreover, it also depends on the number of key features in that activity class. Finally,

$$F_{JK}^{l} = \left\{ {F_{JK}^{l} \times W_{aK}^{l} ,\quad if\;l \in ID_{K} ,0} \right\}$$
(6)

Else, Eq. (6) updates the features set, for instance\(, I_{JK} { }\), which generates features space for ADL detection. The characterization of sensor and defining the profile ease the job, so the sensor profiling is represented by,

$$C_{S} = { }\left\{ {{\text{d}},{\text{ g}},{ }F_{JK}^{{\text{r}}} } \right\}$$
(7)

where \({\text{d }}\) is the dimensionality of the sensor \(S_{L}\).

g \({\text{is }}\) a group to which sensor \(S_{L}\) is associated in order to record key features space of activity as well as sub-activity linked to sensor profile, and the proposed system needs to know the common section of their events given by,

$$S_{KT} = \left( {S.C_{S} } \right) \pi \left( {S.A_{KT} } \right)$$
(8)

where \(A_{KT} { }\) is the activity class set of target environment \(HSOH.\)

3.2 Wellness feature mapping algorithm (WFMA):

The essential objective of any heterogeneous transformation learning approach is to connect the contrasts between the areas by utilizing those under concern. The errand of summing up common data point features over two areas with various modalities like text and pictures may not be helpful for exchange among heterogeneous component spaces. Our novel arrangement of the wellness feature mapping algorithm connects the heterogeneous element spaces by utilizing the common label data between the source and target areas. The proposed calculation decides the mapping between source and target features depending on the gauge of features' commitment to making information segmentations with comparative label dispersions. A visual portrayal of the calculation is delineated in Fig. 1 [34]. There are three stages in the proposed calculation. The first step decides the information segments with comparative label circulations over the spaces; the next step records the commitment of features toward producing a data partition and classification. The final step includes the measurement of transformation from the learned features.

Fig. 1
figure 1

source domain to target domain [34]

Feature mapping from the

The feature transfer issue is practically tested by the inaccessibility of correspondences between the source and target spaces' information purposes. If sufficient correspondences are accessible, one can become familiar with a mapping Z ∈ RdSC× dT by limiting the transformation error as appeared in Eq. (9). Here, æ is the regularization parameter, and η is the number of correspondences.

Let \(\left\{ {\left. {X_{sc, } Y_{sc } } \right\}_{b = 1}^{p} } \right.\), and \(\left\{ {\left. {X_{T, } Y_{T} } \right\}_{C = 1}^{q} } \right.\) show the set of annotated instances I in the source domain \(sc\) and target domain \(T\), where \(p \gg q\). \(X_{sc} \in R^{{d_{sc} }}\) is a source data point of corresponding class annotation \(X_{sc} \in Y\). Same as, \(X_{T}\) \(\in R^{{d_{T} }}\) is a target data point of associated class annotation \(X_{T}\) \(\in Y\). The key features of data points are from multiple sensor modalities and \(d_{sc} \ne d_{T} ,\) to guarantee transfer between heterogeneous feature spaces of two domains; features must be related and share common label space. The number of standard labels is given as \(v\). The ultimate aim is to understand and generate a mapping across source domain to target domain as follows:

$$T = ~\min \frac{1}{n}~ + \left\| {X_{T} - X_{S} Z_{S} } \right\|_{2}^{2} + ~\left\| {Z_{S} } \right\|_{2}^{2}$$
(9)

In uncontrolled heterogeneous domain adaptation (HAD) situations, these common feature space correspondences are missing. As an outcome, some common data between the spaces that can be utilized to connect them should be identified. Our methodology does not assume any intersecting feature or area-related data that can be explored to connect the domain-specific features. Though the proposed calculation depends on a common annotation label space between the HSOH and DSOH areas, they have a standard set of labels. Our feature mapping approach explores the most significant shared space to create relating feature vectors for the two spaces. In the least complicated situation, each common name is a rotate. Suppose the quantity of standard labels between the areas is small. In that case, recognizing shared features becomes problematic as the system needs a sufficient number of cross-area data points. The proposed novel feature transformation algorithm defeats this impediment by depending on normally happening label distributions in the intricate label space rather than individual labels. The mutual label dispersions are the axis that connects the HSOH and DSOH. Since the quantity of common labels over the areas is finite, the system extricates information partitions over the areas that show comparable labeling annotation dissemination. The HSOH feature and DSOH feature's assessed commitment toward a common label circulation are considered cross-space shared data elements.

The following stage in the calculation processes the weight relationship matrices WHSOH and WDSOH between the area-dependent features and the mutual transmissions in the DSOH and HSOH spaces individually. This strategy supports feature guarantees for the accumulated vectors. Because of the shortage of label information in the HSOH space and a modest number of common labels, the system has just a couple of indistinguishable labeling conveyances over the areas. In this way, the research study likewise considers comparative label circulations to lift transfer learning, where the comparability of two name disseminations is processed utilizing Jensen Shannon divergence (JSD) [5, 18, 35, 36].

Our goal is to recognize each HSOH feature as a linear distribution of a small DSOH feature arrangement. So the target project matrix for the mapping is given by PHSOH

$$p_{{HSOH}} = ~\min ~p_{{HSOH}} \frac{1}{{U_{L} }}\left\| {\mathop \sum \limits_{{j = 1}}^{{U_{L} }} W_{{HSOH}} - W_{{DSOH}} P_{{DSOH}} } \right\|~ + \mathop \sum \limits_{i}^{{d_{T} }} ~\left\| {P_{{DSOH_{i} }} } \right\|_{1}$$
(10)

There must be an evaluation of the wellness feature mapping algorithm, how accurately it mapped the features of DSOH to the HSOH. It is better given by deviation of actually measured mapping (11) to ideal modeled mapping (12):

Actual mapping,

$$P_{A} \in R^{{d_{{HSOH \times d_{DSOH } }} }}$$
(11)
$$P_{Ideal} \in R^{{d_{{HSOH \times d_{DSOH } }} }}$$
(12)
$$Evaluation\,parameter = (E_{{para~}} ) = \frac{1}{{2~ \times ~d_{{DSOH~~}} }}\mathop \sum \limits_{{i = 1}}^{{d_{{DSOH~~}} }} \mathop \sum \limits_{{k = 1}}^{{d_{{DSOH~~}} }} \left\| {W_{{HSOH}} - W_{{DSOH}} } \right\|\begin{array}{*{20}c} 2 \\ 2 \\ \end{array}$$
(13)

3.3 Modeling ADL activity recognition learning, mapping, and transferring

Our proposed approach of activity detection is based on separate classifiers for \(HSOH\) and \(DSOH\). Let us assume that \(d\) dataset depicts \(A\) activity set if the AAL. The above-defined \(A = \left\{ {A_{1} , A_{2} , A_{3} , A_{4} , \ldots . A_{k} } \right\}.\) these activities are formed by sensor activations, so the sub-activity is given by \(\varphi = \left\{ {\varphi_{1} , \varphi_{2} , \varphi_{3} , \varphi_{4} , \ldots . \varphi_{u} } \right\}. u > k.\) The system needs to find co-relation between to be modeled set of activities of \(DSOH\) and be tested activities of \(HSOH\). Each activity of \(DSOH\) is processed to recognize its relation with \(HSOH\). For activity recognition, the system used a previously defined wellness model to build the relationship research deep learning model. The deep learning model recognizes whether the particular activity is transformed into the \(HSOH\) or discarded. This depends on the performance of the learning parameters of the transfer learning model.

The best solution is to implement a probabilistic model on the data received from the transfer learning model. So at the time instance, t, the transfer learning belief figure (\(F_{{\begin{array}{*{20}c} t \\ \\ \end{array} }}\)) is defined by the distance (\(D_{{\begin{array}{*{20}c} t \\ \\ \end{array} }}\)) between the modeled value (\(M_{{\begin{array}{*{20}c} t \\ \\ \end{array} }}\)) to the calculated practical value (\(C_{{\begin{array}{*{20}c} t \\ \\ \end{array} }}\)) on the standard deviation (\(\sigma\)) and the confidence level (\(0.95).\)

$$\mathop {M_{t} = \frac{1}{N} \cdot \sum }\limits_{n = 0}^{N} m\left( t \right)$$
(14)
$$F_{{\begin{array}{*{20}c} t \\ \\ \end{array} }} = { }\frac{\sigma }{{\left| {D_{{\begin{array}{*{20}c} t \\ \\ \end{array} }} } \right|}}$$
(15)

When Dt > σ

$$F_{t} = 0.99 when F_{t} \le \sigma$$
(16)

4 Results and experimental analysis

To investigate the transfer learning system's proposed approach, the current research study selected five HSOH datasets, of which four were not annotated, and one was fully annotated, as shown in Table 1. Our evaluation approach is based on the offered transfer learning methodology of activities labeling from source DSOH domain to target HSOH domain.

Table 1 Description of datasets collected from the DSOH and HSOH

4.1 a. Accuracy of mapped features between HSOH and DSOH age-matched control

To measure the accuracy of the proposed WFMA approach, the datasets are grouped into three categories, group one with four DSOH datasets completely labeled, group two with only one HSOH datasets completely labeled, and group three with 4 HSOH datasets not labeled. Table 2 shows the accuracy of the mapped feature space in brief. This arrangement aims to record the performance of target annotation figures based on transformation by a labeled source. The labeled datasets were processed to mine the features and evidence for each event or activity. This evidence is the pattern of sensor activations that are essential to produce a single activity or sub-activity. Once the set of evidence from the labeled datasets is received, the system starts scanning the unlabeled datasets, searching for likelihood. As the likelihood of evidence sequence is matched, the particular portion of the target dataset is allotted an annotation, which is similar to the source-labeled dataset. To calculate the similarity between HSOH and DSOH proposed system features, Mahalanobis distance [5, 20], the distance value tells about fractional matching, no-matching, thorough matching, and complete matching.

Table 2 Accuracy of transferred and mapped features between

The total accuracy in all four datasets of the target is significant, though, in H5 and H6, it is below the confidence level of 95%.

4.2 b. Performance comparison with transfer learning classifier

The sub-section evaluates the mapped feature space performance according to transfer learning classifiers. As HSOH takes over the classification merits from DSOH, there should not be a substantial statistical difference in the performance. This classification in the target is done twice, first with native (N) HSOH datasets without transfer learning evidence from source DSOH datasets and second with the transfer learning (TL) datasets; this dataset is based on source-inherited sensor triggering evidence of sequence which defines an activity.

The majority of the TL models performed exceptionally well for the training datasets of HSOH and DSOH. Even in current research using MobileNet, the proposed system secured AUC 1 under the testing dataset. However, it was below 0.62 for the real-world new dataset, as shown in Tables 3 and 4. When these existing AI models are applied to real-world new datasets, they fail to repeat the performance. Existing TL models tested under collected HSOH and DSOH datasets. Their AUC was below 0.62. It displays overfitting and high variance, which misguides the researchers instead of assisting in recognizing early dementia signs and cognitive impairment. Why are our models crashing for the new dataset during the real-world application? This is a vital question! That we need to understand and address.

Table 3 Performance metrics for deep learning models under the training datasets of DSOH and HSOH
Table 4 Performance metrics for deep learning models under the real-world datasets of DSOH and HSOH

The best arrangement is to utilize more training data to prevent overfitting, which is complicated with the ADL household age and environment dataset. As the deployment of sensors into the home environment is followed by the collection of data of at least one year (which completes all seasons of the year), so the accessibility of data is limited. The pre-trained model prepared on more information will generally sum up better; otherwise, the best arrangement is to utilize regularization strategies. Sometimes limitations on the amount and sort of data any model can store. On the off chance that a system can just bear to remember a few patterns, the advancement procedure will drive it to concentrate on the most noticeable patterns from the features, which have a superior possibility of generalizing well. The most straightforward approach to prevent overfitting in the present case was to decrease the size of the deep learning algorithms, for example, the number of learnable parameters in the model (which is controlled by the number of layers and the number of units per layer). Offered research tried that as well, but the performance did not improve considerably. In deep learning, the number of learnable parameters in a model is frequently alluded to as the model's "capacity." Instinctively, a model with more parameters will have more "memorization capability," and along these lines will have the option to effectively become familiar with an ideal word reference like mapping between training samples and their objectives, a mapping with no generalization power. However, this would be pointless when making forecasts on previously unseen data [7, 13, 17]. Mostly deep learning models will, in general, be acceptable at fitting to the training data, yet the genuine test is a generalization, not fitting. So to see the generalization, we brought a new real-world dataset for the testing. If the system has restricted memorization assets, it would not have the option to learn the mapping without difficulty. To limit its misfortune, it should learn packed portrayals that have increasingly predictive power. Simultaneously, on the off chance that you make your model excessively little, it will experience issues fitting to the training dataset. There is a trade-off between "too much capacity" and "not enough capacity" [36]. Tragically, there is no mystical equation to decide the model's correct size or design (regarding the number of layers or the correct size for each layer). It would be best if the researcher tried utilizing the progression of various structures. The only solution was to design a new integrated machine learning-based approach which can learn and generalize with inadequate training data (Table 5).

Table 5 Performance of HSOH datasets under two different classifier with and without transfer learning

Additionally, overfitting occurred in the existing pre-trained network implementation. A model learned the feature and noise in the training data to the extent that it negatively influenced the deep learning pre-trained model's performance on a new dataset (real-world dataset). This explained that the noise or random variations in the training data were elected and learned as the model's features. The difficulty was that those features did not become applicable to the new dataset and deleteriously influenced the pre-trained network's aptitude to generalize. The feature extraction methods need to apply, which explores the textures for the feature extraction and discards the error noise. There was an immediate need to bring a new TL approach to get stable and better performance. After the performing deep learning task, we found the pre-trained transfer learning models had better performance than the proposed SAMEDR model under training and controlled training, whereas, during real-world new datasets used, pre-trained networks showed a significant decrease.

Following abbreviation used in below table, specificity (SP), F1 score (F1), Mathews correlation coefficient (MC), N normal without transfer learning (N), with the transfer learning (TL), average (Avg), and improvement with transfer learning feature space inheritance (IM). The below table represents the results of classification under classifier CNN and LSTM. The research found a significant difference in these two models' performance, both with and without transfer learning feature space. LSTM performs better in the majority of household datasets. The average parameter improvement in LSTM as compared to CNN is Avg.SP (5%), AvgF1 (4%), and Avg.MC (9%). The projected SAMEDR TL model performs decently well during controlled testing to a real-world new dataset with a slight decrease in performance.

4.3 c. Analytical observations of ADL for dementia patients and healthy age-matched control

The divergence of ADL trends between HSOH and DSOH age-matched control is shown below. The categorization procedure identified ADL in both the subject groups. These activity maps give the graphical representation of daily routine and the user-friendly annotation of performance over different activities in age-matched elderly subjects. The frequency of occurrence of activities is slightly different in DSOH homes as compared to HSOH. In contrast, the total number of recognized ADLs did not vary much from one group to another. A significant difference is found in the ADL schedule, and consistency exhibited a discrepancy, as seen in Fig. 2 of an HSOH and Fig. 3 of a DSOH. Figures 2 and 3 illustrate a contrast of the activity map of an HSOH for the test period of 24 h-30 days. The activity map spots the significant intervals of action and inactivity and historical occurrences of the activities. On computing, the inconsistency in ADL acts over 30 days, a substantial divergence in accomplishing the majority of the ADL (Sleeping, Shower, Cooking, Dishwashing, Toileting, Grooming) was found between HSOH and DSOH subjects as shown. The heterogeneousness in the ADL functioning of the DSOH patients was more significant than the HSOH for all ADL. The wellness feature mapping attributes from DSOH to early cognitive impairment subject offer a significant indication of the risk of dementia.

Fig. 2
figure 2

Activity map of an individual HSOH

Fig. 3
figure 3

Activity map of an individual DSOH

5 Discussion

Cognitive impairment scores can influence intellectual stimulation on ADL. However, intellectual stimulation can be measured as a vital characteristic of perspective understanding of ADL. The present research suggests a method uniting mutually physical and functional health calculated by integrating various ADL performance examinations to explore how cognitive class influences these sense modalities and facilitates improved ambient-assisted living-based preventive healthcare. The persons with dementia (PwD) have complications with many activities but have not understood and recognized their impairment. People with no reasoning deficiency can do activities.

The key impact is that we put forward a set of helpful features utilized to a strengthening system that can assist doctors who do not know the elder’s latest ADL trends to instantly screen subjects under test to measure the probability of having dementia. The proposed system requires subjects to carry out certain ADLs in a smart home ecosystem installed with Wellness Sensors Networks. Then, the system produces sensors, activations, and unearth features. The features and assessed results for every activity are supplied into a deep learning algorithm to categorize elders with dementia and elders without dementia. The average specificity (SP) 0.93, F1 score (F1) 0.93, Mathews correlation coefficient (MC) 0.88. It demonstrates that our recommended instant testing system gets valuable features through sensor activations received from deployed wellness sensors networks. The benefits of the proposed system are: (1) these features are valuable and uncomplicated to be attained, (2) it simply needs the sufficient interval of time to diagnose an elder, and (3) it is straightforward to use for researchers, and there would be user score for the medical professionals use. The present system does not consider the medical professionals' feedback as it has limited user trials; in the next stage, we are recording the doctor's input to improve it. The research findings in this study are encouraging, and our constant current attempt at engaging more applicants may help reinforce all the data analytics and inferences. The research would examine the possibility of offering a context-aware decision-making system that would help in scenarios such as the individual with dementia forget to use the toilet flush or grooming to remind the individual according to their ADL trends.

The planned and implemented system is an alternative methodology to past research on preventive healthcare monitoring systems established to observe cognitive deterioration. We were applying the sensor data relating to DSOH and HSOH subjects. Some of the HSOH, which transitioned to mild cognitive impairment throughout the monitoring period, research revealed that the ADLs could be modeled to extract the feature required for transfer learning. Throughout this approach, SAMEDR revealed and mined trends of activity specific to every single subject. This feature is exceptionally challenging to apply to other functions where several predefined procedures are used. This responded to our initial research issue. To measure any analytical variances between DSOH of activity connect to HSOH subjects when cognitively undamaged and when the changeover to mild cognitive impairment (MCI) or when undergoing MCI, the research used a hypothetical data method and applied deep learning to establish statistical variances between the ADL DSOH to HSOH matching to the diverse conditions of reasoning. Lastly, by utilizing an uncomplicated thresholding tactic of arcs of standardized divergences, the system was proficient in distinguishing MCI in elderlies. The proposed SAMEDR system overtook the attitude that the system implemented through pre-trained transfer learning models. Several predefined procedures correlated with the HSOH and DSOH activity were used to distinguish MCI.

6 Future work and limitation

The research is subject matter to a few constraints. Foremost, it measured elementary ADL connected with own care, such as cooking, body hygiene, and dishwashing. This characterizes the more fundamental proficiencies required for being autonomously but did not consider all IADLs, such as managing the bank account and paying the monthly bills, as they will be assessed in a separate arrangement more significant project. Though IADL performance also faded in the early phases and provided the distinct scales of ADL impact on quality of life, the impact of IADLs dictates added examination [21]. Second, caregiver and care provider ratings were acquired from both relative and care professionals in some of the cases of DSOH [22]. The person with dementia (PwD) can still be rehabilitated in executing ADL using structured learning and audio-assisted coaching. The forthcoming investigation should explore whether the efficacy of assisted coaching is contingent on the individual patient or particular task attributes.

7 Conclusion

This article presented a transfer learning approach based on Wellness Sensors Network’ sensor activations, in which the procedure has been established corresponding to the feature learning from DSOH to HSOH for MCI recognition. This research aims to deliver an efficient approach of transmitting data-statistics models between different DSOH to HSOH while maintaining satisfactory implementation. The research work uses the data features of source DSOH, which is rich in MCI labels, whereas the target domain HSOH ecosystems are deficient in training datasets of cognitive impairment. The recommended procedure was concentrating on producing junctions between features for the objective of employing sensor data fusion. Eventually, SAMEDR formed the target HSOH activities using designed data analysis models with CNN, LSTM to modify HSOH models. Offered research foresees that the likely target domain will be highly distinct in users' ADL trends, sensing units, and transmission methods. The most complex task in activity learning is to acknowledge new events in the target domain. In this case, we recorded the performance of the pre-trained transfer learning network, which showed overfitting. Therefore, we support a new transfer learning framework, SAMEDR, to understand and identify recent target domain events.

The SAMEDR system systematically details the prerequisites evocation, strategy, and assessment of a designed preventive healthcare model to MCI. The model was structured to meet every day and only the requirements of the dementia subject and their close one. Findings of assessing the model demonstrate that it is competent to fulfill the drawn requests, not including complex interfaces from consumers. For example, to accurately determine familiarity and make-up choices, the SAMEDR needs to obtain a set of exceptional knowledge about the subject under test. The present research study did not be dependent on the caregivers to furnish the evidence. A deep learning model with designed transfer learning statistical methods is applied to uncover and fine-tune the knowledge by treating the ADLs. SAMEDR for early MCI recognition is precisely evaluated from both operationality and serviceability standpoints equally. The proposed research study's methodology introduces initial, innovative expertise to recognize the early sign of dementia, MCI, and disorder progress at the premises. Applying the data collected from sensors can correctly characterize the home environment's movement and interaction with household objects in the home and people's routine behaviors to distinguish when an anomaly happens. This innovative methodology enables recognizing precise ADLs in practices that have certainly not been achievable in the past without encountering substantial expenditures or overburdening the patient's cognitive requirements.

Consequently, the scheme adds substantially to the AAL-based preventive healthcare. In the USA and UK, the impacts of exponentially raising the elderly population are challenging to cope with. Subsequently, a range of questions for well-being and community care suppliers have been launched.