{'fraction_non_alphanumeric': 0.035408099254199486, 'fraction_numerical': 0.01446295392765038, 'mean_word_length': 4.641958316948486, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 1, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Adversarial Bone Length Attack on Action Recognition

Skeleton-based action recognition models have recently been shown to be vulnerable to adversarial attacks. Compared to adversarial attacks on images, perturbations to skeletons are typically bounded to a lower dimension of approximately 100 per frame. This lower-dimensional setting makes it more difficult to generate imperceptible perturbations. Existing attacks resolve this by exploiting the temporal structure of the skeleton motion so that the perturbation dimension increases to thousands. In this paper, we show that adversarial attacks can be performed on skeleton-based action recognition models, even in a significantly low-dimensional setting without any temporal manipulation. Specifically, we restrict the perturbations to the lengths of the skeleton's bones, which allows an adversary to manipulate only approximately 30 effective dimensions. We conducted experiments on the NTU RGB+D and HDM05 datasets and demonstrate that the proposed attack successfully deceived models with sometimes greater than 90% success rate by small perturbations. Furthermore, we discovered an interesting phenomenon: in our low-dimensional setting, the adversarial training with the bone length attack shares a similar property with data augmentation, and it not only improves the adversarial robustness but also improves the classification accuracy on the original data. This is an interesting counterexample of the trade-off between adversarial robustness and clean accuracy, which has been widely observed in studies on adversarial training in the high-dimensional regime.


Introduction
Deep neural network models are highly vulnerable to adversarial perturbations, which are small input perturbations intentionally applied by an attacker (Szegedy et al. 2014). This poses a security concern in the use of deep neural network models in practical scenarios. Szegedy et al. (2014) was the first to discover the adversarial attack, that is, applying small perturbations to images that are imperceptible to a human but can fool deep neural network models. Since then, various adversarial attack methods have been proposed in computer vision (Goodfellow, Shlens, and Szegedy 2015;Carlini and Wagner 2017;. Adversarial attacks are not limited to the image domain; they are also possible in domains such as video classification (Wei et al. 2019;Chen et al. 2021b), text classification (Fursov et al. 2021), and speaker recognition (Chen et al. 2021a). One of the reasons underlying the current success of adversarial attacks in various domains and tasks is that adversarial attacks manipulate high-dimensional data (Gilmer et al. 2018;Simon-Gabriel et al. 2019). For example, in the image domain, even small datasets (e.g., CI-FAR10 Krizhevsky (2009)) have hundreds or thousands of pixels to perturb. In the video domain, more dimensions can be perturbed by exploiting the temporal structure. Recently, it was shown that adversarial attacks can succeed even on data in moderate-dimensional settings (Su, Vargas, and Sakurai 2019;Pony, Naeh, and Mannor 2021). In particular, Diao et al. 2021) considered adversarial attacks in skeleton-based action recognition. In this case, an attacker is allowed to perturb the shape and motion of the skeleton along frames, and a skeleton at each frame is represented by approximately 100 parameters (two or three-dimensional coordinates of approximately 30 joints). With constraints on bone connection, the effective number of parameters is even lower. In such a case, it is difficult for attackers to design adversarial perturbations that are sufficiently small to be imperceptible. In Diao et al. 2021), because the motion of the skeleton along frames also was perturbed, they achieved a high success rate of attack with imperceptible adversarial perturbations.
In this study, we consider an extremely low-dimensional adversarial attack on skeleton-based action recognition, where only the lengths of the skeleton's bones can be perturbed, as shown in Fig. 1. The proposed attack has access to only approximately 30 dimensions, which is significantly lower than existing attacks. Despite the restrictiveness of our new attack setting, we experimentally observed that such an extremely low-dimensional attack can succeed. Our bone length attack only requires people to change the apparent bone lengths, e.g., by covering some parts of the body with clothes or attaching a fake extension to arms. In contrast, existing skeleton-based methods require people to move all the joint positions adversarially, which is almost infeasible because perfect body coordination is required all along the motion. Our experiments were conducted on two datasets, the NTU RGB+D ) and HDM05 (Müller et al. 2007) datasets, and two models, the spatial-temporal graph convolutional network (ST-GCN; ) and semantics-guided neural network (SGN; ). In such settings, we saw that with a small perturbation, our attack successfully fooled the models with a 20% success rate, reaching 90% in some cases. We also investigated which parts of a skeleton are more susceptible to our bone length adversarial attack and discovered that perturbing the bones that are long and close to the root joint (base of spine) is effective. Another interesting observation is that adversarial training improves not only the robustness against our attack but also the accuracy of the original data. In the literature (Zhang et al. 2019), it has been established that adversarial training improves the robustness against adversarial examples at the cost of accuracy in original data. Our observations provide a counterexample of this. Based on our experimental results, we consider this to be because in our low-dimensional setting, data augmentation and adversarial examples have similar properties.
Due to the broad and important downstream applications of skeleton-based action recognition, it is crucial to consider the potential vulnerability of skeleton-based action recognition against adversarial attacks. In particular, our adversarial bone length attack seems more realistic than others because it only requires deception of a skeleton extractor to wrongly measure the length of bones, whereas other attacks require perturbation of all positions of joints as well as their time evolution along frames.
Our contributions can be summarized as follows: • We propose the first adversarial attack that only perturbs the lengths of bones to fool skeleton-based action recognition models. Unlike existing adversarial attacks, our attack works in an extremely low-dimensional setting (approximately 30 dimensions and no temporal perturbation).
• Through extensive experiments, we demonstrate the ef-fectiveness of our bone length attack. We also discovered that bones that are long and close to the base of the spine are significantly more susceptible to the attack than other bones. • We discovered that adversarial training using the proposed attack improves not only the adversarial robustness against this attack but also the accuracy against the original data. We also observed that data augmentation improves both the clean accuracy and adversarial robustness. This implies that a low-dimensional adversarial attack may have distinct characteristics from other adversarial attacks in high-dimensional settings.

