# Privacy-Preserved In-Cabin Monitoring System for Autonomous Vehicles

Authors: Ashutosh Mishra; Jaekwang Cha; Shiho Kim
Journal: Computational Intelligence and Neuroscience
 (2022)

---

## Abstract

Fully autonomous vehicles (FAVs) lack monitoring inside the cabin. Therefore, an in-cabin monitoring system (IMS) is required for surveilling people causing irregular or abnormal situations. However, monitoring in the public domain allows disclosure of an individual’s face, which goes against privacy preservation. Furthermore, there is a contrary demand for privacy in the IMS of AVs. Therefore, an intelligent IMS must simultaneously satisfy the contrary requirements of personal privacy protection and person identification during abnormal situations. In this study, we proposed a privacy-preserved IMS, which can reidentify anonymized virtual individual faces in an abnormal situation. This IMS includes a step for extracting facial features, which is accomplished by the edge device (onboard unit) of the AV. This device anonymizes an individual’s facial identity before transmitting the video frames to a data server. We created different abnormal scenarios in the vehicle cabin. Further, we reidentified the involved person by using the anonymized virtual face and the reserved feature vectors extracted from the suspected individual. Overall, the proposed approach preserves personal privacy while maintaining security in surveillance systems, such as for in-cabin monitoring of FAVs.


---

## Body

## 1. Introduction

Intelligent monitoring and surveillance systems are widely used to ensure safety and security. Popular applications of monitoring in public are video surveillance cameras (closed-circuit television); monitoring in intelligent transportation systems, including in-cabin monitoring and road traffic monitoring; and video monitoring for data generation and navigational tasks around city centers, airports, and public roads [1]. Driving automation also requires public visual information for multiple tasks [2]. The Society of Automotive Engineers defined six levels of autonomy in driving automation in 2014 (from no automation (level 0) to full automation (level 5)) [2–4]. Level 4 autonomous vehicles (AVs) are highly automated and capable of performing all driving tasks under certain conditions without human intervention. However, the driver (human) may control such AVs as and when required. In particular, fully autonomous vehicles (FAVs) (level 5 AVs) have no drivers; all occupants are passengers only [3, 4]. Therefore, no one oversees such AVs. In addition, in public and shared vehicles (such as ridesharing, carsharing, and car-full services in AVs), the passengers do not know each other. Therefore, it is important to ensure the security and safety of all occupants sitting in the cabin of such AVs. Furthermore, the vehicle should be protected from any malicious behavior of the occupants and/or external threats. Therefore, FAVs essentially require a multipronged in-cabin monitoring task in real time [5]. However, many countries have imposed a ban or severe restrictions on facial recognition techniques to secure personal information [6–16]. There are legal and ethical issues that impose various restrictions on public monitoring and surveillance systems [16–19]. Furthermore, identification of the accused is also important in abnormal (irregular) situations. This study was motivated by the fact that facial monitoring is important for safety; however, it poses a threat to individual privacy. In this study, we focused on the following two problems associated with in-cabin monitoring systems (IMSes):(i)
Protection of facial privacy.(ii)
Evidence of the accused in abnormal situations.Therefore, a robust solution is required to provide privacy-preserved monitoring in public [20]. Moreover, it should be capable of identifying the concerned person when required. Figure 1 shows the dilemma of intelligent monitoring systems.Figure 1
System overview of the proposed IMS. (a) Few examples causing abnormal situations in the cabin of a vehicle. (b) The dilemma of the legal and ethical issues (privacy) and practical problems (requirement of monitoring). Case 1: the masked face has no facial information, which is crucial in surveillance and monitoring inside the cabin of a vehicle. Case 2: real face suffers from personal privacy threats. Case 3: facial anonymization solves the problem of privacy; however, it has the problem of identifying the concerned person in case of irregular situations.As illustrated in the above figure, an anonymous face protects personal information during in-cabin monitoring of an FAV. However, in certain irregular situations, personal identity is required to identify the accused person. An example of an abnormal incident or irregular situation can be an occupant of the FAV acting violently or attempting vandalism against the other occupants or toward the FAV itself. In such cases, it is important to identify the concerned person. Furthermore, this is an abnormal situation; however, in-cabin monitoring with real faces is not a solution to this problem. The breach of facial information leads to multiple consequences, such as misuse of facial data and banking and financial fraud [1, 6, 7, 13, 14]. One of our motivations for this work was to provide an approach that can protect against such problems in public monitoring systems, particularly the IMS. In-cabin monitoring with facial anonymization has security issues, while those with facial identity have privacy issues. Therefore, it creates a contradiction between privacy and security.


### 1.1. In-Cabin Monitoring

In-cabin monitoring is important in level 4 and beyond AVs [5]. It provides safety and security to the occupants. Simultaneously, it provides safety to the vehicle itself in an irregular situation. Past research works include in-cabin monitoring in various situations [21]. In-cabin monitoring for violence detection inside a FAV was reviewed in [22]. Bell et al. performed in-cabin monitoring to detect harsh vehicle maneuvers and risky driving behaviors [23]. Szawarski et al. patented the idea of in-cabin monitoring for a monitoring vehicle seat, occupants inside a vehicle, and the orientation of both the occupants and the vehicle seat [24]. Safety and cleaning problems of in-cabin monitoring of a vehicle were presented in [25]. However, a monitoring system should protect against any breach of personal privacy (facial identity) with the simultaneous ability to identify an actual person in case of irregular situations.


### 1.2. Facial Privacy versus Facial Recognition in Monitoring Applications

Real-time monitoring is essential in multiple monitoring applications. However, privacy in the public domain is an important concern in real-time monitoring tasks [26–30]. Facial anonymization is a common practice for preserving personal privacy. Recently, generative adversarial network- (GAN-) based deep learning (DL) models have been widely used for face swapping and anonymization [31–34]. In our previous study [31], we demonstrated a robust approach to preserving the facial identity of the occupants in a FAV cabin. It incorporated the facial swapping and reenactment technique to maintain privacy in in-cabin monitoring. However, in ab abnormal situation, the anonymized face of the occupants made it difficult to identify the concerned person [20].


### 1.3. Our Key Research Highlights

In this study, we propose an intelligent IMS. It is an efficient approach for identifying a person, even with an anonymized face. This method resolves both privacy and security issues. Accordingly, we can identify the person who causes an irregular situation, even with their anonymized face. In this approach, we preserved the key facial information of the occupants and stored these identity features on the cloud. These key features help in recognition of the person involved in the irregular situation. The highlights of this study are as follows:(i)
The concept of having an appropriate source face for each target face enhances puppeteering and reenactment of facial emotion and behavior. It helps in event and behavior detection in intelligent monitoring and surveillance systems in the public domain.(ii)
The involvement of the two-dimensional (2D) landmark position in the reenactment generator and separate segmentations of face and hair in the segmentation generator with inpainting and blending generators enhances the facial anonymization and reenactment operations.(iii)
The 128D identity feature is a key marker for accurate facial identification in an anonymized domain. The concept of storing a pair of IDs (original and anonymized) leads to reidentification without any privacy threat. It is not possible to know the original face with only 128D identity features. For reidentification, both the original visual input and the ID are required. In the cloud, the anonymized visual image with the originalID is stored. Therefore, there is no threat of privacy breach, even though the IDs are stored in the cloud.(iv)
Therefore, the proposed approach augments the facial identity feature information to locate the involved person in any abnormal situation without any personal privacy breach.This approach pioneers a newer method of monitoring and surveillance to avoid any legal or ethical issues. Therefore, a monitoring database can be created in the anonymized domain, thereby facilitating further research on events and behavior monitoring in the public domain.


## 1.1. In-Cabin Monitoring

In-cabin monitoring is important in level 4 and beyond AVs [5]. It provides safety and security to the occupants. Simultaneously, it provides safety to the vehicle itself in an irregular situation. Past research works include in-cabin monitoring in various situations [21]. In-cabin monitoring for violence detection inside a FAV was reviewed in [22]. Bell et al. performed in-cabin monitoring to detect harsh vehicle maneuvers and risky driving behaviors [23]. Szawarski et al. patented the idea of in-cabin monitoring for a monitoring vehicle seat, occupants inside a vehicle, and the orientation of both the occupants and the vehicle seat [24]. Safety and cleaning problems of in-cabin monitoring of a vehicle were presented in [25]. However, a monitoring system should protect against any breach of personal privacy (facial identity) with the simultaneous ability to identify an actual person in case of irregular situations.


## 1.2. Facial Privacy versus Facial Recognition in Monitoring Applications

Real-time monitoring is essential in multiple monitoring applications. However, privacy in the public domain is an important concern in real-time monitoring tasks [26–30]. Facial anonymization is a common practice for preserving personal privacy. Recently, generative adversarial network- (GAN-) based deep learning (DL) models have been widely used for face swapping and anonymization [31–34]. In our previous study [31], we demonstrated a robust approach to preserving the facial identity of the occupants in a FAV cabin. It incorporated the facial swapping and reenactment technique to maintain privacy in in-cabin monitoring. However, in ab abnormal situation, the anonymized face of the occupants made it difficult to identify the concerned person [20].


## 1.3. Our Key Research Highlights

In this study, we propose an intelligent IMS. It is an efficient approach for identifying a person, even with an anonymized face. This method resolves both privacy and security issues. Accordingly, we can identify the person who causes an irregular situation, even with their anonymized face. In this approach, we preserved the key facial information of the occupants and stored these identity features on the cloud. These key features help in recognition of the person involved in the irregular situation. The highlights of this study are as follows:(i)
The concept of having an appropriate source face for each target face enhances puppeteering and reenactment of facial emotion and behavior. It helps in event and behavior detection in intelligent monitoring and surveillance systems in the public domain.(ii)
The involvement of the two-dimensional (2D) landmark position in the reenactment generator and separate segmentations of face and hair in the segmentation generator with inpainting and blending generators enhances the facial anonymization and reenactment operations.(iii)
The 128D identity feature is a key marker for accurate facial identification in an anonymized domain. The concept of storing a pair of IDs (original and anonymized) leads to reidentification without any privacy threat. It is not possible to know the original face with only 128D identity features. For reidentification, both the original visual input and the ID are required. In the cloud, the anonymized visual image with the originalID is stored. Therefore, there is no threat of privacy breach, even though the IDs are stored in the cloud.(iv)
Therefore, the proposed approach augments the facial identity feature information to locate the involved person in any abnormal situation without any personal privacy breach.This approach pioneers a newer method of monitoring and surveillance to avoid any legal or ethical issues. Therefore, a monitoring database can be created in the anonymized domain, thereby facilitating further research on events and behavior monitoring in the public domain.


