## 2 Materials and Methods
### Model Construction  
The construction of the model and the arrangement of the final layers were carried out to create a structure that integrates deep learning and quantum layers. This model was built on a pretrained ViT-based architecture. This architecture is based on a transformer structure successfully used in image processing and deep learning tasks, with the capacity to process data with high accuracy. Using the statement timm.create_model('cait_s24_224', pretrained = True), a pretrained ViT model was loaded, and its input features were adapted for image classification tasks. The ViT operates by dividing an image into fixed-size patches and processing these patches as sequences, similar to words in natural language processing. Mathematically, an input image is divided into patches. Each patch is then linearly embedded into a vector and augmented with positional encodings to retain spatial information. The ViT model processes these embeddings using self-attention mechanisms, computed as follows:  
\[\text{Attention}(\text{Q},\text{K},\text{V})=\text{softmax}\left(\frac{\text{ QK}^{\text{T}}}{\sqrt{\text{d}_{\text{K}}}}\right)V \tag{5}\]  
where Q, K, and V are the query, key, and value matrices derived from the input embeddings, and d\({}_{\text{K}}\) is the dimensionality of the key vectors. This mechanism allows the model to focus on different parts of the image to learn complex patterns [28]. The CaiT (Class-Attention in Image Transformers) model is an extension of the ViT, designed to improve the convergence and performance of transformers in image classification tasks. The CaiT introduces class-attention layers that separately process the class token, enabling the model to focus specifically on classification-related features. This is mathematically represented as follows:  
\[ClassAttention(\text{Q}_{\text{c}},\text{K},\text{V})=\text{softmax}\left(\frac{ \text{Q}_{\text{c}}\text{K}^{\text{T}}}{\sqrt{\text{d}_{\text{K}}}}\right)V \tag{6}\]  
where \(\text{Q}_{\text{c}}\) is the class token query and K and V are the key and value matrices from the patch embeddings. These additional layers allow the CaiT to refine the class-specific representations and achieve higher accuracy on image classification benchmarks [29]. The output features of the deep learning structure were adjusted in a multi-layer fully connected layer sequence to suit the DressedQuantumNet class. During this arrangement, fully connected layers of various dimensions were added sequentially and supported with ReLU activation functions. In this layer structure, the 1000-dimensional feature vector from the deep learning model was reduced to dimensions of 512, 256, 128, and 64, respectively. This process preserves the overall structure of the model while extracting smaller, meaningful features. After these stages, the data are transferred to the DressedQuantumNet class and processed with quantum operations. In the model, the final layers of the loaded Vision Transformer architecture were replaced with the DressedQuantumNet class. This class was designed to integrate quantum computing layers with classical deep learning layers to process data in a more complex structure. Replacing the final layers of the model was carried out with the aim of creating a new classifier suitable for its task. After the final layer adjustments, the model was loaded onto a CUDA or CPU device as appropriate. During the model construction phase, path parameters were defined for directories where the final model would be saved and for paths to save the intermediate outputs of the model. This configuration allows the model to retain its state after each step in the training process and continue from where it left off when needed. With the final layer adjustments, the Vision Transformer-based model was made capable of analyzing data within multidimensional relationships through the combination of classical and quantum layers.