Related Work
Skeleton-based action recognition. Skeleton-based action recognition has attracted significant attention in recent years. There are many advantages to using skeleton data for action recognition. Skeleton data are considered to be robust to lighting, subject clothing, and background (Sun et al. 2020;. They are also superior to RGB data in terms of computational cost. Due to these advantages and the progress of sensors (Zhang 2012) and pose estimation models (Wandt et al. 2021;Xu and Takano 2021), various models have been proposed Cheng et al. 2021;Kong, Deng, and Jiang 2021).
Adversarial attacks on skeletons. Adversarial attacks in skeleton-based action recognition have been proposed very recently Diao et al. 2021).  was the first to propose an attack on this task. Their proposed attack generates natural motions satisfying multiple physical constraints by fixing the bone length, limiting the perturbation magnitude and joint acceleration, and using a generative adversarial network (Goodfellow et al. 2014). They also showed that adversarial examples remain adversarial even after being converted from skeleton to RGB data and then from RGB to skeleton data.  proposed an attack by restricting the change in angle between bones. They also proposed a defense method.  conducted user studies to show that their attack is highly imperceptible to humans. They also argued that joints with high velocity and acceleration are vulnerable features. These attacks assume that the attacker has complete knowledge of the model being attacked, such as its parameters and structure, and are called white box attacks. In contrast, Diao et al. (2021) proposed a black box attack, which assumes complete ignorance of the information about an attacked model. Most of the aforementioned adversarial attacks increase the effective dimensions of the attack to a few thousand by using degrees of freedom in the temporal direction. In contrast, we propose an adversarial attack that has no freedom in the temporal direction. This restriction makes this study largely different from previous studies.
Low-dimensional adversarial attacks. Our proposed attack perturbs only approximately 30 dimensions. There exist several related attacks. In the image classification domain, Figure 2: The skeleton of the NTU RGB+D dataset. This skeleton consists of 24 bones, and each joint is indexed. We define the base of the spine (joint 1) as the root joint. Our adversarial bone length attack perturbs the scale parameter {β i,j }. (2019) proposed a one-pixel attack, which perturbs only a single pixel. However, attackers can select the target pixel (three channels) from a large number of pixels; thus, the effective dimension is still higher than ours. In addition, a one-pixel attack is relatively easily noticeable. In the video classification domain, the attack proposed by (Pony, Naeh, and Mannor 2021) does not use any spatial information, and thus the available dimensions are low. However, the available dimensions in our attack are less than those in their attack. Moreover, neither Su, Vargas, and Sakurai (2019) nor Pony, Naeh, and Mannor (2021) explored the effect of adversarial training, while we observed an interesting result through adversarial training.

