## 2 Materials and Methods
### Dataset and Preprocessing  
A large publicly available dataset was selected to train the BRAU-Net++ neural network for the segmentation task required for automatic VBQ determination. The dataset consists of 447 sagittal T1 and T2 MRI series from 218 studies of 218 patients acquired at four different hospitals. All patients had a history of low back pain. The quality and dimensions of these images vary between series, with voxel sizes ranging from 3.15 \(\times\) 0.24 \(\times\) 0.24 mm to 9.63 \(\times\) 1.06 \(\times\) 1.23 mm. Segmentation of the visible vertebrae (except the sacrum), intervertebral disks (IVDs) and spinal canal was performed using a semi-automated segmentation method. First, 20 randomly selected high-resolution series were chosen for manual segmentation. For the other image series, the segmentations were performed using an iterative automatic segmentation method. The first segmentations were performed using an automatic method that was trained with data from manually segmented image series. New segmentations (annotations) were then manually corrected and added to the training dataset. This process was repeated four times. Figure 1 shows a diagram of the annotation process [21]. Before this dataset was used to train the BRAU-Net++ neural network, several preprocessing steps were carried out. Since the signal intensity of the IVDs was not required for VBQ determination, all segmentations of the IVDs were removed from the segmentation masks in the dataset to improve the training performance of the network and shorten the training time. The segmentation masks were left with 9 classes: the L1-L5 vertebrae (numbered 1 to 5), the Th10-Th12 vertebrae (numbered 6 to 8) and the spinal canal (numbered 9). Figure 2 shows an example of a mid-sagittal slice image from a series and the corresponding segmentation mask. The intensity values of the MR images were then rescaled to values between 0 and 1 in order to obtain uniform value ranges for the different series. All images and segmentation masks were rescaled to a size of 224 \(\times\) 224 pixels. From the dataset, 20% of the randomly selected series were used as test data and 10% were randomly selected as validation data. The data used for training were saved in.npz format from the Numpy package for scientific computing in Python. The test and validation datasets were saved in HDF5 format from the h5 py Python package. This was carried out to adapt the dataset to the form of the Synapse dataset used in the original BRAU-Net++ training, which facilitates the process of neural network training [20]. All preprocessing steps were coded in the Python (version 3.9.12.) programming language. Although only T1-weighted image series are required for VBQ determination, the neural network was trained with both T2- and T1-weighted data. T2-weighted images of the spine have a hyperintense signal in the spinal canal where the CSF  
Figure 1: Diagram of the iterative annotation process [21]. Figure 2: (**a**) Mid-sagittal slice of T1-weighted lumbar spine image series; (**b**) corresponding segmentation mask with pixel values ranging from 0 to 9.  
is located in relation to the neural tissue. In contrast, T1-weighted images of the spine tend to have lower signal intensity differences between the CSF and neural tissue in the spinal canal. For this reason, T2-weighted images may be useful for segmenting the CSF from the spinal canal masks. Another MRI dataset was randomly selected from the database of the University Hospital Rijeka, Croatia. It consists of 166 image series, 83 T1-weighted and 83 T2-weighted lumbar spine MRI data from 83 studies of 83 patients, all acquired using a 1.5T MRI device (Siemens Magnetom Aera, Siemens Healthineers, Erlangen, Germany). The T1- and T2-weighted data are available in pairs for each study (each patient). This dataset was selected to determine whether four different methods of VBQ determination showed statistically significant differences from each other.