{'fraction_non_alphanumeric': 0.02593010146561443, 'fraction_numerical': 0.013597075603839978, 'mean_word_length': 4.687196425102001, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Im2Mesh GAN: Accurate 3D Hand Mesh Recovery from a Single RGB Image

This work addresses hand mesh recovery from a single RGB image. In contrast to most of the existing approaches where the parametric hand models are employed as the prior, we show that the hand mesh can be learned directly from the input image. We propose a new type of GAN called Im2Mesh GAN to learn the mesh through end-to-end adversarial training. By interpreting the mesh as a graph, our model is able to capture the topological relationship among the mesh vertices. We also introduce a 3D surface descriptor into the GAN architecture to further capture the 3D features associated. We experiment two approaches where one can reap the benefits of coupled groundtruth data availability of images and the corresponding meshes, while the other combats the more challenging problem of mesh estimations without the corresponding groundtruth. Through extensive evaluations we demonstrate that the proposed method outperforms the state-of-the-art.


Introduction
Compared with existing research on 2D or 3D hand pose estimation from RGB or/and depth image data, hand mesh recovery can provide a more expressive and useful representation for monocular hand image understanding. The hand mesh recovery from a single RGB image is of particular interest for a wide range of applications in many domains, including augmented reality [19,24] and human computer interaction [20,30].
However, hand mesh recovery is an ill-posed problem considering multiple meshes can be inferred from the same RGB image. The popular solution to deal with this illposed recovery is using priors. Most of the hand mesh recovery approaches in the literature employ the parametric MANO hand model [26] as the hand prior and employ some forms of neural networks to regress the model parameters [3,11,8]. However low dimensional nature of the parametric models limits their capability to capture non-linear shapes of hands [7]. In addition, some approaches rely on the heatmaps of the keypoint annotations in the early steps of their model [8,7]. We argue that this is redundant since the 3D keypoints can be learned simultaneously with the mesh and they should be learned simultaneously due to the complementary nature of two tasks.
In this paper, we approach the problem of learning the priors by end-to-end adversarial training. We show that the hand priors can be learned explicitly in the 3D mesh representation and can be encoded in a generative network. We propose a new type of Generative Adversarial Network (GAN) called Im2Mesh to learn the mesh vertices directly from a single RGB input image. Through the competing process of the generator and discriminator, the generator gradually improves to a level where it can generate the mesh directly from a single input image, providing an accurate solution for the hand mesh recovery task.
Importantly, by interpreting the mesh as a graph, we can employ recent advances in Graph Neural Networks (GNNs) to support mesh processing in both generator and discriminator networks. GNNs have demonstrated the capability of handling non-Euclidean structured data such as graphs and manifolds [21,32]. In contrast to the existing graph-based mesh estimation methods in the literature [7] which only consider the CNN generated features, we introduce a 3D descriptor that encodes surface level information into the GNNs, allowing them to better exploit the topological relationship among mesh vertices in the graph-structured hand data. This improves the mesh recovery accuracy since the recovery algorithm not only considers the vertex 3D coordinates but also the 3D features associated with the vertices.
Our main contribution of this paper are summarised as below: • We propose a new GAN architecture called Im2Mesh to enable end-to-end learning of the hand mesh directly from a single RGB input image, without requiring any heatmap processing, 3D keypoint annotations or external parametric hand models.
• We model the generator of GAN a graph architecture, allowing it to model the topological relationship among the vertices of the mesh while introducing a 3D descriptor to encode the surface level information into the GNNs, further capturing the 3D features associated with the mesh vertices. • The proposed approaches not only address the problem of mesh reconstruction for the coupled datasets where one to one mapping prevails between the images and the groundtruth meshes, but also address the problem of reconstructing mesh for the datasets which do not contain the corresponding groundtruth annotation. • We do not use the depth images; as such we increase the potential of using our model for the datasets which do not have the corresponding depth images. The remainder of this paper is organised as follows. In Section 2 we discuss the related work in the research area and their limitations. Section 3 describes our methodology with subsections outlining each component where we describe the approach for the coupled data as well as for uncoupled data. In Section 4 we present our experimental results, and we conclude the paper in Section 5 while describing the results of the proposed methodology.

Related Work
3D hand pose and mesh estimation using parametric models: Majority of existing 3D hand pose and shape estimation methods [22,8] are based on MANO [26] model which is a low dimensional parametric representation of hand mesh. However, there remain few weaknesses in using such parametric models. Firstly, the model is generated in controlled environments which are different from the images that are encountered in real world [4] thus causing a domain gap. Secondly, the low dimensional nature of the parametric models limits their capability to capture nonlinear shapes of hands [7]. Thirdly, to create a parametric model it requires a large amount of data, which makes it challenging to adopt those methods to other object classes. Due to these limitations, in this paper we propose a hand mesh reconstruction approach which does not utilize a parametric hand model. Model free 3D hand pose and mesh estimation: In the recent approaches on 3D hand pose and mesh estimation where parametric models are not used, other priors are employed. For an instance using 2D pose of the hand as an input to the network [4]. This requires the annotation of the 2D pose on input images, which limits the approach's ability in adopting to the datasets where the 2D pose annotation is not available. In addition, there exists some approaches that rely on heatmaps of the keypoints at early stages [8,7], which requires additional steps of keypoint estimation which can later be extracted directly from the estimated mesh. In contrast, we do not employ 2D or 3D keypoint locations in our method. Graph Neural Networks (GNNs) for hand mesh estimation: In the recent literature, several approaches can be found where GNNs have been employed in estimating the 3D mesh of human hand [4,7]. However, the objective functions of these methods are limited to the vertex coordinates and other properties associated with the vertex location in the final mesh, where the resultant features of the GCNs are not fully utilized. To fully harness the strengths of GCNs we incorporate a 3D feature descriptor to our method, where the GCN is aimed to learn not only the vertex locations but it also learn to estimate the 3D feature descriptor, which elevate the overall accuracy of mesh estimation. Effective use of datasets for hand pose and mesh estimation: When the datasets for hand pose and mesh estimation are considered, most recent datasets (Dome dataset by Kulon et al. [18], FreiHAND dataset by et al. [37]) contains the images and their corresponding groundtruth mesh. These datasets have been used by the state-of-the-art methods for hand pose and mesh estimation [4,22]. However, datasets such as RHD [36] and STB [33] contains the images and their corresponding groundtruth 3D pose, and the methods that have used those datasets have targeted only on estimating the 3D pose [7,34,13,23]. However, we propose an approach where the existing datasets which do not contain the groundtruth mesh details can effectively be used for the task of hand mesh estimation.

Single Image Mesh Generation
When considering the available datasets for single image hand mesh reconstruction, there are 2 main variations; 1) The datasets which contain images and the corresponding by groundtruth mesh (i.e., the dataset by Kulon et al. [18] (referred as the Dome dataset hereafter) and the dataset by Zimmermann et al. [37] (referred as the FreiHAND dataset hereafter), and 2) Other standard datasets such as Rendered Handpose Dataset (RHD) [36] and Stereo Handpose Dataset (STB) [33] that do not contain the groundtruth meshes, instead they contain the 3D and 2D keypoint annotations of the human hand. Therefore we use two different network architectures: 1) To reap the maximum benefit of the availability of the coupled data in the Dome dataset [18] and FreiHAND dataset [37] and 2) To use the mesh data in Dome dataset along with the image data in other standard datasets (i.e., STB and RHD) for the robust estimation of the hand mesh.
In this section, we describe the details of our method. First, we introduce the hand mesh representation and the 3D surface feature descriptor we use in this paper. We then elaborate on the methodology that we use for the two aforementioned data settings.