## 2. Materials and Methods

Personal privacy with identification is a challenge as well as a demand in real-time monitoring applications [20]. In this study, we developed a privacy-preserved IMS with the reidentification capability that can identify the accused person. The framework of the proposed method is shown in Figure 2. The proposed system operates in three stages. In stage 1, facial anonymization was performed to ensure personal privacy. It was performed using the onboard device of the AV. In stage 2, a pair of identity features (IDs) was generated for each face before and after anonymization (IDR and IDA). Further, the anonymized video along with the IDs was fed to the cloud. The pairs of IDs were kept in the cloud for person reidentification when required. The anonymized video frames were sent to the data center for further processing (monitoring and surveillance). In stage 3, the IDs were matched to search the accused (person involved in an irregular situation (IDA_AS)). During the investigation, the similarity between IDs ensured the identification of the concerned person (ID). Further, during the investigation, this approach was verified by matching the IDs of the suspect face (IDinv) at the time of investigation with the accused person’s ID.Figure 2
Proposed privacy-preserved intelligent IMS. Here, the identity features (IDs) are as follows: real face ID (IDR), anonymized face ID (IDA), ID of the occupant that caused an abnormal situation (IDA_AS), and suspect face ID during the investigation (IDinv).The dilemma between monitoring requirements and legal and ethical issues is also resolved through this approach. The details of the proposed approach are discussed thoroughly in Section2.2. This approach is suitable for creating a monitoring and surveillance database with legitimation.


### 2.1. Materials

Many research works have been published on personal privacy and person identification considering these two issues as separate research problems. In this study, we briefly surveyed the related works and developments on both face anonymization and person identification.


#### 2.1.1. Face Anonymization

Face deidentification preserves privacy-sensitive information. It alters the original face to hide privacy-sensitive information. Anonymization of faces is an easier and more robust solution to personal privacy-related threats in the digital domain [35]. Blurring, masking faces, or creating a patch over faces is slightly easier than any other face anonymization approach; however, those methods suffer from significant loss of facial information [32, 36]. Therefore, face swapping has attracted significant attention for facial anonymization purposes. The morphable model-based facial exchange approach is considered a pioneering work in face swapping [37]. Bitouk et al. demonstrated automatic face replacement in their work [38]. Machine-learning-based face swapping was suggested in [39]. A convolutional neural network (CNN) was used for face segmentation and swapping in [40]. GAN-based deep models have become popular for virtual human face generation [33, 34]. Therefore, along with autoencoders, GAN-based face swapping has gained considerable attention among researchers for seamless end-to-end face anonymization [33, 34, 41]. Face swapping-based automatic generation and editing of faces was showcased in [42]. It used a region-separative GAN (RSGAN). An autoencoder-based algorithm for face swapping was presented to detect fake videos [43]. In [44], a GAN-based encoder-decoder network was suggested to swap human faces. Collateral privacy issues have also been resolved using the face swapping method [45]. Nirkin et al. suggested a face swapping GAN (FSGAN) in [46]. It provided subject agnostic face swapping and reenactment between a pair of faces. Naruniec et al. presented a fully automatic neural face swapping method in [47]. Sun et al. proposed a hybrid model for face anonymization [36]. Hukkelas et al. introduced a GAN-based DeepPrivacy architecture for face deidentification to remove all privacy-sensitive information [34].


#### 2.1.2. Person Identification

Facial recognition has multipurpose objectives, such as recognition, classification, and discrimination. Urbanization and smart cities demand widespread applications for face recognition [48–52]. Therefore, various face recognition approaches involving person identification have been demonstrated by past researchers. Face recognition approaches are classified into three categories: local, holistic, and hybrid approaches [52]. Local approaches involve only partial facial features (such as eyes, mouth, and nose) to recognize a face, whereas holistic approaches involve complete facial features, including background for facial recognition. Hybrid approaches, as the name suggests, involve both local and holistic approaches. In holistic approaches, popular algorithms involve independent component analysis, linear discriminative analysis, and principal component analysis [53, 54]. The development of artificial intelligence (AI) incorporating DL and CNNs has boosted the performance of facial recognition algorithms. Taigman et al. presented a deep neural network-based face recognition system, DeepFace [55]. Furthermore, many other extended versions of DeepFace have been demonstrated in multiple studies [56–59]. Adjabi et al. thoroughly reviewed face recognition techniques and their comparisons and future scope in their study [51]. Kortli et al. surveyed popular face recognition techniques in all three categories, that is, local, holistic, and hybrid approaches, in their study [52]. They compared these techniques in terms of accuracy, complexity, and robustness. They also discussed the advantages and disadvantages of the respective approaches. Wang et al. efficiently surveyed DL-based face recognition techniques in their study [60]. They exhaustively reviewed various popular DL-based approaches, including autoencoder-based, CNN-based, and GAN-based techniques. They also enumerated the key features, advantages, and disadvantages of these techniques. Furthermore, they summarized some of the commonly used datasets for deep face recognition. Moreover, they indexed the emerging real-world issues and major technical key challenges in deep facial recognition.However, an application involving person identification must address important privacy concerns [61]. In particular, facial identification in the public domain must tackle individual freedom and ethics-related issues [51, 62]. Therefore, the state-of-the-art research problem in face recognition is the reidentification of an individual on anonymized data. Rocher et al. demonstrated the likelihood of correctly reidentifying a specific individual, even with the anonymized dataset [30]. They suggested a generative graphical model that can be trained on incomplete data to accurately identify individuals. Rooijen et al. suggested 2D video tracking for the reidentification of individuals in an anonymized dataset [20]. They suggested that the real facial information of a person is not necessary for reidentification. Luo et al. suggested effective training tricks for person reidentification [63]. A residual learning framework using the residual network (ResNet) model was suggested in [64] for visual recognition tasks. This facilitated the easier and more efficient training of a substantially deeper network. Schroff et al. suggested unified embedding using only 128 bytes per face for efficient face recognition [65]. They developed their network by incorporating the batch input layer and deep CNN, followed by normalization. They used triplet loss to minimize the training errors. The world’s simplest face recognition library (Dlib face recognition) is a popular and efficient tool for extracting facial landmarks [66]. It is a cross-platform open-source machine-learning toolkit that supports the development of machine-learning algorithms. It helps in recognizing and manipulating faces. Intent and behavior have been successfully detected using various techniques. Facial gesture sensing is performed using virtual reality (VR) and augmented reality (AR) devices, respectively in [67, 68]. AR/VR devices provide sensor responses to detect the intent or behavior of the user. However, FAV in-cabin monitoring requires intent or behavior detection using visual (computer vision (CV)-based) monitoring approaches.


### 2.2. Method

In this study, we proposed a representation learning-based approach to generate the identity signature of occupants. This signature is capable of deidentifying a person concerned with an irregular situation in the cabin of level 4 and beyond AVs. We proposed facial anonymization and reidentification system to provide countermeasures in case of an irregular situation. Therefore, this method provides personal information security with traces of the concerned person in case of any abnormality. The proposed method includes four main tasks. First, face anonymization with reenrollment. This is performed by using the face agnostic face swapping technique. It uses a set of GANs. These GANs are used for three purposes: facial reenactment and segmentation, facial inpainting, and facial blending. After accomplishing face anonymization, the second task is to extract the facial identity features of the occupant’s faces in pairs (before and after anonymization, i.e.,IDR and IDA) using the ResNet-based model. These IDs are stored in the cloud, and the anonymized video frames of in-cabin monitoring are transferred to the data center via the cloud for further processing. The third task of the proposed approach is to identify the accused by identity feature matching. Similarity matching of the ID of the accused obtained at the data center with the IDs of the occupants stored in the cloud ensures the identification of the concerned person (IDA). However, it is the ID of the anonymized face of the accused. The Euclidean distance metric was used for similarity matching. Similarly, using the stored pairs of IDs (IDR and IDA), we can obtain the real face identity feature of the accused (IDR). Finally, in the fourth task, the evidence of the accused is obtained by matching the similarities between the IDs of the suspects with the ID of the accused during an investigation. Further details of the proposed method are provided in the following sections.


#### 2.2.1. Facial Identity Feature Vector

The facial identity feature is (128, 1)-dimensional encoding of a facial image. It contains the encoded landmarks of the face using theResNet model. The FaceNet-based CNN model and Facedlib face recognition library are used to extract the 128D identity features (ID) from the faces. Additionally, 128D is optimal embedding, which results in appropriate features required for reidentification or measuring the similarity between two faces. It has already been validated in the “FaceNet” architecture that fewer than 128D identity features deteriorate the identification performance; however, increasing the dimension only unnecessarily increases the number of parameters. This is the main reason for adopting the 128D identity features for recognizing faces.Figure3 shows the (128, 1)-dimensional facial identity feature vector generation of the occupant’s face image. It uses a ResNet-based architecture consisting of 29 convolutional layers for this purpose. The ResNet architecture facilitates the dipper layer accessibility. Additionally, they have an inherent tendency to minimize the training error loss by increasing the number of layers. The triplet loss function is used to estimate the error in the reidentification of the concerned person. It performs similarity matching on the 128D identity features. For the anonymized anchor image ID (IA), positive anonymized image ID (IP), and negative anonymized image ID (IN), the triplet loss is estimated by the following equation:(1)ℒA,P,N=max‖IA,IP2‖−‖IA,IN‖2+margin,0.Figure 3
Illustration of 128D facial identity feature vector generation (from the occupant’s face image). Image shown is taken from our in-cabin monitoring database. The numerical values in the yellow, red, green, and blue colored boxes are representing respective passengers’ (128, 1)-dimensional facial identity feature vectors (ID).The anonymized anchor image ID (IA) represents the 128D ID of the person figured out in an irregular situation. The positive anonymized image (IA) is the stored image 128D ID of the same person on the cloud, and the negative anonymized image ID (IA) is the 128D ID of another occupant. Here, (‖x, y‖2) denotes the “Euclidean distance” between pairs {x, y} in the triplet loss function. A factor margin is included in equation (1) to reduce the chances of misclassification. These facial features are incorporated in 128D encoding and are used as the facial recognizer using only 128 bytes per face.Furthermore, a distance-based classifier compares the 128D features to identify the person involved in an irregular situation. It represents the difference between two feature vectors in Euclidean space. Suppose that image (R) represents the person. Image (C) is the stored image (copy) of the same person on the cloud, and image (D) is an image of another occupant. Further, ƒ(x) represents the 128D encoding of the image fx. The similarity (S) in the vector space is measured by the following equation:(2)S=min‖fR,fC‖2,‖fR,fD‖2.It guarantees that images (R) and (C) are of the same occupant and are different from image (D), which is the image of another occupant.