Method
In this section, we explain how to attack skeleton-based action recognition models by perturbing the bone length only.

Notations
We consider L-class skeleton-based action recognition. An action (sequence of skeletons) is represented by where T and M denote the numbers of frames and joints, respectively, and q i (t) ∈ R 3 denotes the 3D coordinates of the i-th joint of the skeleton at frame t. A classifier f receives an action X and outputs an L-dimensional confidence vector, whose k-th entry, denoted by f (X) k , represents the confidence for the k-th class. A class label is encoded in a one-hot representation as y = (y 1 , . . . , y L ) .

Bone length parameters
Our attack perturbs the lengths of bones. The length of the (i, j)-th bone, which connects the i-th and j-th joints, is associated with a scale parameter β i,j , as shown in Fig. 2. Note that simply perturbing the length scale of each bone does not Algorithm 1: Pseudocode of adversarial bone length attack Input: Original sequence of skeleton X, ground truth label y, trained classifier f Parameter: Step size α, maximum iteration number N , bound Output: Adversarial example X z is the confidence vector, which is output by f that received X.
L(·) is cross entropy loss 10: if n = N − 1 then 11: end if 13: end for 14: return X directly yield a valid skeleton. Therefore, the length scales {β i,j } of bones are perturbed from the root joint sequentially as follows. First, we define the base of the spine as the root joint q root (t). Then, starting from the root joint, the position of each joint is set sequentially. Specifically, when a joint q i (t) is perturbed to q i (t), each of its child joints (say, q j (t)) is perturbed as follows: (1) Note that the root is fixed, i.e., q root (t) = q root (t). As can be seen in Eq. (1), the value of β i,j is the ratio between the length of the (i, j)-th bone before and after the adversarial perturbation. After the positional rearrangement by Eq. (1), the final adversarial example of X is given by

Adversarial bone length attack
Our attack is based on the following optimization with respect to the bone length parameters {β i,j }. Let β be a vector that lists the elements of {β i,j }. Then, the adversarial scales of bones are obtained through the following cross-entropy loss maximization: where f is the target classifier that we attempt to attack. The initial value of β is set to an all-one vector, i.e., The magnitude of the perturbation is bounded by . We optimize β using projected gradient descent (PGD) (Eq. (3)) . The parameter β is iteratively updated by where α > 0 is the step size, and β (n) is the β obtained after n iterations. Clip (β (0) , ) [·] is an operator that clips each entry of a given vector to [1 − , 1 + ], and sign(·) denotes the sign function, which maps each element of the argument vector to ±1 according to its sign. The pseudo code of our attack is given in Algorithm 1. First, the bone scale parameter β and adversarial example X are initialized as the all-one vector and X, respectively. Then, the following procedure is repeated.
1. X is input to the target classifier. If the target classifier misclassifies, the attack terminates; otherwise, β is updated according to Eq. (3).
2. The action X is updated according to Eq. (1).
This termination condition of the attack is according to the official code provided by ). In the experiments, we also restricted our attack to a subset of bones to examine which part of skeleton is the most sensitive to the perturbation. In this case, only the subset of {β i,j } was considered in Eq. (3). We also attacked the classifier using Adam  optimizer instead of PGD, as was used in other studies for attacking skeleton-based action recognition models . In this case, the update rule in Eq.
(3) was replaced with that of Adam.