Hand Mesh Representation
In this work we represent hand mesh M as in Equation 1, where V denotes the vertices and F denotes the faces that comprises the mesh. Each vertex in V is denoted by its x, y and z coordinates (i.e., v i = [x i , y i , z i ]) and each face is denoted by the vertex numbers which have contributed for that face (i.e., (1)

3D Surface Descriptor
In GNNs an attributed graph is defined as, where V is the set of vertices/nodes which is directly extracted from M (Equation 1), E is the set of edges which is derived using F in Equation 1. X, can either be node attributes (i.e., X v R N ×d such that X vi R d , is the feature vector of node v i ), or edge attributes (i.e., X e E T ×c where T is the number of edges in the graph).
In this work, we use a node feature that can represent distinctive node properties. We selected the Signature of Histogram of Orientations (SHOT) descriptor [29], which has the ability to generate descriptive features for 3D points. SHOT descriptor is a combination of the concepts of "signature" [5] and "histogram" [15], such that the descriptor possess computational efficiency while maintaining the robustness. Apart from the evaluations that have been performed by the developers of the SHOT descriptor Samuele et al. [29], the SHOT descriptor has demonstrated optimum performance in different domains [10], including in frameworks with deep learning techniques [2]. The dimension of the feature descriptor depends on the parameters such as the number of neighbours that should be considered at the time of the feature descriptor creation.

Network Architecture for Coupled Training Data
We use a variation of a conditional GAN in this work to generate realistic hand meshes, based on the RGB hand images. The objective of a conditional GAN is expressed as in Equation 3, where G and D are the functions learned by the generator and the discriminator respectively. Conditional GANs are capable of learning the mapping between the input and the desired output.
The configuration of the conditional GAN that we use is depicted in Figure 1. The generator network has 2 components to predict the position vectors (i.e., V in Equation 1) and the node features (i.e., X in Equation 2, wherein this work we have used SHOT descriptor). Similarly, the discriminator network is also composed of 2 components, as "Position Discriminator" and "Surface Descriptor Discriminator".
When it comes to conditional GANs, the generator's objective is to generate output that closely resembles the groundtruth output while fooling the discriminator. Therefore, we define L (G) as in Equation 4, to measure the similarity between the predicted values and the corresponding groundtruth values. The final objective of the conditional GAN is, The first two terms of Equation 4 are aimed at minimizing the reconstruction error between the position vector and the SHOT descriptor respectively. L pos is defined as, where pred pos and gt pos are the predicted and groundtruth vertex locations (i.e., position values) of the mesh [31]. We introduce L shot , which is the difference between the surface descriptors (SHOT descriptor) of the groundtruth mesh and the predicted mesh. L shot is defined as in Equation 7.
A loss based on the surface normals of the mesh is introduced to enforce the smoothness of the mesh. To ensure that the surface normals of the groundruth mesh and the predicted mesh are parallel, the dot product among them is used. L normal is calculated as in Equation 8, where n i pred and n i gt denote the normal vector of face i in the predicted mesh and the groundtruth mesh respectively.
In addition, to further enhance the smoothness of the mesh we employ the Laplacian loss (L Laplacian ) [7]. We introduce two components to the Laplacian loss (Equation 9), where the L V ertexLaplacian is calculated for each of the vertices in the mesh considering the adjacent neighbours while enforcing the smoothness in a fine grained context, and L KeypointLaplacian is calculated for the keypoints while considering the neighbours in a broad range, thus enforcing the smoothness in a more coarser level. The weights of the L V ertexLaplacian and L KeypointLaplacian are denoted by α and β. Laplacian error in general is defined as in whereas L KeypointLaplacian is defined based neighbours that are identified through a graph unrolling and graph traversing process. Please refer to the supplementary material for the details on the method that was used to identify neighbours for L KeypointLaplacian calculation.
The Quadratic loss (L Quadratic ) (Equation 11) [1] is also used to penalize the predicted points in the normal direction. In Equation 11, Q vgt v pred stands for the quadratic error ( [6,27]) which is calculated based on the triangle incidents that correspond to v gt .
In general, the objective of the the discriminator network (D in Equation 3) is to classify whether the given input is from the real sample or whether it has been generated by the generator network (G). However, the existing work on GANs is focused on discriminating the generated data such as class labels and images and thus have used fully connected or convolutional layers in the discriminator.
In this work we use graph convolutional layers in the "Surface Descriptor Discriminator" network (Figure 1), where the node features are taken into consideration. As the edge connections (E in Equation 2) remain the same for all the estimated meshes we use spectral based graph convolution operations. We used GCN layers introduced by Kim et al. [17].

Network Architecture for Uncoupled Training Data
Hand mesh estimation from a single image suffers from the problem of having a limited amount of training data and hence the deep learning based techniques with supervised learning can not be used. As a solution many of the existing methods use the datasets with 3D keypoint annotations and estimate the hand pose. The estimated pose is then used along with parametric models such as MANO [26] for the 3D mesh reconstruction.
In this paper, we use a variation of cycle GAN [35] to estimate the 3D mesh of hand using a single image, based on uncoupled training data. The overview of the framework that we use in this work is depicted in Figure 2, where "Mesh Generator" and "Mesh Discriminator" consists of position and surface descriptor related components which are denoted in Figure 1.
We define the objective function of the network as, where L GAN is defined according to the adversarial loss proposed in [9] (Equation 13). L cyc , which stands for cycle consistency loss is used to constraint the possible mapping functions such that the mapping from image to mesh can be made as unique as possible. We define the cycle consistency loss with two components as L cyc mesh and L cyc im , which stand for the cycle consistency of the mesh generator and L GAN (G, D, X, Y ) = E y (logD (y)) L cyc im = E G I(G M (I)) − I 1 (14)

Generator and Discriminator for Coupled Training Data
The dome dataset [18], contains meshes with 7907 vertices and the FreiHAND dataset, which is based on the MANO model has 778 vertices. The generator network we use is composed with 2 main components 1) To estimate an initial mesh with low resolution and 2) To increase the mesh resolution. For the initial low resolution mesh, we targeted on learning position vectors and SHOT descriptors for 224 vertices. To be compatible with the image shape we derived the shot descriptors with a dimension of 221. For this dataset, SHOT descriptors of a dimension of 221 were obtained by setting the parameters such that number of bins = 7, radius of descriptor estimation = 3 and minimum neighbours = 3.