#### 2.2.2. Source Image Generation

A source image was required for face swapping in facial anonymization. It is used to replace the face appearing in the target image. This replacement, that is, swapping, should produce a realistic result that seamlessly reenacts the anonymized face that is similar to the target face. Our recommendation is to use a nonreal face as the source image. It mitigates any chaos/conflicts that may occur by using any real face as the source image. Therefore, in our proposed method, we used GAN-generated virtual human faces as the source image. We have considered generating appropriate source faces that can effectively render the original emotions or behaviors performed by the occupants. It helps in further event and behavior-monitoring tasks. Figure4 shows the proposed source image generation process. We applied the concept of similarity matching in vector space to select a similar source face for each target face from the set of virtual human faces (nonreal face as the source image). Similarity matching between source and target faces facilitates reciprocating similar emotions and intents, which is necessary for further monitoring applications.Figure 4
Source image generation using AI-generated faces with the best matching technique.Figure4 shows the source image generation process. The face detector detects the faces (target faces) of the occupants (from the in-cabin visual input). The identity feature extractor extracts the IDs (128D identity features) of faces (target faces) and matches the similarity of the target faces with the set of virtual human faces (source faces) to find the most appropriate source face. This similarity matching is in the vector space (Euclidean distance matching between the extracted face ID and IDs of the set of virtual human faces).


#### 2.2.3. Facial Anonymization

Facial anonymization requires exactitude in the anonymized faces to mitigate errors in further processing. Therefore, swapping should be performed efficiently to provide unaltered expressions and emotions over the anonymized face. We used the concept of FSGAN for facial anonymization to provide personal privacy during in-cabin monitoring of irregular situations. This requires perfection in the following three tasks:(i) Facial Reenactment and Segmentation. To obtain proper facial swapping, we must estimate the proper reenacted face. This is performed by the proper segmentation of the face and hair segments of the target image. Proper facial reenactment requires separate face and hair segmentations with the mapping of 2D facial landmark positions. Therefore, the stepwise loss function is considered as the objective function for implementing facial reenactment. For ith layer feature map Fi∈ℝCi×Hi×Wi, the perceptual loss ℒperc between pairs of images (x, y) is expressed as follows:(3)ℒpercx,y=∑1Ci×Hi×Wi×‖Fix,Fiy‖2.The reconstruction lossℒrec between a pair of images (x, y) is expressed as follows:(4)ℒrecx,y=λperc×ℒpercx,y+λpixel×ℒpixelx,y,where “λ” is the corresponding hyperparameter λperc=1;λpixel=0.1;λadv=0.001;λSG=0.1;λrec=1;λstepwise=1 and λreenactment is linearly increased from 0 to 1 during training. Pixelwise loss ℒpixel between a pair of images (x, y) is calculated as ℒpixelx,y=‖x−y‖. We have used the multiscale discriminator adversarial loss objective function to improve the realism of the generated images. The adversarial loss ℒadv between the generator and discriminator (G, D) is expressed as follows:(5)ℒadvG,D=minmax∑ℒGANG,D,ℒGANG,D=Ex,ylogDx,y+Exlog1−Dx,Gx,where “Ex,y” is the expected value over all real data instances. “Ex” is the expected value over all random inputs to the generator. The reenactment generator loss ℒRG is given by the following equation:(6)ℒRG=ℒperc+ℒrec+ℒadv.The perpetual loss is used to estimate the errors in capturing fine facial details, and the reconstruction loss is used to evaluate pixelwise color inaccuracy. Adversarial loss improves the generated images and provides a realistic look. The standard cross-entropy lossℒCE is defined as (for truth label “ti” and the “SoftMax” probability “Pi” for ith class)(7)ℒCE=−∑ti×logPi.Further, segmentation generator lossℒSG is obtained by the following equation:(8)ℒSG=ℒCE+ℒpixel.(ii) Facial Inpainting. This method estimates the missing portions of the reenacted face based on the face and hair segmentation of the target image. The inpainting generator loss ℒIP was calculated using the following equation:(9)ℒIP=ℒrec+ℒadv.(iii)
Facial Blending. It blends the completely reenacted face such that the swapped face matches the background environment like the original target face. The loss function ℒB for facial blending is obtained using the following equation:(10)ℒB=ℒperc+ℒadv.The identity signature is generated corresponding to each occupant (a pair of identity signatures for real and anonymized faces) in the FAV. After facial anonymization, the video frames are transmitted to the cloud along with a pair of identity signatures of the occupants.


#### 2.2.4. Anonymized Person Reidentification in Abnormal Situations

The proposed IMS facilitates the reidentification of the person involved in an abnormal situation. In our algorithm, in-cabin facial anonymization for preserving identity before transmitting the video frames to the cloud was achieved through the following pseudocode. The identity signature is generated corresponding to each occupant in the FAV. It is a vector of size 1 × 128. Therefore, for each occupant, we have a pair of identity signatures corresponding to the original and anonymized faces. Each pair is stored in the cloud. In any irregular situation, the concerned person is back-traced by matching the identity signature and anonymized face. The following is Pseudocode 1 of our proposed approach for obtaining the identity features (ID) of the person involved in an abnormal situation.Pseudocode 1: Algorithm for obtaining the ID of a person involved in an abnormal situation.
(i)
Definitions: Faces of the occupant (F); target face (T); appropriate source face (S); anonymized face (A); identity features (ID): real face ID (IDR); anonymized face ID (IDA); ID of the occupant that caused an abnormal situation (IDA_AS); and an in-cabin abnormal situation (AS).(ii)
Functions:F  = face detector; S  = source detector; A  = anonymizer; I  = IDextractor.(iii)
Input: video frames (in-cabin)(1)
fori = 1 to range of the occupant:(iv)
T(i) =  F (Input)(v)
S(i) =  S (T(i)) # search most similar source face for target face(vi)
A(i) ← A (T(i), S(i))(vii)
IDR(i) =  II (T(i)) # 128D feature vector of the target face IDA(i) =  II (A(i))(2)
store:ID(i) ← (IDR(i); IDA(i))(3)
At datacenter: monitor event and behavior forAS:(viii)
ifoccupant j is involved in AS, then:(xi)
generate (IDA_AS(j)) #ID of jth occupant in abnormal situation(x)
matchID:(xi)
forID from 1 to range of the ID:(xii)
k = argmin(‖IDA_AS(j), IDA(:))‖2)(4)
Map:IDR(k) ← IDA(k)(xiii)
return (IDR(k)) # the algorithm returns the real face ID of an anonymized personWe considered virtual human face generation for the source faces. These faces are used to swap the target face in the captured visual in-cabin dataset. The source faces are generated depending on the similarity of the target face in the vector space. A similar source face provides the exactitude in replaying the facial gestures. This facilitates better reenactment performances. The concept of virtual human face generation for the source face protects any chaos or risk of threatening others’ identities. Furthermore, we generated the facial identity signatures of the original and anonymized faces. These identity signatures help backtrack the concerned person in the event of an irregular situation. The identity signature is only vectored information. In other words, the identity signature in our proposed approach is extracted from a face that is used to reidentify the face. However, a face cannot be recreated using this information. Therefore, personal identity is not revealed through the identity signature. Our proposed approach provides proof or evidence that confirms the identity of the concerned person. The following is Pseudocode 2 of our proposed approach for evidence of the person involved in an abnormal situation.Pseudocode 2: Algorithm for evidence of the person involved in the abnormal situation.
(i)
Definitions: Target face (occupant’s face) captured during the investigation (Tinv); ID of the occupant’s face obtained during an investigation (IDinv); ID of the person involved in the abnormal situation (IDR); and real face of the occupant involved in the abnormal situation (O).(ii)
Functions: II  = ID extractor.(iii)
Input:Tinv; IDR(1)
At investigation:(iv)
fori from 1 to range of the target faces:(v)
IDinv(i) =  II (Tinv(i))(vi)
matchID: # compare IDR and the suspect face ID(vii)
j=argminiIDR,IDinvi2(2)
Map:O ← j(viii)
return (O)In the case of proof or evidence, our method determines who is the concerned person. The returned identity feature (real faceIDR(k)) in Pseudocode 1 refers to the crucial identity parameter of the person involved in an abnormal situation. Matching the identity feature at the time of investigation with the obtained ID (real face IDR(k)) confirms the person involved in an abnormal situation. Therefore, this approach easily locates the person involved in an irregular situation without any breach of others’ identities.


## 2.1. Materials

Many research works have been published on personal privacy and person identification considering these two issues as separate research problems. In this study, we briefly surveyed the related works and developments on both face anonymization and person identification.


### 2.1.1. Face Anonymization

Face deidentification preserves privacy-sensitive information. It alters the original face to hide privacy-sensitive information. Anonymization of faces is an easier and more robust solution to personal privacy-related threats in the digital domain [35]. Blurring, masking faces, or creating a patch over faces is slightly easier than any other face anonymization approach; however, those methods suffer from significant loss of facial information [32, 36]. Therefore, face swapping has attracted significant attention for facial anonymization purposes. The morphable model-based facial exchange approach is considered a pioneering work in face swapping [37]. Bitouk et al. demonstrated automatic face replacement in their work [38]. Machine-learning-based face swapping was suggested in [39]. A convolutional neural network (CNN) was used for face segmentation and swapping in [40]. GAN-based deep models have become popular for virtual human face generation [33, 34]. Therefore, along with autoencoders, GAN-based face swapping has gained considerable attention among researchers for seamless end-to-end face anonymization [33, 34, 41]. Face swapping-based automatic generation and editing of faces was showcased in [42]. It used a region-separative GAN (RSGAN). An autoencoder-based algorithm for face swapping was presented to detect fake videos [43]. In [44], a GAN-based encoder-decoder network was suggested to swap human faces. Collateral privacy issues have also been resolved using the face swapping method [45]. Nirkin et al. suggested a face swapping GAN (FSGAN) in [46]. It provided subject agnostic face swapping and reenactment between a pair of faces. Naruniec et al. presented a fully automatic neural face swapping method in [47]. Sun et al. proposed a hybrid model for face anonymization [36]. Hukkelas et al. introduced a GAN-based DeepPrivacy architecture for face deidentification to remove all privacy-sensitive information [34].