Experiments and Results
We first introduce our experimental settings. Then, we present the results of our proposed attack. Finally, we attempt to defend against our attack.

Experimental settings
Datasets We used the NTU RGB+D ) and HDM05 (Müller et al. 2007) datasets, which are 3D skeleton action datasets. The NTU RGB+D dataset consists of 56,880 motion data of a skeleton with 24 bones. This dataset has 60 classes and was created from 40 subjects. There are two ways to split the training and test data: cross-subject (CS) and cross-view (CV). In CS, the dataset is divided so that the numbers of subjects included in the training and test data are both 20. The numbers of samples are 40,320 and 16,560, respectively. CV divides the training and test data according to the camera's viewpoint. The numbers of samples in these training and test datasets are 37,920 and 18,960, respectively. The HDM05 dataset consists of 2,337 data of a skeleton with 30 bones. The number of classes is 130. At the prepossessing stage, we adopted a smoothing filter, translation, and so on. This reduced the number of classes to 65. We randomly divided samples of each class into a training set (80%), validation set (10%), and testing set (10%). Please refer to the supplementary material for this preprocess.
Target models We used two skeleton-based action recognition models as our target models to attack: the ST-GCN (Yan, Xiong, and Lin 2018) and SGN  models. When the NTU RGB+D dataset was used, we used pretrained weights provided by the authors of each model 12 . When the HDM05 dataset was used, we trained the two models with the official code provided by the authors.
To guarantee the convergence, we ran at least 300 epochs for the ST-GCN model and 200 epochs for the SGN model and adopted early stopping for both models. The data augmentation for each model was the same as when the model was trained on the NTU RGB+D dataset. After training, the test accuracies on the ST-GCN and SGN models were 86.1% and 96.1%, respectively.
Evaluation metrics and others Following , we attacked the test data that were correctly classified by the target model. Then, the attacks were evaluated based on their success rate. In this paper, we used PGD (Eq. 3). We leave the results using Adam in the supplementary material. The maximum number of iterations of the PGD was set to 50. The step size was set to α = 0.01, as in . All experiments were conducted using an Intel Core i7-6850K CPU and TITAN RTX GPU.