Generator
For the preliminary layers of the generator we used a convolution based architecture which is in the shape of a U-Net [28], however we did not use any skip connections in this work as the domains of the input and output are different. In denoting the 2D convolution layers followed by a batch normalization and a ReLU activation we use the notation of Convolution-BatchNorm-ReLU. We used a similar architecture as in [14], where the encoder has 8 layers of Convolution-BatchNorm-ReLUs with 64, 128, 256, 512, 512, 512, 512 and 512 kernels followed by a decoder with 8 layers of Convolution-BatchNorm-ReLUs with 512,512,512,512,256,128, 64. The above mentioned convolutions are 4 × 4 filters and decoder network is followed by another convolution layer to make the output channel dimension to 1. The ReLUs in the encoder are leaky with a slope of 0.2. After the final pass, which results in an output of shape 224 × 224 (ignoring the batchsize dimension and channel dimension), we decompose that into two components as

Mesh Enhancer
To enhance the mesh resolution, we used a cascade of Multi-branch GCN [25] modules, where GCNConv layers [17] were used for feature upsampling. For the dome dataset we used 5 Multi-branch GCN modules at the first cascade level and then 8 modules in the second cascaded level and for the FreiHAND dataset we use 3 Multi-branch GCN modules. The resultant node features which construct mesh at full resolution were then passed through a set of Convolution-BatchNorm-ReLU which plays a role analogues to the role of "Coordinator Reconstructor" of the initial work on point upsampling [25]. This contains Convolution-BatchNorm-ReLU layers with 64, 64, 64, 64 and 1 kernels with each kernel having 1 × 3 filters. Thus the output of this network constructs the position vector for the mesh at full resolution.

