# Use of Generative Adversarial Networks (GAN) for
## 2 Methods and Samples  
### Phase 1: Parameter Selection and Model Protocol  
In order to test the best architecture and parameters for BSM DL analysis, we selected some of the most powerful existing DCNN models, some of them successfully used for BSM classification [1]: VGG16, ResNet50, Densenet, and Jason2. All these models, but the latter, were used through transfer learning. Transfer learning consists of using models that were trained for a different problem and use their feature-learning weights, which are already pre-trained [17], for retraining on new image datasets. Here, some of the most high-performing models trained on more than 1,000,000 images for the 1000-image category ILSVRC competition were used. These pre-trained models were used as standalone feature extractors and classifiers. The layers of each pre-trained model with their weights were integrated within the new models used here containing an output dense layer containing 128 neurons. This was implemented through the Keras API. For a summary of the description of these architectures see [1; 5]. In previous modeling, BSM images were high resolution (80 \(\times\) 400 pixels) [1]. Here, we adopted a lower resolution approach, since experimentation showed that model accuracy was not affected. For this reason, we reshaped the original rectangular BSM images into 64 \(\times\) 64-pixel images. The original images were captured using a binocular microscope (Optika) at 30\(\times\). The resulting BSM image data bank was composed of 488 cut marks, 106 tooth marks, plus 63 marks from trampling experiments. Cut marks were made with simple flakes. Tooth marks were obtained in experiments of bones modified by lions and wolves. Trampling marks were obtained from experiments using different times of bone exposure to diverse sand-grain sizes. For a detailed description of the BSM samples refer to [1]. For a more in-depth description of the experiments, see [2; 5; 18]. All images were transformed into black and white during image processing in the Keras platform (with a Tensorflow backend), by using bidimensional matrices for standardization and centering. The architectures were designed to address a multiple classification problem. For this reason, the \"softmax\" activation was used on the last dense layer. This function is specific for multinomial classification. It provides the probabilities of each input element of pertaining to a specific label. During compilation, categorical cross-entropy was used as the loss function. We used Tensorflow 2.4.1 and Keras 2.4.2. The architectures were trained on 70% of the original BSM image set (\(n=459\)). The resulting models were subsequently tested against the 30% remaining sample, which constituted the testing set (\(n=197\)). Training and testing were performed through mini-batch kernels (size = 32) because it is the minimum recommended. Models were run using a backpropagation process for 50 epochs. The two parameters selected for intra- and inter- model performance comparison were the activation functions and the optimizers. Following experimentally-based recommendations, we selected the \"relu\" activation as the baseline function [7; 17; 19; 20]. Relu (rectified linear activation) has become the default activation function for DL models because it deals efficiently with vanishing gradient problems (decreased error through backpropagation), the saturation on the ends and the sensitivity focused in the mid-points of other activation functions like sigmoid or tanh [20]. The \"relu\" function returns a value equivalent to the input if activated or zero if inactivated. The formula is rather simple: \(f(x)=max(0,x)\). Recently, a purported improvement over \"relu\" has been suggested by the Google Brain team under a new activation function named \"swish\", whose formula is \(f(x)=x\cdot sigmoid(x)\)[21; 22]. Swish is a monotonic smooth function that implements a sigmoid curvature at the base of the ramp and it is more flexible for activation/deactivation.