Attack results
To investigate the effectiveness and imperceptibility of our attack, we attacked two models. In Fig. 3 (a), we show the results of the attack using the NTU RGB+D dataset. As a result of the attack on the ST-GCN model, the success rates for the PDG attack with = 0.1 and = 0.2 exceeded 10% and 20%, respectively. Note that this success rate is not as high as those achieved in other studies; this is because the dimensionality of the input data used for the attack in these studies was much higher (e.g., thousands of dimensions), whereas in our setting, the dimensionality is only approximately 30. Nevertheless, our attack achieved moderate success rates that were nonnegligible for practical use. When we set = 0.5, we can see that the attack became more successful (greater than 50% success). For the HDM05 dataset, the success rate was even higher (Fig. 3 (b)). We observed that the success rate of the attack on the ST-GCN model exceeded 70% when = 0.1. With = 0.2, the success rate was over 90%.
The results indicate that the proposed attack is very effective for some models and datasets. In Fig. 4 (a), we provide an adversarial example generated with = 0.1 when we attacked the ST-GCN model using the HDM05 dataset. One can see that the predicted classes are different although the skeletons appear very similar before and after the attack (blue and red, respectively). The same result was observed for = 0.2 (Fig. 4 (c)). To summarize, the ST-GCN model trained by the HDM05 dataset was very vulnerable to our bone length attack on the skeleton. However, the confidences on the adversarial motions in Figs. 4 (a) and (c) are relatively low, because we employ early-stopping (ES); the proposed attack terminates once the adversarial example fools the target model . To make the confidences higher, we can increase the number of iterations in the PGD attack. Hence we attacked the model with 50 iterations, which is the maximum number of iterations in the PGD attack. We call the termination condition the full-run (FR) case. Table 1 shows that the average confidence scores in the ES and FR cases for misclassified adversarial examples and that the confidence scores in the FR case are higher than those in the ES case. In Figs. 4 (b) and (d), we demonstrate the FR attacks using the same original data in Figs. 4 (a) and (c), respectively. From Figs. 4, one can see the FR attacks cause bigger changes than the ES attacks. These results  Table 2: Classification accuracy of models trained with the HDM05 dataset with and without data augmentation (w/ aug and w/o aug, respectively). One can see that data augmentation improved the accuracy for both models.
come from that there is a trade-off between high confidence and imperceptibility. As we can see the results for the HDM05 dataset shown in Fig. 3(b), attacks on the two models resulted in significantly different success rates; the ST-GCN model was highly vulnerable to the attack, while the SGN model was more adversary-robust. We believe the reason underlying the adversarial robustness of the ST-GCN model lies in the data augmentation process. When we trained the ST-GCN and SGN models with the HDM05 dataset, we followed the training protocol with the NTU RGB+D dataset from the corresponding papers of the two models. Therefore, we did not use data augmentation when the ST-GCN model was trained with the NTU RGB+D dataset, but we did for the SGN model (Sec. 4.1). To observe the effect of data augmentation on adversarial robustness, we trained the models on the HDM05 dataset with and without data augmentation and attacked them. The data augmentation during training of the SGN model was performed by randomly rotating the skeleton. We adopted this augmentation for the ST-GCN model as well because we did not want the results to depend on the quality of the data augmentation. As shown in Table 2, the classification accuracy of both models for original data was improved by data augmentation. Interestingly, as shown in Fig. 5, data augmentation also improved the adversarial robustness (lower success rates). In particular, the improvement in adversarial robustness for the ST-GCN model was significant (approximately 20% improvement at = 0.1). Therefore, the adversarial robustness exhibited by the ST-GCN model in Fig. 3(b) can be attributed to the presence of data augmentation.
In image classification, some data augmentation methods were proposed to improve adversarial robustness (Zhang et al. 2018;Yun et al. 2019). However, in white box setting, these methods are effective only for non-iterative attack    Table 4: Success rates of adversarial bone length attack on the ST-GCN model with the HDM05 dataset by restricted to the union of Parts 3, 4, and 5, which contains more total number of bones as Part 6. The sensitivity to the attack in this region was lower than that in Part 6 (Table 3).
e.g., FGSM (Goodfellow, Shlens, and Szegedy 2015). To the best of our knowledge, the literature has not previously reported data augmentation significantly improving adversarial robustness against iterative attack. In (Rice, Wong, and Kolter 2020) and (Gowal et al. 2020), adversarial training was combined with various data augmentations, but no particular improvement in adversarial robustness was observed. We hypothesize that in the low-dimensional setting of this study, adversarial examples and augmented data are much more similar than in a high-dimensional setting, where adversarial examples are usually considered. We show promising empirical results regarding this hypothesis in Sec. 4.3. Next, we investigated which subsets of bones were more vulnerable to perturbations. For this, we used the ST-GCN model and the HDM05 dataset. The skeleton was divided into seven parts (Fig. 6), and adversarial perturbation was only applied to one of them. The results are summarized in Table 3. One can see that attacks on Parts 1,4,5,and 7 (head,wrists,hands,and feet,respectively) almost completely failed, whereas attacks on Parts 2, 3, and 6 (body, shoulders, and legs, respectively) were successful. In particular, the success rate for Part 6 was significant compared to those for the other parts. Thus, the legs are more susceptible to attacks. Part 6 has more bones than the other parts. To determine if the number of bones causes the vulnerability, we considered a joint attack on Parts 3, 4, and 5, which have more total bones than Part 6 alone. The results are presented in Table 4. It can be seen that the attack adding perturbations to Parts 3, 4, and 5 resulted in a much lower success rate. As such, the vulnerability of Part 6 is not due to its number of bones.
Based on the above results, we found two tendencies. First, the closer the perturbed bones are to the root joint, the more successful the attack is likely to be. We believe that because a change in bone length can move the positions of the bones of their descendants, a change in bones closer to the root joint can have a greater impact on the entire skeleton. Second, the longer the perturbed bones are, the more likely the attack will be successful. The in this attack is proportional to the original bone. Therefore, for the same , the longer the perturbed bone is, the greater the amount of bone change is allowed. These results differ from those of . They stated that joints with greater velocity and acceleration are more useful for attacks. In contrast, our results show that attacks that perturb the torso are more successful than those that perturb the hands and arms. Therefore, we can see that our attack has different characteristics to theirs.