Discriminator
The discriminator network contains 2 branches where the position vectors and the node features are compared with the corresponding groundtruth values. "Position Discriminator" takes the input of size N × 3 and the "Surface Descriptor Discriminator" takes the input of size N × 221, where N is the number of vertices in the resultant mesh. For the position discriminator we use three Convolution-BatchNorm-ReLU layers with 64,64 and 1 kernels in each with 5 × 1 filters and for the "Surface Descriptor Discriminator", we use 2 GCNConv layers where we reduce the feature size from 221 to 100 and then to 50. We pass each of these through a fully connected layer with 2048 nodes and then concatenate the output from the 2 discriminators before passing them trough another fully connected layer of 1048 nodes followed by a fully connected layer with size 1 and softmax activation.

Generator and Discriminator for Uncoupled Training Data
Compared with the network settings that are described in the above section where the coupled training data is available, when our implementation of cycle GAN (Figure 2) is considered the main difference is that in cycle GAN we have enforced the cycle consistency loss where we feed the mesh generated by "Mesh Generator" in Figure 2 to the "Image Generator" and vice-versa. To allow this, the inputs for each generator should be same in shape. Hence we consider the coarse grained mesh which has 224 vertices and set the input image width and height to 224 pixels. For the generators and for the "Image Discriminator" we used the same architectures that have been used by the original paper of cycle GAN [35]. For the mesh discriminator, we used the same architecture that we described in the "Discriminator" subsection of Section 3.5.
For the setting of uncoupled training data, we separately trained the mesh enhancer ( Figure 3) such that it learns the mapping from low dimensional mesh to the high dimensional mesh, and the generated low dimensional meshes were upsampled using it.