### 2.1.2. Person Identification

Facial recognition has multipurpose objectives, such as recognition, classification, and discrimination. Urbanization and smart cities demand widespread applications for face recognition [48–52]. Therefore, various face recognition approaches involving person identification have been demonstrated by past researchers. Face recognition approaches are classified into three categories: local, holistic, and hybrid approaches [52]. Local approaches involve only partial facial features (such as eyes, mouth, and nose) to recognize a face, whereas holistic approaches involve complete facial features, including background for facial recognition. Hybrid approaches, as the name suggests, involve both local and holistic approaches. In holistic approaches, popular algorithms involve independent component analysis, linear discriminative analysis, and principal component analysis [53, 54]. The development of artificial intelligence (AI) incorporating DL and CNNs has boosted the performance of facial recognition algorithms. Taigman et al. presented a deep neural network-based face recognition system, DeepFace [55]. Furthermore, many other extended versions of DeepFace have been demonstrated in multiple studies [56–59]. Adjabi et al. thoroughly reviewed face recognition techniques and their comparisons and future scope in their study [51]. Kortli et al. surveyed popular face recognition techniques in all three categories, that is, local, holistic, and hybrid approaches, in their study [52]. They compared these techniques in terms of accuracy, complexity, and robustness. They also discussed the advantages and disadvantages of the respective approaches. Wang et al. efficiently surveyed DL-based face recognition techniques in their study [60]. They exhaustively reviewed various popular DL-based approaches, including autoencoder-based, CNN-based, and GAN-based techniques. They also enumerated the key features, advantages, and disadvantages of these techniques. Furthermore, they summarized some of the commonly used datasets for deep face recognition. Moreover, they indexed the emerging real-world issues and major technical key challenges in deep facial recognition.However, an application involving person identification must address important privacy concerns [61]. In particular, facial identification in the public domain must tackle individual freedom and ethics-related issues [51, 62]. Therefore, the state-of-the-art research problem in face recognition is the reidentification of an individual on anonymized data. Rocher et al. demonstrated the likelihood of correctly reidentifying a specific individual, even with the anonymized dataset [30]. They suggested a generative graphical model that can be trained on incomplete data to accurately identify individuals. Rooijen et al. suggested 2D video tracking for the reidentification of individuals in an anonymized dataset [20]. They suggested that the real facial information of a person is not necessary for reidentification. Luo et al. suggested effective training tricks for person reidentification [63]. A residual learning framework using the residual network (ResNet) model was suggested in [64] for visual recognition tasks. This facilitated the easier and more efficient training of a substantially deeper network. Schroff et al. suggested unified embedding using only 128 bytes per face for efficient face recognition [65]. They developed their network by incorporating the batch input layer and deep CNN, followed by normalization. They used triplet loss to minimize the training errors. The world’s simplest face recognition library (Dlib face recognition) is a popular and efficient tool for extracting facial landmarks [66]. It is a cross-platform open-source machine-learning toolkit that supports the development of machine-learning algorithms. It helps in recognizing and manipulating faces. Intent and behavior have been successfully detected using various techniques. Facial gesture sensing is performed using virtual reality (VR) and augmented reality (AR) devices, respectively in [67, 68]. AR/VR devices provide sensor responses to detect the intent or behavior of the user. However, FAV in-cabin monitoring requires intent or behavior detection using visual (computer vision (CV)-based) monitoring approaches.


## 2.1.1. Face Anonymization

Face deidentification preserves privacy-sensitive information. It alters the original face to hide privacy-sensitive information. Anonymization of faces is an easier and more robust solution to personal privacy-related threats in the digital domain [35]. Blurring, masking faces, or creating a patch over faces is slightly easier than any other face anonymization approach; however, those methods suffer from significant loss of facial information [32, 36]. Therefore, face swapping has attracted significant attention for facial anonymization purposes. The morphable model-based facial exchange approach is considered a pioneering work in face swapping [37]. Bitouk et al. demonstrated automatic face replacement in their work [38]. Machine-learning-based face swapping was suggested in [39]. A convolutional neural network (CNN) was used for face segmentation and swapping in [40]. GAN-based deep models have become popular for virtual human face generation [33, 34]. Therefore, along with autoencoders, GAN-based face swapping has gained considerable attention among researchers for seamless end-to-end face anonymization [33, 34, 41]. Face swapping-based automatic generation and editing of faces was showcased in [42]. It used a region-separative GAN (RSGAN). An autoencoder-based algorithm for face swapping was presented to detect fake videos [43]. In [44], a GAN-based encoder-decoder network was suggested to swap human faces. Collateral privacy issues have also been resolved using the face swapping method [45]. Nirkin et al. suggested a face swapping GAN (FSGAN) in [46]. It provided subject agnostic face swapping and reenactment between a pair of faces. Naruniec et al. presented a fully automatic neural face swapping method in [47]. Sun et al. proposed a hybrid model for face anonymization [36]. Hukkelas et al. introduced a GAN-based DeepPrivacy architecture for face deidentification to remove all privacy-sensitive information [34].


## 2.1.2. Person Identification

Facial recognition has multipurpose objectives, such as recognition, classification, and discrimination. Urbanization and smart cities demand widespread applications for face recognition [48–52]. Therefore, various face recognition approaches involving person identification have been demonstrated by past researchers. Face recognition approaches are classified into three categories: local, holistic, and hybrid approaches [52]. Local approaches involve only partial facial features (such as eyes, mouth, and nose) to recognize a face, whereas holistic approaches involve complete facial features, including background for facial recognition. Hybrid approaches, as the name suggests, involve both local and holistic approaches. In holistic approaches, popular algorithms involve independent component analysis, linear discriminative analysis, and principal component analysis [53, 54]. The development of artificial intelligence (AI) incorporating DL and CNNs has boosted the performance of facial recognition algorithms. Taigman et al. presented a deep neural network-based face recognition system, DeepFace [55]. Furthermore, many other extended versions of DeepFace have been demonstrated in multiple studies [56–59]. Adjabi et al. thoroughly reviewed face recognition techniques and their comparisons and future scope in their study [51]. Kortli et al. surveyed popular face recognition techniques in all three categories, that is, local, holistic, and hybrid approaches, in their study [52]. They compared these techniques in terms of accuracy, complexity, and robustness. They also discussed the advantages and disadvantages of the respective approaches. Wang et al. efficiently surveyed DL-based face recognition techniques in their study [60]. They exhaustively reviewed various popular DL-based approaches, including autoencoder-based, CNN-based, and GAN-based techniques. They also enumerated the key features, advantages, and disadvantages of these techniques. Furthermore, they summarized some of the commonly used datasets for deep face recognition. Moreover, they indexed the emerging real-world issues and major technical key challenges in deep facial recognition.However, an application involving person identification must address important privacy concerns [61]. In particular, facial identification in the public domain must tackle individual freedom and ethics-related issues [51, 62]. Therefore, the state-of-the-art research problem in face recognition is the reidentification of an individual on anonymized data. Rocher et al. demonstrated the likelihood of correctly reidentifying a specific individual, even with the anonymized dataset [30]. They suggested a generative graphical model that can be trained on incomplete data to accurately identify individuals. Rooijen et al. suggested 2D video tracking for the reidentification of individuals in an anonymized dataset [20]. They suggested that the real facial information of a person is not necessary for reidentification. Luo et al. suggested effective training tricks for person reidentification [63]. A residual learning framework using the residual network (ResNet) model was suggested in [64] for visual recognition tasks. This facilitated the easier and more efficient training of a substantially deeper network. Schroff et al. suggested unified embedding using only 128 bytes per face for efficient face recognition [65]. They developed their network by incorporating the batch input layer and deep CNN, followed by normalization. They used triplet loss to minimize the training errors. The world’s simplest face recognition library (Dlib face recognition) is a popular and efficient tool for extracting facial landmarks [66]. It is a cross-platform open-source machine-learning toolkit that supports the development of machine-learning algorithms. It helps in recognizing and manipulating faces. Intent and behavior have been successfully detected using various techniques. Facial gesture sensing is performed using virtual reality (VR) and augmented reality (AR) devices, respectively in [67, 68]. AR/VR devices provide sensor responses to detect the intent or behavior of the user. However, FAV in-cabin monitoring requires intent or behavior detection using visual (computer vision (CV)-based) monitoring approaches.


## 2.2. Method

In this study, we proposed a representation learning-based approach to generate the identity signature of occupants. This signature is capable of deidentifying a person concerned with an irregular situation in the cabin of level 4 and beyond AVs. We proposed facial anonymization and reidentification system to provide countermeasures in case of an irregular situation. Therefore, this method provides personal information security with traces of the concerned person in case of any abnormality. The proposed method includes four main tasks. First, face anonymization with reenrollment. This is performed by using the face agnostic face swapping technique. It uses a set of GANs. These GANs are used for three purposes: facial reenactment and segmentation, facial inpainting, and facial blending. After accomplishing face anonymization, the second task is to extract the facial identity features of the occupant’s faces in pairs (before and after anonymization, i.e.,IDR and IDA) using the ResNet-based model. These IDs are stored in the cloud, and the anonymized video frames of in-cabin monitoring are transferred to the data center via the cloud for further processing. The third task of the proposed approach is to identify the accused by identity feature matching. Similarity matching of the ID of the accused obtained at the data center with the IDs of the occupants stored in the cloud ensures the identification of the concerned person (IDA). However, it is the ID of the anonymized face of the accused. The Euclidean distance metric was used for similarity matching. Similarly, using the stored pairs of IDs (IDR and IDA), we can obtain the real face identity feature of the accused (IDR). Finally, in the fourth task, the evidence of the accused is obtained by matching the similarities between the IDs of the suspects with the ID of the accused during an investigation. Further details of the proposed method are provided in the following sections.


### 2.2.1. Facial Identity Feature Vector

