## 3 AI, DL and Computer Vision in UAV Sensing
### Deep Learning and Computer Vision  
Computer vision is the field of artificial intelligence that enables computer systems to extract important information from visual inputs such as images and videos and respond accordingly. Machine vision uses AI to allow computers to perceive, observe, and understand their surroundings. Image processing is used to automate tasks that the human visual system can perform. To work properly, computer vision requires a large amount of data, as it analyzes these data to identify and recognize specific inputs, such as frames or images. To instruct a computer on identifying automobiles, it requires a substantial amount of car illustrations to enable it to acquire the ability to distinguish and discern cars, including those that are free from any physical impairment or blemish [22]. Neural networks (NNs) are machine learning techniques that are influenced by biological neural networks. NNs use nodes (also known as neurons) to transmit information in the same way as human bodies do. The most frequent type of NN in UAV technology is the convolutional neural network (CNN). CNNs are a particular kind of NN that is designed for the exclusive purpose of identifying images. Convolution, as the title suggests, is the technique through which the initial image at the input of a machine vision application is altered with filters that identify significant image features like boundaries (Figure 2). The system shall acquire knowledge about the screened data it identifies independently and correspond it with the anticipated result. A distinguishable instance is identifying the label of an entity in a specific picture that serves as an input. Typically, filters consisting of 3 \(\times\) 3 or 5 \(\times\) 5 squares are employed to detect the orientation of the boundary or characteristic: leftward, rightward, upward, or downward. Deep artificial neural networks frequently acquire more efficient data representations than shallow ones. Nevertheless, incorporating many layers in a CNN can lead to the problem of vanishing or exploding gradients, which can make optimization challenging [23]. In reality, the back-propagation technique is utilized to comprehend the significance of the filter parameters' weights utilized in the convolution process. The utilization of an activation function is a crucial step in the convolution procedure. Within a neural network, activation functions determine how the input's weighted sum is transformed into an output from a node or group of nodes in a specific layer of the network. Figure 2: Training process of a CNN [24]. Although there are diverse options for activation functions, the non-linear function ReLU (Rectified Linear Unit) is the most commonly employed [23, 25]:  
\[\sigma(x)=max(0,x) \tag{1}\]  
_Tanlt_:  
\[\sigma(x)=\frac{e^{x}-e^{-x}}{e^{x}+e^{-x}} \tag{2}\]  
and _Sigmoid_:  
\[\sigma(x)=\frac{1}{1+e^{x}} \tag{3}\]  
Non-linear activation functions are especially suitable for constructing multi-layer artificial neural networks as they can consistently approximate all functions, as demonstrated by the universal approximation theorem. The ReLU function is particularly favored in unmanned aerial vehicle applications owing to its uncomplicated mathematical expression and derivative:  
\[f(x)= \begin{cases}x,&\text{if }x>0\\ 0,&\text{if }x\leq 0\end{cases}  \tag{4}\]  
\[f^{\prime}(x)= \begin{cases}1,&\text{if }x>0\\ 0,&\text{if }x<0\\ \text{undefined},&\text{at }x=0\end{cases}  \tag{5}\]  
The ReLU activation function is effective in preventing the vanishing gradient problem that can occur during the training of a neural network. In this process, the weight of each layer receives an update based on the error function. Pooling layers, such as max-pooling layers, are frequently placed between two convolutional layers to minimize the spatial volume of the input image. The max-pooling layer has no parameters; however, it does have two hyper-parameters: the filter (\(F\)) and the stride (\(S\)).