Training
For the network which uses coupled data we set δ = 10 in Equation 5. All the parameters λ, µ, θ , γ and phi in Equation 4, and α and β in Equation 9 were set to 1. To see the effectiveness of the constraints that were enforced to obtain surface smoothness we evaluate the method with setting the parameters θ and γ to 0. The results related to those settings can be found in the Section 4. For the network which used uncoupled data, δ was set to 10. We used a training procedure similar to [14,35] where all the models were trained from the scratch and with a learning rate of 0.0002 using Adam optimizer [16].

Evaluations
In this section we describe the datasets and the evaluation matrix that we used, the ablative studies that we conducted to evaluate the effectiveness of the components in our model, the experimental results that we obtained in benchmarking our model with the state-of-the-art methods. It should be noted that when recording the results of the state-of-the-art methods, we have used the evaluations that are been performed by the respective authors and the results with the best configuration of their proposed methods have been considered.

Datasets
This work utilizes two types of datasets, 1) Coupled dataset where the images and the corresponding groundtruth mesh is available and 2) Datasets which contain only the images. For the coupled dataset we used the Dome dataset [18] and FreiHAND dataset [37] and for the later we used the RHD [36] and STB [33] hand datasets with the 3D meshes which are available as the groundtruth in Dome dataset.

Evaluation Protocol
For the Dome dataset we used the L1 reconstruction error, between the ground truth mesh and the predicted mesh. For the quantitative evaluations of the datasets for which groundtruth meshes are not available we extracted the 3D locations of the keypoints and used the accuracy measurement of Percentage of Correct Keypoints (PCK) scores. In PCK calculation, if the predicted keypoint, which we extract from the estimated mesh lies within a sphere with a specific radius with respect to the groundtruth value, it is considered as correct keypoint.