The facial identity feature is (128, 1)-dimensional encoding of a facial image. It contains the encoded landmarks of the face using theResNet model. The FaceNet-based CNN model and Facedlib face recognition library are used to extract the 128D identity features (ID) from the faces. Additionally, 128D is optimal embedding, which results in appropriate features required for reidentification or measuring the similarity between two faces. It has already been validated in the “FaceNet” architecture that fewer than 128D identity features deteriorate the identification performance; however, increasing the dimension only unnecessarily increases the number of parameters. This is the main reason for adopting the 128D identity features for recognizing faces.Figure3 shows the (128, 1)-dimensional facial identity feature vector generation of the occupant’s face image. It uses a ResNet-based architecture consisting of 29 convolutional layers for this purpose. The ResNet architecture facilitates the dipper layer accessibility. Additionally, they have an inherent tendency to minimize the training error loss by increasing the number of layers. The triplet loss function is used to estimate the error in the reidentification of the concerned person. It performs similarity matching on the 128D identity features. For the anonymized anchor image ID (IA), positive anonymized image ID (IP), and negative anonymized image ID (IN), the triplet loss is estimated by the following equation:(1)ℒA,P,N=max‖IA,IP2‖−‖IA,IN‖2+margin,0.Figure 3
Illustration of 128D facial identity feature vector generation (from the occupant’s face image). Image shown is taken from our in-cabin monitoring database. The numerical values in the yellow, red, green, and blue colored boxes are representing respective passengers’ (128, 1)-dimensional facial identity feature vectors (ID).The anonymized anchor image ID (IA) represents the 128D ID of the person figured out in an irregular situation. The positive anonymized image (IA) is the stored image 128D ID of the same person on the cloud, and the negative anonymized image ID (IA) is the 128D ID of another occupant. Here, (‖x, y‖2) denotes the “Euclidean distance” between pairs {x, y} in the triplet loss function. A factor margin is included in equation (1) to reduce the chances of misclassification. These facial features are incorporated in 128D encoding and are used as the facial recognizer using only 128 bytes per face.Furthermore, a distance-based classifier compares the 128D features to identify the person involved in an irregular situation. It represents the difference between two feature vectors in Euclidean space. Suppose that image (R) represents the person. Image (C) is the stored image (copy) of the same person on the cloud, and image (D) is an image of another occupant. Further, ƒ(x) represents the 128D encoding of the image fx. The similarity (S) in the vector space is measured by the following equation:(2)S=min‖fR,fC‖2,‖fR,fD‖2.It guarantees that images (R) and (C) are of the same occupant and are different from image (D), which is the image of another occupant.


### 2.2.2. Source Image Generation

A source image was required for face swapping in facial anonymization. It is used to replace the face appearing in the target image. This replacement, that is, swapping, should produce a realistic result that seamlessly reenacts the anonymized face that is similar to the target face. Our recommendation is to use a nonreal face as the source image. It mitigates any chaos/conflicts that may occur by using any real face as the source image. Therefore, in our proposed method, we used GAN-generated virtual human faces as the source image. We have considered generating appropriate source faces that can effectively render the original emotions or behaviors performed by the occupants. It helps in further event and behavior-monitoring tasks. Figure4 shows the proposed source image generation process. We applied the concept of similarity matching in vector space to select a similar source face for each target face from the set of virtual human faces (nonreal face as the source image). Similarity matching between source and target faces facilitates reciprocating similar emotions and intents, which is necessary for further monitoring applications.Figure 4
Source image generation using AI-generated faces with the best matching technique.Figure4 shows the source image generation process. The face detector detects the faces (target faces) of the occupants (from the in-cabin visual input). The identity feature extractor extracts the IDs (128D identity features) of faces (target faces) and matches the similarity of the target faces with the set of virtual human faces (source faces) to find the most appropriate source face. This similarity matching is in the vector space (Euclidean distance matching between the extracted face ID and IDs of the set of virtual human faces).


### 2.2.3. Facial Anonymization

Facial anonymization requires exactitude in the anonymized faces to mitigate errors in further processing. Therefore, swapping should be performed efficiently to provide unaltered expressions and emotions over the anonymized face. We used the concept of FSGAN for facial anonymization to provide personal privacy during in-cabin monitoring of irregular situations. This requires perfection in the following three tasks:(i) Facial Reenactment and Segmentation. To obtain proper facial swapping, we must estimate the proper reenacted face. This is performed by the proper segmentation of the face and hair segments of the target image. Proper facial reenactment requires separate face and hair segmentations with the mapping of 2D facial landmark positions. Therefore, the stepwise loss function is considered as the objective function for implementing facial reenactment. For ith layer feature map Fi∈ℝCi×Hi×Wi, the perceptual loss ℒperc between pairs of images (x, y) is expressed as follows:(3)ℒpercx,y=∑1Ci×Hi×Wi×‖Fix,Fiy‖2.The reconstruction lossℒrec between a pair of images (x, y) is expressed as follows:(4)ℒrecx,y=λperc×ℒpercx,y+λpixel×ℒpixelx,y,where “λ” is the corresponding hyperparameter λperc=1;λpixel=0.1;λadv=0.001;λSG=0.1;λrec=1;λstepwise=1 and λreenactment is linearly increased from 0 to 1 during training. Pixelwise loss ℒpixel between a pair of images (x, y) is calculated as ℒpixelx,y=‖x−y‖. We have used the multiscale discriminator adversarial loss objective function to improve the realism of the generated images. The adversarial loss ℒadv between the generator and discriminator (G, D) is expressed as follows:(5)ℒadvG,D=minmax∑ℒGANG,D,ℒGANG,D=Ex,ylogDx,y+Exlog1−Dx,Gx,where “Ex,y” is the expected value over all real data instances. “Ex” is the expected value over all random inputs to the generator. The reenactment generator loss ℒRG is given by the following equation:(6)ℒRG=ℒperc+ℒrec+ℒadv.The perpetual loss is used to estimate the errors in capturing fine facial details, and the reconstruction loss is used to evaluate pixelwise color inaccuracy. Adversarial loss improves the generated images and provides a realistic look. The standard cross-entropy lossℒCE is defined as (for truth label “ti” and the “SoftMax” probability “Pi” for ith class)(7)ℒCE=−∑ti×logPi.Further, segmentation generator lossℒSG is obtained by the following equation:(8)ℒSG=ℒCE+ℒpixel.(ii) Facial Inpainting. This method estimates the missing portions of the reenacted face based on the face and hair segmentation of the target image. The inpainting generator loss ℒIP was calculated using the following equation:(9)ℒIP=ℒrec+ℒadv.(iii)
Facial Blending. It blends the completely reenacted face such that the swapped face matches the background environment like the original target face. The loss function ℒB for facial blending is obtained using the following equation:(10)ℒB=ℒperc+ℒadv.The identity signature is generated corresponding to each occupant (a pair of identity signatures for real and anonymized faces) in the FAV. After facial anonymization, the video frames are transmitted to the cloud along with a pair of identity signatures of the occupants.


### 2.2.4. Anonymized Person Reidentification in Abnormal Situations

The proposed IMS facilitates the reidentification of the person involved in an abnormal situation. In our algorithm, in-cabin facial anonymization for preserving identity before transmitting the video frames to the cloud was achieved through the following pseudocode. The identity signature is generated corresponding to each occupant in the FAV. It is a vector of size 1 × 128. Therefore, for each occupant, we have a pair of identity signatures corresponding to the original and anonymized faces. Each pair is stored in the cloud. In any irregular situation, the concerned person is back-traced by matching the identity signature and anonymized face. The following is Pseudocode 1 of our proposed approach for obtaining the identity features (ID) of the person involved in an abnormal situation.Pseudocode 1: Algorithm for obtaining the ID of a person involved in an abnormal situation.
(i)
Definitions: Faces of the occupant (F); target face (T); appropriate source face (S); anonymized face (A); identity features (ID): real face ID (IDR); anonymized face ID (IDA); ID of the occupant that caused an abnormal situation (IDA_AS); and an in-cabin abnormal situation (AS).(ii)
Functions:F  = face detector; S  = source detector; A  = anonymizer; I  = IDextractor.(iii)
Input: video frames (in-cabin)(1)
fori = 1 to range of the occupant:(iv)
T(i) =  F (Input)(v)
S(i) =  S (T(i)) # search most similar source face for target face(vi)
A(i) ← A (T(i), S(i))(vii)
IDR(i) =  II (T(i)) # 128D feature vector of the target face IDA(i) =  II (A(i))(2)
store:ID(i) ← (IDR(i); IDA(i))(3)
At datacenter: monitor event and behavior forAS:(viii)
ifoccupant j is involved in AS, then:(xi)
generate (IDA_AS(j)) #ID of jth occupant in abnormal situation(x)
matchID:(xi)
forID from 1 to range of the ID:(xii)
k = argmin(‖IDA_AS(j), IDA(:))‖2)(4)
Map:IDR(k) ← IDA(k)(xiii)
return (IDR(k)) # the algorithm returns the real face ID of an anonymized personWe considered virtual human face generation for the source faces. These faces are used to swap the target face in the captured visual in-cabin dataset. The source faces are generated depending on the similarity of the target face in the vector space. A similar source face provides the exactitude in replaying the facial gestures. This facilitates better reenactment performances. The concept of virtual human face generation for the source face protects any chaos or risk of threatening others’ identities. Furthermore, we generated the facial identity signatures of the original and anonymized faces. These identity signatures help backtrack the concerned person in the event of an irregular situation. The identity signature is only vectored information. In other words, the identity signature in our proposed approach is extracted from a face that is used to reidentify the face. However, a face cannot be recreated using this information. Therefore, personal identity is not revealed through the identity signature. Our proposed approach provides proof or evidence that confirms the identity of the concerned person. The following is Pseudocode 2 of our proposed approach for evidence of the person involved in an abnormal situation.Pseudocode 2: Algorithm for evidence of the person involved in the abnormal situation.
(i)
Definitions: Target face (occupant’s face) captured during the investigation (Tinv); ID of the occupant’s face obtained during an investigation (IDinv); ID of the person involved in the abnormal situation (IDR); and real face of the occupant involved in the abnormal situation (O).(ii)
Functions: II  = ID extractor.(iii)
Input:Tinv; IDR(1)
At investigation:(iv)
fori from 1 to range of the target faces:(v)
IDinv(i) =  II (Tinv(i))(vi)
matchID: # compare IDR and the suspect face ID(vii)
j=argminiIDR,IDinvi2(2)
Map:O ← j(viii)
return (O)In the case of proof or evidence, our method determines who is the concerned person. The returned identity feature (real faceIDR(k)) in Pseudocode 1 refers to the crucial identity parameter of the person involved in an abnormal situation. Matching the identity feature at the time of investigation with the obtained ID (real face IDR(k)) confirms the person involved in an abnormal situation. Therefore, this approach easily locates the person involved in an irregular situation without any breach of others’ identities.


