## 2 Methodology  
We named the proposed method XGAN, and a schematic summary of its structure is illustrated in Figure 1. It comprises a generator (\(G\)) and a discriminator (\(D\)). \(G\) receives a random signal vector \(z\) and outputs an image \(G(z)\), while \(D\) classifies authentic \(x\) and artificial images \(G(z)\). The model uses XAI to extract feature information from \(D\) and feed it back to \(G\) to perform a new form of training called educational training. To conduct this training, we propose a new loss function \(\mathcal{L}_{G}^{ad}\) that uses traditional adversary losses (\(\mathcal{L}_{G}^{adv}\)) combined with XAI explanations (\(E\)) to backpropagate important information to the generator. The new loss function was defined as follows:  
\[\mathcal{L}_{G}^{ed}=\mathcal{L}_{G}^{adv}*E, \tag{1}\]  
in which \(*\) is the multiplication operation.  
The gradient determines how much to adjust each weight of \(G\) so that the loss function walks towards the optimum. Incorporating \(E\) within the gradient enables emphasis on areas corresponding to objects of interest while dampening the influence of less relevant regions. Our method proposes a student-versus-teacher relationship. In this relationship, \(E\) corresponds to a test answer in which the professor (\(D\)) informs the student (\(G\)) of their test score, indicating features drawn close to reality and those not similar to the original images. Thus, instead of propagating just one value that indicates \(D\)'s classification error, we propagate a matrix with relevant information for each pixel in the image.  
To propagate a matrix, an operation known as the vector-Jacobian product is required, defined as  
\[J\cdot\vec{v}, \tag{2}\]  
where \(\vec{v}\) is a multidimensional vector of the same dimension as the explanations \(E\) with 1 in all positions, and \(J\) is the Jacobian matrix, a matrix of partial derivatives that indicates how the output changes concerning the input. AutoDiff uses the Jacobian matrix to perform the backpropagation process by stacking the partial derivatives for each output concerning each input variable. Considering that a neural network is a function \(f:\mathbb{R}^{n}\rightarrow\mathbb{R}^{m}\) that maps \(n\)-dimensional input vectors (\(x\)) to \(m\)-dimensional output vectors (\(y\)), the matrix \(J\) is defined as  
Figure 1: Schematic summary of the proposed model.  
\[J=\begin{bmatrix}\frac{\partial y_{1}}{\partial x_{1}}&\frac{\partial y_{1}}{ \partial x_{2}}&\dots&\frac{\partial y_{1}}{\partial x_{u}}\\ \frac{\partial y_{2}}{\partial x_{1}}&\frac{\partial y_{2}}{\partial x_{2}}& \dots&\frac{\partial y_{2}}{\partial x_{n}}\\ \vdots&\vdots&\ddots&\vdots\\ \frac{\partial y_{m}}{\partial x_{1}}&\frac{\partial y_{m}}{\partial x_{2}}& \dots&\frac{\partial y_{m}}{\partial x_{n}}\end{bmatrix}. \tag{3}\]  
The Jacobian matrix indicates how the output changes when a small amount of the input changes. In the proposed method, \(J\) also informs the change that each pixel of the artificial image causes in the prediction of \(D\), assigning greater weights to the more relevant pixels via \(E\).  
We used the DCGAN, WGAN-GP, and RAGAN models to define the adversarial loss functions \(\mathcal{L}_{D}^{adv}\) and \(\mathcal{L}_{G}^{adv}\), and the XAI methods Saliency, DeepLIFT, and Gradient\(\odot\)Input to generate the explanations \(E\). We give more details about the models and methods in the following sections.