Ablative Studies
Our ablative studies were conducted on the Dome dataset which has the groundtruth mesh data, as such the quantitative evaluations could be carried out. We Figure 3: The graph enhancement process that was used in our work. It should be noted that this image depicts the process of upsampling a graph which has N nodes and a feature dimension of d, to a graph with R nodes. The depicted network contains two cascaded levels of graph upsampling followed by the "Coordinate Reconstructor" which calculates the position vector of the upsampled graph. k and q are the feature dimensions that of the generated features at cascaded level 1 and 2. Since the objective of our work is to upsample the graph while retaining the number of features we set k = q = d.
conducted the ablative studies, with the aim of evaluating the contribution of the components in Equation 4. All the results related to ablative studies are recorded in Table 1.
Effectiveness of using the 3D surface descriptor: We performed this ablative study to evaluate the effectiveness of incorporating L shot , which measures the similarity in the groundtruth and generated SHOT descriptor. We trained our model on training subset and tested on the test subset of the Dome dataset [18]. For this ablative study, we set µ = 0 in Equation 4.
Effectiveness of enforcing the surface smoothness in the mesh: As described in Section 3.3, our method combines several loss functions to enforce the surface smoothness of the mesh. We evaluate the effectiveness of each of these loss components (i.e., L normal and L Laplacian , where the later consists of 2 components as L V ertexLaplacian and L KeypointLaplacian ). We assessed the effectiveness of using components individually and in combination. First we eliminate all the loss values that are related to the surface smoothness, and the corresponding results can be found in the second raw of Table 1. Similarly by eliminating individual lossless we compared the reconstruction error (Table 1). Figure 4 better visualizes the effect of constraints that are used to smooth the surface. From the conducted ablative studies it is evident that the contribution of the components in the loss function are vital and the compound of all the components has resulted in better accuracy values.

Comparison to the State-of-the-art
For the Dome dataset we compared our method with the state-of-the-art method which has used the same dataset. When the two methods were compared using the L1 reconstruction error, the obtained results are recorded in Table  2. From the obtained values it can be seen that our method has outperformed the state-of-the-art method with signifi-(a) θ = 0 and γ = 0 (b) θ = 0 and γ = 1 (c) θ = 1 and γ = 0 (d) θ = 1 and γ = 1 Figure 4: The qualitative results that were obtained by changing the parameters that are related to surface smoothness, in Equation 4. cant margins. Similarly for FreiHAND dataset, we compared our results with the state-of-the-art methods and the obtained results are recorded in Table 3 Please refer to supplementary material where we have provided qualitative results on the Dome dataset and FreiHAND dataset.
For the RHD dataset and STB dataset, the evaluations were performed using the 3D PCK values, where we compare the extracted 3D keypoint values with the groundtruth 3D keypoint values. The obtained PCK values are recorded in Figure 5. From the results it can be seen that, though the objective of our method was not estimating the 3D keypoint locations, with our method we have obtained PCK values which are comparable to the state-of-the-art methods. It should be noted that our method has not been trained with 3D pose supervision. However, it outperforms the state-ofthe-art methods that have been trained with 3D pose supervision. Please refer to the supplementary material for the Area Under Curve (AUC) values related to Figure 5a and Figure 5b.
Additionally, the in supplementary material we have provided qualitative results for the 3D reconstructions that were obtained by our method in the setting of uncoupled training data. We have illustrated the low resolution meshes as well as the high resolution meshes which were generated by our method.
Additionally, in supplementary material we have provided qualitative results for the 3D reconstructions that were

2.96
Effectiveness of surface normal error

Conclusion
While 3D mesh reconstruction of the human hand using a single image has been explored in the past, the problem still remains a challenge due to the high degree of freedom of the human hand. In this paper, we have presented a method to create 3D mesh of the hand using a single image that can effectively use the existing databases for better reconstruction of the 3D mesh using a single image. We have designed a loss function that can generate more realistic hand meshes, and we demonstrate the effectiveness of that loss function in two settings of Generative Adversarial Networks. The first setting is targeted on the effective use of coupled datasets where the groundtruth meshes are available, whereas the second setting is targeted on uncoupled datasets. In addition, we employ a 3D surface descriptor in this work along with graph convolution networks, which enable the preservation of the surface details of generated meshes. We confirm that our framework outperforms the state-of-the-art as well as the first effort to incorporate explicit 3D features in a single image-based 3D mesh reconstruction. One of the interesting properties of the proposed mesh recovery approach is that there is no need for parametric hand models as priors. The geometry of the hand is learned and encoded directly in the generator through the end-to-end adversarial training process. This fact enables the proposed algorithm to be easily adapted to other mesh problems such as other body parts or 3D objects.  The PCK values that were obtained when comparing our method with the state-of-the-art methods, where our method has comparable results to the state-of-the-art methods.