## 2.2.1. Facial Identity Feature Vector

The facial identity feature is (128, 1)-dimensional encoding of a facial image. It contains the encoded landmarks of the face using theResNet model. The FaceNet-based CNN model and Facedlib face recognition library are used to extract the 128D identity features (ID) from the faces. Additionally, 128D is optimal embedding, which results in appropriate features required for reidentification or measuring the similarity between two faces. It has already been validated in the “FaceNet” architecture that fewer than 128D identity features deteriorate the identification performance; however, increasing the dimension only unnecessarily increases the number of parameters. This is the main reason for adopting the 128D identity features for recognizing faces.Figure3 shows the (128, 1)-dimensional facial identity feature vector generation of the occupant’s face image. It uses a ResNet-based architecture consisting of 29 convolutional layers for this purpose. The ResNet architecture facilitates the dipper layer accessibility. Additionally, they have an inherent tendency to minimize the training error loss by increasing the number of layers. The triplet loss function is used to estimate the error in the reidentification of the concerned person. It performs similarity matching on the 128D identity features. For the anonymized anchor image ID (IA), positive anonymized image ID (IP), and negative anonymized image ID (IN), the triplet loss is estimated by the following equation:(1)ℒA,P,N=max‖IA,IP2‖−‖IA,IN‖2+margin,0.Figure 3
Illustration of 128D facial identity feature vector generation (from the occupant’s face image). Image shown is taken from our in-cabin monitoring database. The numerical values in the yellow, red, green, and blue colored boxes are representing respective passengers’ (128, 1)-dimensional facial identity feature vectors (ID).The anonymized anchor image ID (IA) represents the 128D ID of the person figured out in an irregular situation. The positive anonymized image (IA) is the stored image 128D ID of the same person on the cloud, and the negative anonymized image ID (IA) is the 128D ID of another occupant. Here, (‖x, y‖2) denotes the “Euclidean distance” between pairs {x, y} in the triplet loss function. A factor margin is included in equation (1) to reduce the chances of misclassification. These facial features are incorporated in 128D encoding and are used as the facial recognizer using only 128 bytes per face.Furthermore, a distance-based classifier compares the 128D features to identify the person involved in an irregular situation. It represents the difference between two feature vectors in Euclidean space. Suppose that image (R) represents the person. Image (C) is the stored image (copy) of the same person on the cloud, and image (D) is an image of another occupant. Further, ƒ(x) represents the 128D encoding of the image fx. The similarity (S) in the vector space is measured by the following equation:(2)S=min‖fR,fC‖2,‖fR,fD‖2.It guarantees that images (R) and (C) are of the same occupant and are different from image (D), which is the image of another occupant.


## 2.2.2. Source Image Generation

A source image was required for face swapping in facial anonymization. It is used to replace the face appearing in the target image. This replacement, that is, swapping, should produce a realistic result that seamlessly reenacts the anonymized face that is similar to the target face. Our recommendation is to use a nonreal face as the source image. It mitigates any chaos/conflicts that may occur by using any real face as the source image. Therefore, in our proposed method, we used GAN-generated virtual human faces as the source image. We have considered generating appropriate source faces that can effectively render the original emotions or behaviors performed by the occupants. It helps in further event and behavior-monitoring tasks. Figure4 shows the proposed source image generation process. We applied the concept of similarity matching in vector space to select a similar source face for each target face from the set of virtual human faces (nonreal face as the source image). Similarity matching between source and target faces facilitates reciprocating similar emotions and intents, which is necessary for further monitoring applications.Figure 4
Source image generation using AI-generated faces with the best matching technique.Figure4 shows the source image generation process. The face detector detects the faces (target faces) of the occupants (from the in-cabin visual input). The identity feature extractor extracts the IDs (128D identity features) of faces (target faces) and matches the similarity of the target faces with the set of virtual human faces (source faces) to find the most appropriate source face. This similarity matching is in the vector space (Euclidean distance matching between the extracted face ID and IDs of the set of virtual human faces).


## 2.2.3. Facial Anonymization

Facial anonymization requires exactitude in the anonymized faces to mitigate errors in further processing. Therefore, swapping should be performed efficiently to provide unaltered expressions and emotions over the anonymized face. We used the concept of FSGAN for facial anonymization to provide personal privacy during in-cabin monitoring of irregular situations. This requires perfection in the following three tasks:(i) Facial Reenactment and Segmentation. To obtain proper facial swapping, we must estimate the proper reenacted face. This is performed by the proper segmentation of the face and hair segments of the target image. Proper facial reenactment requires separate face and hair segmentations with the mapping of 2D facial landmark positions. Therefore, the stepwise loss function is considered as the objective function for implementing facial reenactment. For ith layer feature map Fi∈ℝCi×Hi×Wi, the perceptual loss ℒperc between pairs of images (x, y) is expressed as follows:(3)ℒpercx,y=∑1Ci×Hi×Wi×‖Fix,Fiy‖2.The reconstruction lossℒrec between a pair of images (x, y) is expressed as follows:(4)ℒrecx,y=λperc×ℒpercx,y+λpixel×ℒpixelx,y,where “λ” is the corresponding hyperparameter λperc=1;λpixel=0.1;λadv=0.001;λSG=0.1;λrec=1;λstepwise=1 and λreenactment is linearly increased from 0 to 1 during training. Pixelwise loss ℒpixel between a pair of images (x, y) is calculated as ℒpixelx,y=‖x−y‖. We have used the multiscale discriminator adversarial loss objective function to improve the realism of the generated images. The adversarial loss ℒadv between the generator and discriminator (G, D) is expressed as follows:(5)ℒadvG,D=minmax∑ℒGANG,D,ℒGANG,D=Ex,ylogDx,y+Exlog1−Dx,Gx,where “Ex,y” is the expected value over all real data instances. “Ex” is the expected value over all random inputs to the generator. The reenactment generator loss ℒRG is given by the following equation:(6)ℒRG=ℒperc+ℒrec+ℒadv.The perpetual loss is used to estimate the errors in capturing fine facial details, and the reconstruction loss is used to evaluate pixelwise color inaccuracy. Adversarial loss improves the generated images and provides a realistic look. The standard cross-entropy lossℒCE is defined as (for truth label “ti” and the “SoftMax” probability “Pi” for ith class)(7)ℒCE=−∑ti×logPi.Further, segmentation generator lossℒSG is obtained by the following equation:(8)ℒSG=ℒCE+ℒpixel.(ii) Facial Inpainting. This method estimates the missing portions of the reenacted face based on the face and hair segmentation of the target image. The inpainting generator loss ℒIP was calculated using the following equation:(9)ℒIP=ℒrec+ℒadv.(iii)
Facial Blending. It blends the completely reenacted face such that the swapped face matches the background environment like the original target face. The loss function ℒB for facial blending is obtained using the following equation:(10)ℒB=ℒperc+ℒadv.The identity signature is generated corresponding to each occupant (a pair of identity signatures for real and anonymized faces) in the FAV. After facial anonymization, the video frames are transmitted to the cloud along with a pair of identity signatures of the occupants.


## 2.2.4. Anonymized Person Reidentification in Abnormal Situations

The proposed IMS facilitates the reidentification of the person involved in an abnormal situation. In our algorithm, in-cabin facial anonymization for preserving identity before transmitting the video frames to the cloud was achieved through the following pseudocode. The identity signature is generated corresponding to each occupant in the FAV. It is a vector of size 1 × 128. Therefore, for each occupant, we have a pair of identity signatures corresponding to the original and anonymized faces. Each pair is stored in the cloud. In any irregular situation, the concerned person is back-traced by matching the identity signature and anonymized face. The following is Pseudocode 1 of our proposed approach for obtaining the identity features (ID) of the person involved in an abnormal situation.Pseudocode 1: Algorithm for obtaining the ID of a person involved in an abnormal situation.
(i)
Definitions: Faces of the occupant (F); target face (T); appropriate source face (S); anonymized face (A); identity features (ID): real face ID (IDR); anonymized face ID (IDA); ID of the occupant that caused an abnormal situation (IDA_AS); and an in-cabin abnormal situation (AS).(ii)
Functions:F  = face detector; S  = source detector; A  = anonymizer; I  = IDextractor.(iii)
Input: video frames (in-cabin)(1)
fori = 1 to range of the occupant:(iv)
T(i) =  F (Input)(v)
S(i) =  S (T(i)) # search most similar source face for target face(vi)
A(i) ← A (T(i), S(i))(vii)
IDR(i) =  II (T(i)) # 128D feature vector of the target face IDA(i) =  II (A(i))(2)
store:ID(i) ← (IDR(i); IDA(i))(3)
At datacenter: monitor event and behavior forAS:(viii)
ifoccupant j is involved in AS, then:(xi)
generate (IDA_AS(j)) #ID of jth occupant in abnormal situation(x)
matchID:(xi)
forID from 1 to range of the ID:(xii)
k = argmin(‖IDA_AS(j), IDA(:))‖2)(4)
Map:IDR(k) ← IDA(k)(xiii)
return (IDR(k)) # the algorithm returns the real face ID of an anonymized personWe considered virtual human face generation for the source faces. These faces are used to swap the target face in the captured visual in-cabin dataset. The source faces are generated depending on the similarity of the target face in the vector space. A similar source face provides the exactitude in replaying the facial gestures. This facilitates better reenactment performances. The concept of virtual human face generation for the source face protects any chaos or risk of threatening others’ identities. Furthermore, we generated the facial identity signatures of the original and anonymized faces. These identity signatures help backtrack the concerned person in the event of an irregular situation. The identity signature is only vectored information. In other words, the identity signature in our proposed approach is extracted from a face that is used to reidentify the face. However, a face cannot be recreated using this information. Therefore, personal identity is not revealed through the identity signature. Our proposed approach provides proof or evidence that confirms the identity of the concerned person. The following is Pseudocode 2 of our proposed approach for evidence of the person involved in an abnormal situation.Pseudocode 2: Algorithm for evidence of the person involved in the abnormal situation.
(i)
Definitions: Target face (occupant’s face) captured during the investigation (Tinv); ID of the occupant’s face obtained during an investigation (IDinv); ID of the person involved in the abnormal situation (IDR); and real face of the occupant involved in the abnormal situation (O).(ii)
Functions: II  = ID extractor.(iii)
Input:Tinv; IDR(1)
At investigation:(iv)
fori from 1 to range of the target faces:(v)
IDinv(i) =  II (Tinv(i))(vi)
matchID: # compare IDR and the suspect face ID(vii)
j=argminiIDR,IDinvi2(2)
Map:O ← j(viii)
return (O)In the case of proof or evidence, our method determines who is the concerned person. The returned identity feature (real faceIDR(k)) in Pseudocode 1 refers to the crucial identity parameter of the person involved in an abnormal situation. Matching the identity feature at the time of investigation with the obtained ID (real face IDR(k)) confirms the person involved in an abnormal situation. Therefore, this approach easily locates the person involved in an irregular situation without any breach of others’ identities.


