## 2 Materials and Methods
### Combined Dataset and Pre-Processing  
In this study, it was decided to combine the proposed dataset (BHN) with other datasets of historical newspapers in the literature in order to execute the experiments with a more robust dataset. We searched the literature for datasets of historical German-Brazilian newspapers or other similar newspapers. In [31], a list of such datasets was built meeting the following requirements: 1. they must be open for academic research purposes; 2. they must be easy to access and download; 3. they must be composed, at least in part, of images from historical German-language newspapers; and 4. they must contain layout annotations (i.e., the GT). Then, a total of three datasets of historical newspapers were used, including the BHN, with markings suitable for the task of detecting layout in historical documents. Table 1 presents a description of the datasets, containing information on the quality of the images, dots per inch (DPIs), format, and number of pages in the datasets. The first dataset selected was the _GBN Dataset_ ([[https://web.inf.ufpr.br/vri/databases/gbn/](https://web.inf.ufpr.br/vri/databases/gbn/)]([https://web.inf.ufpr.br/vri/databases/gbn/](https://web.inf.ufpr.br/vri/databases/gbn/)), accessed on 24 August 2023), which consists of 152 color pages images from eight different newspapers belong to the _dbp digital_ project from the _Dokumente.br_ initiative, which has the goal to digitally reconstruct the complete collection of these newspapers [6]. The second dataset chosen, called _BlaLet GT Dataset_ ([[https://github.com/impresso/NZZ-black-letter-ground-truth](https://github.com/impresso/NZZ-black-letter-ground-truth)]([https://github.com/impresso/NZZ-black-letter-ground-truth](https://github.com/impresso/NZZ-black-letter-ground-truth)), accessed on 26 October 2023), has 167 images of pages from the Swiss newspaper Neue Zurcher Zeitung [28]. Finally, the third dataset used is the BHN, proposed in this paper and already explained in Section 2.1. \begin{table}
\begin{tabular}{c c c c c} \hline \hline \multirow{2}{*}{**Dataset**} & \multicolumn{4}{c}{**Images**} & \multirow{2}{*}{**Pages**} \\ \cline{2-2} \cline{4-5}  & **Quality** & & **DPI** & **Format** \\ \hline BlaLet GT & Gray & 224–521 & TIFF & 167 \\ GBN & Bitonal & 300 & PNG & 152 \\
**BHN (Our)** & RGB & 96 & PNG & 140 \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Characteristics of the datasets selected. Figure 2: BHN dataset image markings, showing: (**a**) Source image; (**b**) Ground truth, where the purple bounding box indicates the text class, the green color indicates the graphic class and the red color indicates the separator class. The selected datasets feature images with a similar layout style, consisting of scanned pages from newspapers which were printed between the 18 th and 20 th centuries. In addition to the images, the datasets have the GT, which consists of annotations of the coordinates of each piece of content on the pages. Once these datasets had been selected and organized, the three sets were merged to form a single dataset with 459 images of historical newspapers, 321 of which were for training (70%), 69 for validation (15%) and 69 for testing (15%). The procedure of combining the datasets and separating them into training, validation and test data was also done using roboflow. The Figure 3 shows some examples of images from the final dataset. The original datasets comprised the classes Text, Image, Graphic, Table, and Separator. In the experiments, we disregarded the separator category in the final dataset, as it does not hold significant information for understanding the document. The Table 2 shows the classes evaluated and the number of instances of each class. It can be seen that the distribution of classes is unbalanced, where the majority classes are Text and Graphic, with a greater number of instances, and the minority classes are Table and Image. The markings were revised to correct incorrect bounding boxes at the end of the process.