Adversarial Training
Next, we attempt to defend against our attack by performing adversarial training ) on the HDM05 dataset. We used our attack with = 0.1 in adversarial training. The results are shown in Fig. 7. One can see that the ST-GCN and SGN models with adversarial training were more robust than that trained using the original data. By adversarial training, the ST-GCN model acquired the same level of robustness against our attack as the SGN model, and the SGN model provided only a low success rate even for large perturbation . These results suggest that the proposed attack can be prevented to some extent by adversarial training. Notably, we can also see that adversarial training increased the accuracy on the original data, as shown in Table 5. The clean accuracy of the ST-GCN model was 86.1% with standard training and 89.8% with adversarial training. This phenomenon is a counterexample of the following widely seen observation in the literature: adversarial training gains adversarial robustness at the cost of reduced clean accuracy. We speculate that there may be a relationship between our attack and data augmentation as a factor in this phenomenon. As shown in Fig. 5, we achieved some adversarial robustness against our attack by data augmentation. Data augmentation was used to increase the accuracy of the model, similar to our results as shown in Table. 2, and adversarial training with our attack also increased the accuracy. In other words, adversarial training with our attack has similar properties to  data augmentation. The details of this will be the subject of future work.

Conclusion
In this paper, we proposed the first bone length adversarial attack on a skeleton-based action recognition models in an extremely low-dimensional setting. Unlike existing attacks, the proposed attack does not manipulate the motion of skeletons and only perturbs the lengths of the skeleton's bones, the number of which is approximately 30. Nevertheless, for some datasets and settings, it was possible to fool models with small perturbations at a success rate of over 90%. The skeletons before and after the attack appeared very similar, which makes our attack difficult to notice. We also found that perturbing the bones that were longer and closer to the root joint was more effective. Furthermore, we observed some interesting properties, which are considered to be a characteristic of our low-dimensional setting: (i) data augmentation improved both clean accuracy and adversarial robustness, and (ii) adversarial training using our attack also improved both of them. To the best of our knowledge, neither of these results have been reported in the standard high-dimensional setting; thus, we consider that our study opens a new direction for adversarial attacks. where I train+val denotes the index sets of the union of the training set and validation set. The set of standard deviation vectors, S = {σ i | i = 1, . . . , M }, is calculated in a similar way. Using the means and standard deviations, each sample is normalized as follows.
where the division by σ i is performed entry-wise. Finally, we sample the frames from X (k) in the four-frame interval to reduce the computational cost and then extended by zero-padding so that the number of frames becomes identical across all the samples. We merged similar classes into a single class as in (Cho and Chen, 2014).

S2 Results with the Adam optimizer
Throughout the experiments in the main text, we used PGD  for the adversarial bone length attack because it is simple and one of the most widely used adversarial attack methods. Some studies on adversarial attacks on skeleton-based action recognition used the Adam optimizer  instead of PGD . Here, we report the results of our experiments with the Adam optimizer. As shown in Fig. S1, the use of the Adam optimizer does not change the main results reported in the main text. With the NTU RGB+D dataset , the SGN model  was slightly more vulnerable than the ST-GCN model , while with the HDM05 dataset, the ST-GCN model was extremely vulnerable even for small perturbations.