The same is true for hardware and software intended directly for the monitoring process. Therefore, in this work, the adaptation of active sensing using LIF spectroscopy and passive sensing, which is based on the analysis of an optical image of oil product slicks on the sea surface, to a specialized carrier, i.e., a drone, was carried out. The drone itself was also designed for autonomous monitoring of marine pollution using the optical sensing method. The article includes the following sections: Section 2 describes the results of the development of HSFW1--passive optical monitoring. Section 3 presents the main results of the development of HFSW2 and the LIF spectroscopy method for determining the types of oil products in slicks and solutions, as well as measuring the concentration of solutions of oil products contained in seawater using a drone. Section 3 shows the design and parameters of the laser LIF spectrometer for a drone. A short overview of the works in which the LIF spectroscopy method was used for monitoring water areas on drones is given. Section 4 describes the basic principles of developing the navigation and flight control sub-framework--HSFW3. The main characteristics of a specialized drone, which was developed specifically for the mission of monitoring oil pollution at sea, are presented. Section 5 is a description of the structure and principles for the development of the HSFW complex. Section 6 contains descriptions of the main results obtained from testing the HSFW and discusses the results. Section 7 is the conclusion. Hardware and Software Sub-Framework for Passive Optical Sensing of Oil Slicks on the Sea Surface (HSFW1)  
The hardware part of the offshore oil slick monitoring sub-framework (HSFW1) includes a video camera and a computer. The software part of the HSFW1 consists of an AI detection element, which only detects the presence of a slick on the sea surface, and an AI element of segmentation and classification of slick, allowing the slick to be classified on the basis of a certain oil appearance code, thus enabling an estimation of the slick thickness. The first element is applicable to all slicks regardless of their thickness, including crude oil slicks. The second element works only with thin slicks of oil products. The learning procedure for the first element was carried out on real images of slicks of oil products obtained at different periods when monitoring real pollution using a drone. The Python programming language was used to create this software component. A library of computer vision algorithms, image processing, and general-purpose numerical algorithms with open-source OpenCV was used to work with images. The neural network architecture YOLOv3-tiny [19], implemented using the Keras library with the Tensorflow framework, was chosen as a system with an object detection component. This architecture can be used on low-performance microcomputers such as the Raspberry pi 3, which are quite suitable for a small-sized drone. The performance of this element was tested on real pollution in Peter the Great Bay. The sources of pollution were accidents during bunkering. Figure 1 shows a fragment of the operation of the element for recognizing oil slicks. The element gives the probability that the registered slick is a slick formed by oil products. The probability value for the two slicks is shown in the images. In this case, these values are 0.9 and 0.8, interpreted as slicks of oil products. During the learning, the detection criterion was used; thus, the slick was fixed on the sea surface at a probability value of 0.65. The element can estimate the area of pollution after detecting a slick formed by oil products on the sea surface. It should be noted that we did not have a sufficient number of images of crude oil slicks on the sea surface. Therefore, the dataset for learning the neural network to detect crude oil slicks contained a small number of slick images.