## 3. Results and Discussion

In our experiment, we first anonymized the occupants of the FAV to secure their privacy in the public domain. Further, we applied the concept of vector space similarity to match the representation learning-based identity features for face recognition to locate the person involved in an irregular situation. The augmentation of the representation-learning-based identity feature introduces a new domain in reidentification. The proposed system was introduced to maintain personal privacy during the monitoring. We examined our proposed system for the in-cabin monitoring task of the FAV. We captured our database for in-cabin monitoring in abnormal situations. The similarity measure (Si,j) is calculated by the Euclidean distance (ED) metric that is expressed as follows:(11)Si,j=‖fi,fj‖2,where ƒ(i) and ƒ(j) represent the 128D encoding of images i and j, respectively. Therefore, the similarity measure identifies the distance (Euclidean distance) between two pairs of IDs (128D encoding). The lesser the distance is, the closer the faces are.


### 3.1. Appropriate Source Faces

We proposed the concept of an appropriate source face in our facial anonymization approach. For every occupant face (target face), an appropriate source face is obtained by matching their similarity in the vector space. We considered various scenarios to assess the efficacy of our proposed approach, including single and multiple faces in the input image frame. Figure5 shows the complete set of the considered source faces in our experiment. We considered a set of 24 source faces (shown below). All these faces were not real (AI-generated). The source faces were used to swap the target face in the facial anonymization process.Figure 5
Set of virtual human faces (AI-generated faces). These virtual human faces are obtained from Generated Photos. It provides AI-generated images that are free from any copyrights, distribution rights, and infringement claims (source: Generated Photos (https://generated.photos/)).These faces are nonreal virtual human faces. Generated Photos provides GAN-generated faces, which are human faces of nonreal humans. This has the benefit of further augmentation in anonymization. We considered various scenarios in our experiments. Examples include images with a single face only (for both males and females), multiple faces for males only and females only, and multiple faces for both males and females. These are in-cabin images obtained from the public domain (through an image search on the web) and are shown in Figure6. We considered different scenarios for the occupants in the cabin. Therefore, in F1 and F2, there is only a single person in-cabin (F1: male and F2: female). In other scenarios, we considered more than one person in the cabin (only males, only females, and both males and females). Finally, we considered a family with children. There are four most appropriate source faces (S1 to S4) chosen for face anonymization.Figure 6
We have chosen single and multiple faces in the input images in different scenarios: single face (only male or only female), multiple faces (only male), multiple faces (only female), and multiple faces (both male and female). Here, the target (occupant) faces are indexed from F1 to F23, and considered source faces (both male and female) are indexed from S1 to S4.Table1 presents the similarities (in vector space) between the source and target faces, as shown in Figures 5 and 6.Table 1
Similarities between the source and target faces.
ScenarioTarget (occupants†)Similarity measure (using Euclidean distance)S1S2S3S4Single faceMaleF10.914894810.802879610.894330560.74069120FemaleF20.788184840.816361490.685920500.76422129Multiple faceMaleF30.914143910.884003880.876157880.83486502F40.796857330.718623790.934502420.75311709MaleF50.912051740.820942960.872662420.78036428F60.812367090.803816980.938599410.67143296FemaleF70.810977880.827094090.718919880.86480495F80.859471960.785128720.779789780.90500906BothF90.894283900.831585450.884011850.80949051BothF100.849777160.904806970.711743110.94153902BothF110.658315000.528384550.956106710.88142326BothF120.389166490.453613820.891092940.88496564BothF130.796243210.800978130.882023070.71975099BothF140.636602640.673435930.880042480.96042187BothF150.845247070.890086150.775004290.86828727BothF160.745470800.776760840.931556770.73583944BothF170.791791920.803909870.730408280.88839209BothF180.789509080.799867980.720499680.94658813BothF190.900070990.853221990.998293070.85322199BothF200.401971320.638068650.830321990.88047087BothF210.462300890.530982780.858792770.86241199BothF220.480558320.543563840.832165050.81304802BothF230.557516650.457671830.904735980.78517239†The occupants are numbered from left to right clockwise.These values follow the facial similarities of the source and target faces. These values measure the distance between the identity features of the source and target faces. The lower the values are, the more similar the faces are. The values in the green boxes represent the minimum Euclidean distances. These minimum values indicate appropriate source faces for anonymization. We can observe that the male target faces have lesser distances for male source faces than for female source faces. Interestingly, the distance values follow the similarity in looks as well. The eastern looks target faces have a lesser distance for eastern source faces than for the western source face, and vice versa. Female source faces have a lesser distance than the identity features of children’s target faces.


### 3.2. Privacy Preservation during In-Cabin Monitoring

Facial anonymization is performed after deciding the appropriate source face using FSGAN-based face swapping and reenactment. Figure7 depicts the reenacted anonymization of the target faces. Here, the first row (F1 to F8) and the third row (F9 to F23) show the original in-cabin visual inputs, and the corresponding anonymized output is represented in the second row (A1–A8) and fourth row (A9–A23). We chose four source faces (S1 to S4 shown in Figure 6) to swap the target faces (F1 to F23).Figure 7
Facial anonymization with reenactment. F1 to F23: original images. A1 to A23: corresponding anonymized images considering appropriate source faces.It is evident from this result that perfect reenactments are achieved even in the anonymized domain. Thus, it discerns the preservation of personal privacy during monitoring and surveillance operations. Furthermore, this appropriate reenactment supports the detection of abnormal or irregular situations in real time. To examine abnormality detection in the anonymized domain, we have experimented by considering vandalism as an irregular situation inside the vehicle cabin. We created our database for a similar situation. Snippets of the vandalism inside the vehicle are shown in Figure8. We created a situation wherein occupants in the back seat of the vehicle started fighting with the occupants in the front seat. Four scenes were captured in our experiment. Shoulder shaking is shown in scene #1. Scene #2 shows a slapping scenario. Head shaking is discerned in scene #3, and scene #4 represents a neck choking incident inside the cabin of the vehicle. The identity features (IDs) of each occupant were calculated for normal and irregular situations. It is clearly observed that O3 (in the green box) is responsible for the irregular situation (in-cabin vandalism of the vehicle shown in the red box).Figure 8
Snippets of our database showing vandalism inside the vehicle cabin. The original image under normal and irregular situations is in row R1, and the corresponding anonymized images are shown in row R2. The occupants are numbered from left to right clockwise (O1, O2, O3, and O4). Scene#1: O3 shakes shoulder of O4; scene #2: O3 tries to slap O4; scene #3 O3 shakes head of O4; and scene #4: O3 chokes neck of O4. Green box: concerned person and red box: in-cabin vandalism.


### 3.3. Person Reidentification in Abnormal Situations

Table2 presents the similarities of the anonymized identity feature (IDA) with the anonymized facial identity feature of occupant #3 (IDA_IS). Here, IDA_IS is the anonymized identity feature of the occupant who is involved in an irregular situation calculated at the data center, and IDA is the anonymized identity feature of the occupant stored in the cloud.Table 2
Identity feature matching betweenIDA_IS#3 at the data center and other stored IDs of the occupants in the cloud for different scenarios.
SceneSimilarity measure (in Euclidean distance)IDA#1IDA#2IDA#3IDA#4Scene#10.528933460.783631860.354243580.42124692Scene#20.452347070.796877740.358804170.40963131Scene#30.498638820.776155400.417167360.44500655Scene#40.747017550.58166430.537169270.73605501Detail description of scenes (scenes#1–#4) is mentioned in Section 3.2.The values in the green boxes represent the minimum Euclidean distances. These minimum differences between theIDs indicate the involved person. The original ID of this person is stored in the cloud. Therefore, by mapping the ID, we can easily identify the real person. Reidentification was performed by backtracking the ID obtained from the cloud and pictures of the occupants taken during the investigation. The ID of the person involved in an abnormal situation from the cloud (IDR) needs to be matched with the IDs of the occupants inside the vehicle for facial identification of the person. This approach provides proof or evidence confirming the identity of the concerned person. For assurance of the person involved in the abnormal situation, we took pictures of the occupants (during an investigation). The images are shown in Figure 9. Now, the identity feature of each occupant is extracted to match the concerned person ID (IDR) (as per Pseudocode 2). First, we compared the similarity between the faces of the occupants inside the vehicle with those of the other faces captured during the investigation. This is required to ensure that the occupants are the same.Figure 9
Other pictures of the occupants during investigation for matching. The numbering is the same as those in the in-cabin images from left to right (O1′’, O2′’, O3′’, and O4′’).Table3 presents the similarity measures between the occupants’ IDs extracted during an investigation and their IDs extracted from the in-cabin images.Table 3
Identity feature matching between the occupants’IDs extracted during the investigation and their IDs extracted from in-cabin images.
Occupant’sID (in-cabin)Occupant’sIDs were extracted during an investigationIDO1’IDO2’IDO3’IDO4’IDO10.484326090.790618290.720765230.69776956IDO20.758598660.663921540.793480790.72322158IDO30.522659820.776968990.362261760.47469558IDO40.642180590.815298800.521733350.42871777The minimum Euclidean distances are represented by the green boxes. Here, minima indicate that the occupants O and O′’ are the same. Thereafter, assurance of the involved person is performed by matching the identity feature of the occupants extracted from the in-cabin image of the vehicle with theID of the person involved in an abnormal situation (stored in cloud IDR). Table 4 presents the similarity measures between the occupants’ IDs extracted from the in-cabin image with the obtained ID of the person involved in an abnormal situation (stored in cloud IDR).Table 4
Identity feature matching betweenIDR stored in the cloud with other occupant’s IDs extracted from the in-cabin of the vehicle.
ID (person involved)IDs of the occupants (In-cabin)IDO1IDO2IDO3IDO4IDR0.625113490.7596781200.52087737The zero value in the green box indicates that the occupant (O3) is the person involved in an abnormal situation. Overall, this approach focuses on in-cabin monitoring with personal privacy preservation to avoid abnormal situations. Personal privacy preservation is achieved by using the concept of event and behavior monitoring in an anonymized domain. The person’s reidentification is only for providing evidence in cases where the involved person is denying it.


## 3.1. Appropriate Source Faces

We proposed the concept of an appropriate source face in our facial anonymization approach. For every occupant face (target face), an appropriate source face is obtained by matching their similarity in the vector space. We considered various scenarios to assess the efficacy of our proposed approach, including single and multiple faces in the input image frame. Figure5 shows the complete set of the considered source faces in our experiment. We considered a set of 24 source faces (shown below). All these faces were not real (AI-generated). The source faces were used to swap the target face in the facial anonymization process.Figure 5
Set of virtual human faces (AI-generated faces). These virtual human faces are obtained from Generated Photos. It provides AI-generated images that are free from any copyrights, distribution rights, and infringement claims (source: Generated Photos (https://generated.photos/)).These faces are nonreal virtual human faces. Generated Photos provides GAN-generated faces, which are human faces of nonreal humans. This has the benefit of further augmentation in anonymization. We considered various scenarios in our experiments. Examples include images with a single face only (for both males and females), multiple faces for males only and females only, and multiple faces for both males and females. These are in-cabin images obtained from the public domain (through an image search on the web) and are shown in Figure6. We considered different scenarios for the occupants in the cabin. Therefore, in F1 and F2, there is only a single person in-cabin (F1: male and F2: female). In other scenarios, we considered more than one person in the cabin (only males, only females, and both males and females). Finally, we considered a family with children. There are four most appropriate source faces (S1 to S4) chosen for face anonymization.Figure 6
We have chosen single and multiple faces in the input images in different scenarios: single face (only male or only female), multiple faces (only male), multiple faces (only female), and multiple faces (both male and female). Here, the target (occupant) faces are indexed from F1 to F23, and considered source faces (both male and female) are indexed from S1 to S4.Table1 presents the similarities (in vector space) between the source and target faces, as shown in Figures 5 and 6.Table 1
Similarities between the source and target faces.
ScenarioTarget (occupants†)Similarity measure (using Euclidean distance)S1S2S3S4Single faceMaleF10.914894810.802879610.894330560.74069120FemaleF20.788184840.816361490.685920500.76422129Multiple faceMaleF30.914143910.884003880.876157880.83486502F40.796857330.718623790.934502420.75311709MaleF50.912051740.820942960.872662420.78036428F60.812367090.803816980.938599410.67143296FemaleF70.810977880.827094090.718919880.86480495F80.859471960.785128720.779789780.90500906BothF90.894283900.831585450.884011850.80949051BothF100.849777160.904806970.711743110.94153902BothF110.658315000.528384550.956106710.88142326BothF120.389166490.453613820.891092940.88496564BothF130.796243210.800978130.882023070.71975099BothF140.636602640.673435930.880042480.96042187BothF150.845247070.890086150.775004290.86828727BothF160.745470800.776760840.931556770.73583944BothF170.791791920.803909870.730408280.88839209BothF180.789509080.799867980.720499680.94658813BothF190.900070990.853221990.998293070.85322199BothF200.401971320.638068650.830321990.88047087BothF210.462300890.530982780.858792770.86241199BothF220.480558320.543563840.832165050.81304802BothF230.557516650.457671830.904735980.78517239†The occupants are numbered from left to right clockwise.These values follow the facial similarities of the source and target faces. These values measure the distance between the identity features of the source and target faces. The lower the values are, the more similar the faces are. The values in the green boxes represent the minimum Euclidean distances. These minimum values indicate appropriate source faces for anonymization. We can observe that the male target faces have lesser distances for male source faces than for female source faces. Interestingly, the distance values follow the similarity in looks as well. The eastern looks target faces have a lesser distance for eastern source faces than for the western source face, and vice versa. Female source faces have a lesser distance than the identity features of children’s target faces.


## 3.2. Privacy Preservation during In-Cabin Monitoring

Facial anonymization is performed after deciding the appropriate source face using FSGAN-based face swapping and reenactment. Figure7 depicts the reenacted anonymization of the target faces. Here, the first row (F1 to F8) and the third row (F9 to F23) show the original in-cabin visual inputs, and the corresponding anonymized output is represented in the second row (A1–A8) and fourth row (A9–A23). We chose four source faces (S1 to S4 shown in Figure 6) to swap the target faces (F1 to F23).Figure 7
Facial anonymization with reenactment. F1 to F23: original images. A1 to A23: corresponding anonymized images considering appropriate source faces.It is evident from this result that perfect reenactments are achieved even in the anonymized domain. Thus, it discerns the preservation of personal privacy during monitoring and surveillance operations. Furthermore, this appropriate reenactment supports the detection of abnormal or irregular situations in real time. To examine abnormality detection in the anonymized domain, we have experimented by considering vandalism as an irregular situation inside the vehicle cabin. We created our database for a similar situation. Snippets of the vandalism inside the vehicle are shown in Figure8. We created a situation wherein occupants in the back seat of the vehicle started fighting with the occupants in the front seat. Four scenes were captured in our experiment. Shoulder shaking is shown in scene #1. Scene #2 shows a slapping scenario. Head shaking is discerned in scene #3, and scene #4 represents a neck choking incident inside the cabin of the vehicle. The identity features (IDs) of each occupant were calculated for normal and irregular situations. It is clearly observed that O3 (in the green box) is responsible for the irregular situation (in-cabin vandalism of the vehicle shown in the red box).Figure 8
Snippets of our database showing vandalism inside the vehicle cabin. The original image under normal and irregular situations is in row R1, and the corresponding anonymized images are shown in row R2. The occupants are numbered from left to right clockwise (O1, O2, O3, and O4). Scene#1: O3 shakes shoulder of O4; scene #2: O3 tries to slap O4; scene #3 O3 shakes head of O4; and scene #4: O3 chokes neck of O4. Green box: concerned person and red box: in-cabin vandalism.


## 3.3. Person Reidentification in Abnormal Situations

Table2 presents the similarities of the anonymized identity feature (IDA) with the anonymized facial identity feature of occupant #3 (IDA_IS). Here, IDA_IS is the anonymized identity feature of the occupant who is involved in an irregular situation calculated at the data center, and IDA is the anonymized identity feature of the occupant stored in the cloud.Table 2
Identity feature matching betweenIDA_IS#3 at the data center and other stored IDs of the occupants in the cloud for different scenarios.
SceneSimilarity measure (in Euclidean distance)IDA#1IDA#2IDA#3IDA#4Scene#10.528933460.783631860.354243580.42124692Scene#20.452347070.796877740.358804170.40963131Scene#30.498638820.776155400.417167360.44500655Scene#40.747017550.58166430.537169270.73605501Detail description of scenes (scenes#1–#4) is mentioned in Section 3.2.The values in the green boxes represent the minimum Euclidean distances. These minimum differences between theIDs indicate the involved person. The original ID of this person is stored in the cloud. Therefore, by mapping the ID, we can easily identify the real person. Reidentification was performed by backtracking the ID obtained from the cloud and pictures of the occupants taken during the investigation. The ID of the person involved in an abnormal situation from the cloud (IDR) needs to be matched with the IDs of the occupants inside the vehicle for facial identification of the person. This approach provides proof or evidence confirming the identity of the concerned person. For assurance of the person involved in the abnormal situation, we took pictures of the occupants (during an investigation). The images are shown in Figure 9. Now, the identity feature of each occupant is extracted to match the concerned person ID (IDR) (as per Pseudocode 2). First, we compared the similarity between the faces of the occupants inside the vehicle with those of the other faces captured during the investigation. This is required to ensure that the occupants are the same.Figure 9
Other pictures of the occupants during investigation for matching. The numbering is the same as those in the in-cabin images from left to right (O1′’, O2′’, O3′’, and O4′’).Table3 presents the similarity measures between the occupants’ IDs extracted during an investigation and their IDs extracted from the in-cabin images.Table 3
Identity feature matching between the occupants’IDs extracted during the investigation and their IDs extracted from in-cabin images.
Occupant’sID (in-cabin)Occupant’sIDs were extracted during an investigationIDO1’IDO2’IDO3’IDO4’IDO10.484326090.790618290.720765230.69776956IDO20.758598660.663921540.793480790.72322158IDO30.522659820.776968990.362261760.47469558IDO40.642180590.815298800.521733350.42871777The minimum Euclidean distances are represented by the green boxes. Here, minima indicate that the occupants O and O′’ are the same. Thereafter, assurance of the involved person is performed by matching the identity feature of the occupants extracted from the in-cabin image of the vehicle with theID of the person involved in an abnormal situation (stored in cloud IDR). Table 4 presents the similarity measures between the occupants’ IDs extracted from the in-cabin image with the obtained ID of the person involved in an abnormal situation (stored in cloud IDR).Table 4
Identity feature matching betweenIDR stored in the cloud with other occupant’s IDs extracted from the in-cabin of the vehicle.
ID (person involved)IDs of the occupants (In-cabin)IDO1IDO2IDO3IDO4IDR0.625113490.7596781200.52087737The zero value in the green box indicates that the occupant (O3) is the person involved in an abnormal situation. Overall, this approach focuses on in-cabin monitoring with personal privacy preservation to avoid abnormal situations. Personal privacy preservation is achieved by using the concept of event and behavior monitoring in an anonymized domain. The person’s reidentification is only for providing evidence in cases where the involved person is denying it.


## 4. Conclusions

Identity feature augmentation in anonymization is a potential solution for providing privacy in public domain monitoring. Identification of the involved person is crucial, especially in abnormal situations. The proposed intelligent IMS augments the security features with privacy. This method is suitable for creating a monitoring database without any restrictions or legalities. We performed various scenarios to assess the efficacy of the proposed system. It provided an efficient algorithm to perform monitoring tasks in the public domain without any threat to the personal identity of a person. This helped in reidentification, even with an anonymized face. In the future, this algorithm can be implemented on various public domain monitoring platforms, such as transportation systems, shopping centers, theaters, hospitals, highways, fuel refilling stations, smart city applications, and toll plazas.



---

*Source: 5389359-2022-04-22.xml*