A machine vision-based unmanned aerial vehicle power material inventory method

CN123016261APending Publication Date: 2026-10-30HANGZHOU FANSHENG TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611206293.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-10
Publication Date
2026-10-30

AI Technical Summary

Benefits of technology

本发明中,通过像素亮度差异与邻接关系构建连续区域边界,使标识区域保持稳定空间形态并减少边界断裂干扰,通过轮廓间距变化划分区段,使字符集合形成有序分布结构,通过字段位置偏移方向划分同向区段与交替区段,使字段顺序在倾斜或错位情况下保持一致,通过路径连接关系完成编号拼接,使字段内容形成连续关联链路,通过编号与位置信息联合约束及重复识别规则,使同批次数据在时间与空间维度保持一致,从而增强编号构建稳定性与空间对应能力。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123016261A_ABST
    Figure CN123016261A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of intelligent power material management, and discloses a method for checking power materials by using an unmanned aerial vehicle based on machine vision, which comprises the following steps: acquiring an inspection image, extracting brightness changes, constructing a continuous region boundary, forming a coordinate set, dividing a character section based on the contour interval, merging the character section into a field distribution set, correcting the sequence based on the field position offset relationship, forming a field sequence, connecting and extracting the field content along a path, splicing the field content to form numbering information, associating the numbering information with position information, eliminating repeated items, and forming a checking result. The application constructs a continuous region boundary through pixel brightness differences and adjacency relationships, divides a section through contour interval changes, divides same-direction and alternate sections through the field position offset direction, completes sequence correction, splices field content to form numbering through a path connection relationship, and jointly restricts numbering and position information and performs repeated identification, so that the data is consistent in time and space dimensions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent management technology for power materials, and in particular to a machine vision-based method for inventorying power materials using unmanned aerial vehicles (UAVs). Background Technology

[0002] The field of intelligent management technology for power materials includes the identification, collection, recognition, location recording, and status registration of power equipment and materials. Its core focuses on the consistency and traceability of information of power materials during warehousing, inspection, transportation, and on-site use. It involves specific steps such as defining the material appearance coding structure, identification carrier deployment, image acquisition path planning, recognition results, and the corresponding verification of ledger data. By uniformly describing the composition of material number fields, appearance feature combination forms, and spatial distribution relationships, a material information organization and verification system for power scenarios is formed.

[0003] Among them, the machine vision-based drone power material inventory method refers to the processing method of performing inventory operations by drone equipment and completing material verification by combining image recognition. Its technical aspects include the drone flying in the order of warehouse coordinates and acquiring material images to record the location and time information, dividing the material identification coding area in the image into segments, extracting the character content of each field, performing segment matching according to the field arrangement order and establishing a sequential constraint relationship, and registering the complete number obtained by matching with the material ledger number one by one.

[0004] Existing processing relies on field segment matching and sequential correspondence to confirm the numbering, lacking constraints on regional continuity and spatial structure. When the label is damaged or obscured, the character distribution is prone to breakage, leading to unstable field division. For example, when a label is partially missing, adjacent characters are easily misclassified into the same segment. Field order is mainly matched based on a preset structure. When faced with shooting angle deviations or irregular material placement, field positions may shift or overlap, making order determination prone to failure. Number splicing lacks path association constraints, and the connection relationship between fields is unclear, easily resulting in misalignment or missing combinations. At the same time, there is a lack of differentiation mechanism in repeated collection scenarios, with the same material recorded as multiple numbers in different locations, causing inventory data redundancy and chaotic location mapping. Summary of the Invention

[0005] To address the technical problems existing in the prior art, this invention provides a machine vision-based method for inventorying power supplies using unmanned aerial vehicles (UAVs). The technical solution is as follows: A machine vision-based method for inventorying power supplies using drones includes the following steps: S1: Acquire video frames of the drone inspection path, convert the pixel grayscale and extract the brightness, delineate the continuous area based on the brightness difference of the horizontal adjacent pixels, identify the pixel adjacency and remove the interrupted area, extract the pixel coordinates of the contour, and obtain the set of boundary coordinates of the identified area. S2: Extract character outlines based on the boundary coordinate set of the identified area and expand them horizontally. The spacing between adjacent outlines forms a sequence. The position is determined according to the difference in adjacent spacing. The horizontal distribution is divided into segments. The characters in each segment are merged according to the boundary contact to obtain the field segment character distribution set. S3: Based on the character distribution set of the field segment, extract the pixel coordinates of each field to form a field sequence. The order of the material code field is compared with the field sequence bit by bit. The consistent outline and overlapping pixels are the alignment points. The starting pixel of the unaligned field is compared with the previous field according to the horizontal displacement change. The same direction offset is divided into the same direction segment, and the direction change is divided into the alternating segment. The field of the same direction segment is horizontally shifted and mapped to the starting pixel. The field of the alternating segment is horizontally shifted and the range is defined to obtain the field order correction result. S4: Based on the field order correction results, extract the field content to form an identification sequence and expand it horizontally. Compare the identification sequence with the code segment by segment. If the outline is consistent and the pixels overlap, use the matching point to determine the starting position. Connect the starting pixels of all fields in the horizontal direction to form a path connection sequence. Extract the field content along the path and splice it to obtain the material inventory number information. S5: Based on the material inventory number information and the drone location information, the numbers are associated. The numbers in the same batch are compared one by one. Duplicate items are identified if the outlines are consistent and the pixels overlap. The first number is retained according to the inspection time and duplicate numbers are removed. The associated location information is stored to obtain the visual inventory results of power materials.

[0006] As a further embodiment of the present invention, the boundary coordinate set of the identified area includes the coordinate range of the outer contour of the area, the boundary closure shape identifier, the spatial coverage of the area, and the set of valid area identifiers; the character distribution set of the field segment includes the segment location division identifier, the segment span range, the segment character aggregation unit, and the segment order relationship identifier; the field order correction result includes the field arrangement order identifier, the field segment affiliation identifier, the field alignment benchmark identifier, and the overall field offset status identifier; the material inventory numbering information includes the number character combination content, the number field structure unit, the number sequence order identifier, and the number unique identification identifier; and the visual inventory result of the power materials includes the correspondence between the number and the location, the inventory batch affiliation identifier, the set of valid numbers, and the material spatial distribution information.

[0007] As a further aspect of the present invention, the step of obtaining the coordinate set of the boundary of the identified region is as follows: S101: Acquire images of cable reel identification stickers and insulator packaging box labels collected by the UAV during the inspection of the power storage site along the inspection path, perform grayscale conversion on the video frames, record the pixel row and column positions and pixel brightness status, extract the brightness distribution content in the image area of ​​the identification sticker and packaging box label according to the pixel arrangement order, and obtain the pixel brightness distribution record. S102: Based on the pixel brightness distribution record, the brightness status of the current pixel and the horizontally adjacent pixels are compared point by point along the horizontal direction of the image. The position of the brightness status difference between adjacent pixels is marked. The pixels corresponding to the brightness status difference are merged according to the horizontal coordinate connection relationship. The area range composed of the horizontal brightness change is delineated to obtain the horizontal brightness change area. S103: Based on the horizontal brightness change area, identify the horizontal and vertical adjacency relationships of pixels within the area, mark the interruption positions of the horizontal and vertical adjacency relationships within the area, remove the areas with interrupted adjacency relationships, extract the contours of the retained area boundary pixels according to the continuous connection relationship, and output the pixel coordinate set to obtain the boundary coordinate set of the identified area.

[0008] As a further aspect of the present invention, the step of obtaining the field segment character distribution set is as follows: S201: Based on the boundary coordinate set of the identified area, extract the character pixel connected boundary within the boundary coordinate range, extract the circumscribed contour of the character pixel connected boundary, and expand the character circumscribed contour center pixel coordinate and contour boundary pixel coordinate along the horizontal direction of the image to obtain the character contour horizontal arrangement sequence. S202: Call the character outline horizontal arrangement sequence, extract the center pixel coordinate interval of adjacent character outlines along the horizontal direction of the image, form a spacing sequence according to the horizontal position, compare the horizontal distance change between the current interval and the previous interval item by item, mark the position corresponding to the distance change according to the arrangement order, and obtain the outline spacing change position index. S203: Based on the outline spacing change position index, divide the outer contours of the characters on both sides of the change position into field segments according to the continuous distribution of the horizontal pixel coordinates, filter the contact relationship of the outer contours of adjacent characters in the same segment, merge the contacting characters into a character set and collect them in the order of the segment arrangement to obtain the field segment character distribution set.

[0009] As a further aspect of the present invention, the step of obtaining the field order correction result is as follows: S301: Based on the character distribution set of the field segment, extract the character pixel coordinate distribution in each field and form a field sequence. Extract the field arrangement order from the material coding structure as a reference sequence. Compare the field sequence with the reference sequence according to the horizontal position of the field. Mark the position where the character outline boundary shape is consistent and the pixel coordinates coincide as the alignment start point to obtain the field alignment coordinates. S302: Call the field alignment coordinates, extract the starting pixel coordinates of the field that has not formed an alignment start point and the starting pixel coordinates of the previous field, compare the positional relationship of the starting pixel coordinates item by item along the horizontal direction of the image, compare the offset direction of the starting pixel coordinates of adjacent fields, and mark the offset areas in the same direction and the areas with changed offset directions according to the horizontal position of the field to obtain the offset segment identifier. S303: Based on the offset segment identifier, for the same-direction segment, the overall horizontal position of the field is moved and the starting pixel coordinates of the field are remapped; for the alternating segment, the field boundary is moved horizontally and the character set range is redefined. The remapped starting pixel coordinates of the field and the redefined character set are combined according to the field arrangement order to obtain the field order correction result.

[0010] As a further aspect of the present invention, the step of obtaining the material inventory number information is as follows: S401: Based on the field order correction results, extract the character content of each field, expand the starting pixel coordinates of the remapped field, the redefined character set range and the character outline boundary coordinates along the horizontal direction of the image, compare the arrangement of the character content of adjacent fields in the horizontal position of the field, and collect the corresponding field character content and field segment coordinates to obtain the recognition field sequence. S402: Call the identification field sequence, extract the field segment and field content arrangement rules from the material coding structure, compare the identification field sequence and field content arrangement rules with the field segment positions one by one, compare the overlapping positions of the character outline boundary closing direction and pixel coordinates, mark the positions with consistent boundary directions and overlapping coordinates as matching points and associate them with the field starting position to obtain the field matching starting coordinates; S403: Based on the field matching start coordinates, connect all field start pixel coordinates progressively in the horizontal direction of the image, keep the connection range within the segment corresponding to the field matching start coordinates and form a path relationship, extract the path covering field character content along the path direction, and concatenate the field character content according to the field arrangement order to obtain the material inventory number information.

[0011] As a further aspect of the present invention, the steps for obtaining the visual inventory results of power materials are as follows: S501: Based on the material inventory number information and the location information output during the UAV inspection process, extract the number content, number recognition time, location output time and location coordinates, compare the number recognition time and location output time within the same inspection batch to determine the order of inspection time, and match the number content with the location coordinates associated with the corresponding location output time to obtain the number location mapping relationship. S502: Call the number position mapping relationship to extract the number content, character outline boundary coordinates, pixel coordinate positions and associated position coordinates within the same inspection batch, compare the correspondence between the number content item by item, compare the shape relationship of the character outline boundary coordinates with the overlap relationship of the pixel coordinate positions, and divide the numbers with the same boundary shape and overlapping coordinate positions into duplicate items to obtain the duplicate number division identifier. S503: Based on the duplicate numbering identifier, extract the associated position coordinates in the mapping relationship between the duplicate item number, the drone inspection time sequence and the number position, filter the duplicate items whose inspection time sequence is the first number, remove the mapping items corresponding to subsequent duplicate numbers, and store the retained numbers and associated position coordinates according to the inspection batch to obtain the visual inventory results of power materials.

[0012] The beneficial effects of the technical solutions provided in the embodiments of the present invention include at least the following: In this invention, continuous region boundaries are constructed through pixel brightness differences and adjacency relationships, ensuring a stable spatial form for the identified region and reducing boundary breakage interference. Segments are divided by contour spacing variations, enabling the character set to form an ordered distribution structure. Field position offset directions are used to divide unidirectional and alternating segments, ensuring that the field order remains consistent even when tilted or misaligned. Numbering is completed through path connection relationships, forming a continuous and related link for field content. Through joint constraints of numbering and position information and repetition recognition rules, data in the same batch remains consistent in both time and space dimensions, thereby enhancing the stability of numbering construction and spatial correspondence. Attached Figure Description

[0013] Figure 1 This is a flowchart of the method of the present invention; Figure 2 This is a flowchart illustrating the process of obtaining the boundary coordinate set of the identified region in this invention. Figure 3 This is a flowchart illustrating the process of obtaining the character distribution set of the field segment in this invention. Figure 4 This is a flowchart illustrating the process of obtaining the field order correction results of this invention. Figure 5 This is a flowchart illustrating the process of obtaining inventory number information for the present invention. Figure 6 This is a flowchart illustrating the process of obtaining the visual inventory results of power materials according to the present invention. Detailed Implementation

[0014] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.

[0015] refer to Figures 1 to 6 A machine vision-based method for inventorying power supplies using drones includes the following steps: S1: Acquire images of cable reel markings and insulator packaging box labels collected by the drone during the inspection of the power storage site along the inspection path. Convert the video frames to grayscale and extract brightness information pixel by pixel. Compare the brightness values ​​of the current pixel with the horizontally adjacent pixels point by point and delineate the continuous distribution area formed by the brightness change. Identify the horizontal and vertical adjacency relationships of pixels in the area and remove the areas with interrupted adjacency relationships. Extract the contour closure of the retained area boundary and output the pixel coordinate set to obtain the boundary coordinate set of the marking area. S2: Extract the character outline based on the boundary coordinate set of the identifier region and expand it along the horizontal direction of the image. The spacing between the center pixel coordinates of adjacent outlines forms a spacing sequence according to the horizontal position. The relationship between the current interval and the previous interval is compared item by item to define the change position. The outlines on both sides of the change position are divided into different segments according to the continuous distribution of horizontal pixel coordinates. Each segment corresponds to the range of horizontal continuous outlines. The characters in each segment are merged according to the contact relationship of the outline boundary to form a character set, thus obtaining the character distribution set of the field segment. S3: Extract the pixel coordinate distribution of characters in each field based on the character distribution set of the field segment to form a field sequence. The field arrangement order in the material coding structure is used as a reference sequence and compared with the field sequence bit by bit. The position where the character outline boundary shape is consistent and the pixel coordinates coincide is used as the alignment starting point. The position relationship between the starting pixel coordinates of the unaligned field and the starting pixel coordinates of the previous field in the horizontal direction of the image is compared item by item. The area where the starting pixel coordinates of adjacent fields are offset in the same direction is divided into the same direction segment, and the area where the offset direction changes is divided into the alternating segment. The overall horizontal position of the field in the same direction segment is moved and the starting pixel coordinates of the field are remapped. The field boundary in the alternating segment is moved horizontally and the character set range is redefined to obtain the field order correction result. S4: Based on the field order correction results, extract the character content of each field and expand it along the horizontal direction of the image to form a recognition field sequence. Compare the recognition field sequence with the material code field content segment by segment. The positions where the character outline boundary shape is consistent and the pixel coordinates coincide are used as matching points to determine the starting position of the field. All field starting pixel coordinates are progressively connected along the horizontal direction of the image and kept within the same segment to form a path relationship. Extract the field character content along the path direction and splice them to obtain the material inventory number information. S5: Based on the material inventory number information and the location information output during the drone inspection, the number and location information are associated. The correspondence between the number content in the same inspection batch is compared item by item. The numbers with the same character outline boundary shape and overlapping pixel coordinate position are divided into duplicate items. Among the duplicate items, the first number is retained according to the drone inspection time sequence and the subsequent duplicate numbers are removed. The retained numbers are associated with the corresponding location information and stored to obtain the visual inventory results of power materials.

[0016] The set of boundary coordinates for the identified area includes the coordinate range of the outer contour of the area, the boundary closure shape identifier, the spatial coverage of the area, and the set of valid area identifiers. The set of character distribution for field segments includes the segment location division identifier, the segment span range, the segment character aggregation unit, and the segment order relationship identifier. The field order correction results include the field arrangement order identifier, the field segment affiliation identifier, the field alignment benchmark identifier, and the overall field offset status identifier. The material inventory numbering information includes the number character combination content, the number field structure unit, the number sequence order identifier, and the number unique identification identifier. The visual inventory results for power materials include the correspondence between number and location, the inventory batch affiliation identifier, the set of valid numbers, and the material spatial distribution information.

[0017] Please see Figure 2 The steps to obtain the coordinate set of the boundary of the identified region are as follows: S101: Acquire images of cable reel identification stickers and insulator packaging box labels collected by the UAV during the inspection of the power storage site along the inspection path, perform grayscale conversion on the video frames, record the pixel row and column positions and pixel brightness status, extract the brightness distribution content in the image area of ​​the identification sticker and packaging box label according to the pixel arrangement order, and obtain the pixel brightness distribution record. The system retrieves video files from a specified directory on the storage device, reads image data captured by the device along the inspection route for the power storage area, locates and extracts the image with frame number 1500, sets the image size to 1920 pixels wide and 1080 pixels high, and establishes a planar coordinate system. For this frame, the system extracts red, green, and blue channel data one by one. Taking the pixel at coordinates 450 in the X direction and 520 in the Y direction as an example, the corresponding RGB channel values ​​are read as 145, 160, and 130 respectively. The system performs feature dimensionality reduction by introducing a standard weight mapping mechanism for each color channel that conforms to human visual perception, directly obtaining the grayscale value of this point as 152. This mapping transformation is applied to the more than two million pixels in the entire image to construct a grayscale recording matrix. To determine the brightness state binarization parameters, the system extracts the average grayscale values ​​of the effective and background areas from one hundred historical inspection label images. Based on historical statistical averages of 185 and 82, and adding a system ambient light compensation coefficient of 1.1, a baseline threshold of 147 is obtained. The local scanning area is extracted using a matrix, and each point is compared with a set threshold of 147. When the grayscale value of a test point of 152 is greater than the threshold, it indicates that the current point is in a high-brightness state, and its status bit is marked as 1; while when a pixel with a grayscale value of 120 is lower than the threshold, its status bit is marked as 0. The advantage of this method is that by establishing a direct comparison relationship between the preset empirical threshold parameter and the grayscale value of a single pixel, it effectively filters out the color interference caused by sudden changes in ambient light. The above status values ​​are extracted sequentially according to the row priority rule of image storage and collected into a one-dimensional array structure to obtain a pixel brightness distribution record containing row and column coordinates and binary status indicators.

[0018] S102: Based on the pixel brightness distribution record, the brightness status of the current pixel and the horizontally adjacent pixels are compared point by point along the horizontal direction of the image. The position of the brightness status difference between adjacent pixels is marked. The pixels corresponding to the brightness status difference are merged according to the horizontal coordinate connection relationship. The area range composed of the horizontal brightness change is delineated to obtain the horizontal brightness change area. The system retrieves pixel brightness distribution records, locks the specified horizontal and vertical coordinate scanning area, and initiates a row-by-row, column-by-column horizontal state comparison process. It locates the current pixel state and compares it with the states of adjacent pixels on the right to extract edge transition differences. When adjacent pixels transition from state 0 to state 1, the pixel location where the state changes is established as the brightness state difference location. To merge discrete features belonging to the same character stroke, the system sets a horizontal connection distance benchmark of 5 pixels. This parameter is established based on the distribution span of broken strokes and background noise in a large number of actual label samples. The system reads the coordinates of two adjacent difference locations in the horizontal coordinate system and determines whether their horizontal spatial span meets the benchmark requirement. When the horizontal distance between two extracted difference locations is 3 pixels, it meets the merging tolerance condition of no more than 5 pixels, and the system aggregates them into the same connected group. When encountering difference points 8 pixels apart, the aggregation operation is rejected because it exceeds the benchmark span limit, and a new independent group is created for them. The horizontal envelope range formed by nodes with continuous horizontal brightness variations was defined, and the minimum horizontal coordinate (851) and maximum horizontal coordinate (854) within each group were obtained. A set of boundary record parameters characterizing the span of this region was generated. This result demonstrates that the system established the horizontal physical boundary of discrete bright pixels in the image through state difference. Traversing all data points within the processing area completed the range delineation task, yielding the horizontal brightness variation region.

[0019] S103: Based on the horizontal brightness variation area, identify the horizontal and vertical adjacency relationships of pixels within the area, mark the interruption positions of the horizontal and vertical adjacency relationships within the area, remove the areas with interrupted adjacency relationships, extract the contours of the retained area boundary pixels according to the continuous connection relationship, and output the pixel coordinate set to obtain the boundary coordinate set of the identified area.

[0020] The system reads records of horizontal brightness variation areas, extracts coordinate data within the specified area boundaries, and obtains topological information on the horizontally adjacent arrangement of pixels within the area. Simultaneously, the system reads the set of horizontal coordinates of the current row and the corresponding area of ​​the next row on the vertical axis. Based on the intersection of the horizontal coordinates of the two rows, the number of overlapping pixels is determined to be 4, thus indicating a vertical physical adjacency between the two rows. Based on measured statistical data of the gaps between interfering horizontal stripes and valid characters in the image, a threshold of 10 pixels is set to indicate a break in the adjacency relationship. During the vertical downward scanning of ten rows, if it is verified that there are no brightness variation records for 10 consecutive rows (i.e., the cumulative vertical blank span reaches the set threshold of 10 pixels), the position is marked as an inter-row break. This result indicates that the physical continuity of valid pixels within this vertical axis interval has been substantially blocked. After discarding data from the marked break areas, the total number of valid pixels within the retained areas is accumulated to represent the actual area. Based on a preset area threshold parameter of 50 square pixels, small noise areas with a total pixel count lower than this setting are completely eliminated. Extract the outer edge pixels within the reserved area to obtain the boundary coordinate set. Introduce the 8-connected neighborhood determination principle. When adjacent boundary pixels meet the conditions of linear or diagonal proximity, they are considered as continuous connected nodes. Connect these nodes in clockwise geometric order to form a complete contour closed loop. Collect the pixel coordinate parameters on all closed loops, format and encapsulate them for output, and obtain the boundary coordinate set of the identified area.

[0021] Please see Figure 3 The steps to obtain the character distribution set of the field segment are as follows: S201: Based on the boundary coordinate set of the identified region, extract the connected boundary of character pixels within the bounded area of ​​the boundary coordinates, extract the circumscribed contour of the connected boundary of character pixels, and expand the center pixel coordinates of the circumscribed contour and the boundary pixel coordinates of the contour along the horizontal direction of the image to obtain the horizontal arrangement sequence of character contours. The system reads the boundary coordinate set of the identified region, delineates the horizontal and vertical pixel addressing intervals of the target based on the boundary coordinate data, scans the internal connected pixel groups within this interval that conform to the effective brightness marker, and separates the independent character pixel connected boundaries that do not spatially intersect using the morphological region growing principle. For a single character pixel connected boundary, four extreme coordinates representing its minimum bounding rectangle are extracted. Taking connected boundary 1 as an example, its minimum and maximum horizontal boundary coordinates are extracted to be 810 and 830, and its minimum and maximum vertical boundary coordinates are extracted to be 410 and 450, respectively. The center node is then extracted, yielding the horizontal center coordinate of the bounding rectangle to be 820 and the vertical center coordinate to be 430. Similarly, boundary values ​​are extracted for connected boundary 2, obtaining its horizontal center coordinate to be 850 and its vertical center coordinate to be 430. The coordinates representing the geometric center points and the accompanying extreme contour parameters are then expanded and extracted along the extension direction of the image's horizontal coordinate axis. By comparing the center values ​​of the x-coordinates of each connected boundary, and based on the comparison rule that 820 is less than 850, the center coordinates are stored in an ascending order in memory array. This result indicates that a linear topological order has been successfully established for discrete characters within the target region in the horizontal space. The envelope coordinates and ascending order of all connected boundaries are then compiled and output to obtain the horizontal arrangement sequence of the character outlines.

[0022] S202: Call the character outline horizontal arrangement sequence, extract the pixel coordinate interval of the outer contour center of adjacent characters along the horizontal direction of the image, form a spacing sequence according to the horizontal position, compare the horizontal distance change between the current interval and the previous interval item by item, mark the position corresponding to the distance change according to the arrangement order, and obtain the contour spacing change position index. The system retrieves the horizontal arrangement sequence of character outlines and extracts the horizontal center pixel coordinates of the bounding rectangles of adjacent connected boundaries within the sequence. The first, second, and third coordinate values ​​(820, 850, 920, and 950) are read, and the corresponding spacing sequences are calculated to be 30 pixels, 70 pixels, and 30 pixels respectively, based on the distance span between adjacent coordinate parameters. Based on hundreds of test samples, the system identifies a distribution characteristic where the average spacing between closely spaced characters within a field is approximately 20 pixels and the average spacing across fields is approximately 60 pixels. The system sets a baseline reference value of 25 pixels to character abrupt changes in outline spacing. By comparing the numerical change of the current spacing span with the previous spacing span, a difference of 40 pixels is found. This difference is compared to the baseline reference value of 25. Since the actual difference is significantly greater than the set abrupt change baseline value, this result indicates a discontinuity in the horizontal arrangement distance of the character outlines at the corresponding positions in the sequence. The system identifies the location of the jump sequence number as the position corresponding to the field distance change, traverses the entire spacing sequence to complete the check of all jump breakpoints, stores the position sequence number data that meets the jump constraint conditions, and obtains the outline spacing change position index.

[0023] S203: Based on the index of the change position of the outline spacing, divide the outer contour of the characters on both sides of the change position into field segments according to the continuous distribution of the horizontal pixel coordinates. Filter the contact relationship of the outer contour boundary of adjacent characters in the same segment, merge the contacting characters into a character set and collect them in the order of the segment arrangement to obtain the character distribution set of the field segment.

[0024] The system retrieves the outline spacing change position index data, reads the jump position sequence number from the index record, and, based on the continuous distribution pattern of increasing pixel horizontal coordinates, assigns the outer contour group to the left of the jump position to the first independent field segment, and the outer contour group to the right of the jump position to the second independent field segment. Within the same field segment, the extreme coordinates of the smallest outer contour of adjacent characters are extracted to evaluate the contact fusion relationship of their physical boundaries. To quantify this contact relationship and eliminate adhesion interference, the system sets the horizontal coordinate distance judgment threshold to 2 pixels based on the measured statistical data of the overlap between clear character spacing and ink smudging. The maximum horizontal extreme value 830 of the left contour and the minimum horizontal extreme value 840 of the adjacent right contour are read, and the horizontal physical distance between them is found to be 10 pixels. Since this distance is greater than the judgment threshold of 2 pixels, it is determined that the two do not have a boundary contact fusion relationship and maintain their respective independent pixel boundaries; if the measured horizontal physical distance between the subsequent two contours is only 1 pixel, it is determined that the two have a boundary contact fusion relationship. For contours with contact and fusion relationships, the system merges their extreme value parameters to obtain new envelope parameters covering both and updates the corresponding coordinates, forcibly merging them into the same character set. The advantage of this approach is that, through a rigorous horizontal coordinate distance boundary threshold check, it accurately separates the character body from the adhered color blocks caused by environmental factors. By integrating the extreme value distribution parameters of the entire segment's internal character set and completing formatted registration, a field segment character distribution set is obtained.

[0025] Please see Figure 4 The steps to obtain the field order correction results are as follows: S301: Based on the character distribution set of the field segment, extract the pixel coordinate distribution of the characters in each field and form a field sequence. Extract the field arrangement order from the material coding structure as a reference sequence. Compare the field sequence with the reference sequence according to the horizontal position of the field. Mark the position where the character outline boundary shape is consistent and the pixel coordinates coincide as the alignment start point to obtain the field alignment coordinates. The system reads the character distribution set of field segments, extracts the pixel group envelope coordinate data of different segments to construct a field sequence array in a side-by-side data format, calls the internally preset material coding structure file to extract its field length configuration rules, and combines them to generate a standard reference sequence. The first and second parts of the actually extracted field sequence are aligned with the first and second parts of the standard reference sequence in the horizontal mapping array. The character pixel height (40) and width (20) are extracted to obtain the aspect ratio parameter 2.0 representing the geometric shape. Simultaneously, the total area occupied by the effective pixels of the character in the envelope is calculated to obtain the space occupancy parameter 0.75. The above actual feature parameters are combined with the reference aspect ratio 2.1 and reference occupancy rate 0.72 in the standard template parameters and multi-dimensional spatial feature comparison logic for comprehensive judgment, resulting in an Euclidean space difference value of 0.1044 representing the shape similarity between the two. The system sets the consistency distance judgment threshold for extremely close shape representation to 0.2. The comparison shows that the actual difference value is lower than the set threshold, fully meeting the consistency requirements; at the same time, the overlap coverage ratio with the standard grid coordinate system is measured to be 0.85, which is greater than the set overlap safety benchmark value of 0.8. Based on this, the corresponding position is marked as the sequence alignment start point, and its center anchor coordinates 810 and 410 are recorded. This result indicates that the currently extracted image character sequence has a precise and rigid binding relationship with the system's standard reference system in terms of physical shape and spatial positioning. All first and second calibration parameters of the comparison and calibration process are saved to obtain the field alignment coordinates.

[0026] S302: Call the field alignment coordinates, extract the starting pixel coordinates of the field that has not formed an alignment start point and the starting pixel coordinates of the previous field, compare the positional relationship of the starting pixel coordinates item by item along the horizontal direction of the image, compare the offset direction of the starting pixel coordinates of adjacent fields, and mark the offset areas in the same direction and the areas with changed offset directions according to the horizontal position of the field to obtain the offset segment identifier. The field alignment coordinate file record is retrieved, and subsequent associated field data that has not yet formed an alignment match is extracted. The starting horizontal coordinate of the current undetermined outer region is obtained as 920. Simultaneously, the starting horizontal coordinate of the previously associated aligned field as 810 is extracted. The actual relative physical offset between the two is 110 pixels along the horizontal extension direction. The predetermined physical layout specification parameters in the material coding structure are used to set the expected offset baseline value to 100 pixels. The comparison shows that the actual offset value is greater than the expected standard value and the difference is a positive amount of 10 pixels. Therefore, it is determined that the spatial offset direction at this location shows a positive horizontal extension distortion. Further extraction of the subsequent segment coordinate 1050 and the previous segment coordinate 920, and setting the expected baseline span as 150 pixels according to the corresponding coding specifications, shows that the actual measured span distance is 130 pixels, showing a shortfall of 20 pixels. Therefore, it is determined that the spatial offset direction at this location has turned into a negative horizontal contraction distortion. By recording the offsets between each field and the positive and negative marker parameters representing the distortion direction, adjacent segments with the same extension or contraction patterns are divided into continuous offset regions in the same direction. The boundary region between positive and negative transformations is defined as the inflection point region where the offset direction changes. This result indicates that the system has successfully locked the nodes in the target sequence where the spatial distribution trend of each field changes abruptly due to physical factors such as curved surfaces. The above segmentation attributes and distortion differences are recorded completely according to the horizontal numbering position of the sequence to obtain the offset segment identifier.

[0027] S303: Based on the offset segment identifier, for segments in the same direction, the overall horizontal position of the field is moved and the starting pixel coordinates of the field are remapped. For alternating segments, the field boundary is moved horizontally and the character set range is redefined. The remapped starting pixel coordinates of the field and the redefined character set are combined according to the field arrangement order to obtain the field order correction result.

[0028] The method involves calling the offset segment identifier record, extracting the segment information with the same-direction offset label and the horizontal and vertical coordinate parameters of all characters within that segment, and performing a matrix inverse mapping operation to compensate for the overall horizontal reverse displacement based on the positive 10-pixel translation difference of that segment. The original starting horizontal coordinate of 920 is remapped back to 910 due to the compensation effect, and all other coordinate parameters within the segment are simultaneously updated. For alternating segments with labels indicating inflection points of offset direction change, the negative 20-pixel difference is extracted and a horizontal expansion and movement compensation operation is performed, expanding the original right boundary extreme value of the envelope from 1130 to the horizontal axis position of 1150. Simultaneously, the corresponding pixel compensation amount is superimposed on the starting pixel horizontal coordinate of 1050 of the segment, and the remapping yields the calibrated starting horizontal coordinate of 1070. All coordinate data within the segment are then subjected to the same incremental offset processing. The advantage of this method is that by introducing the deviation parameters generated by the previous feature comparison to perform a matrix inverse correction operation, it directly restores the severe spatial distortion caused by the label surface attachment without destroying the internal topology of the characters. The remapping starting coordinates and the redefined character sets are collected sequentially according to the original order of each field to obtain the field order correction result.

[0029] Please see Figure 5 The steps to obtain the inventory number information are as follows: S401: Based on the field order correction results, extract the character content of each field, expand the starting pixel coordinates of the remapped field, the redefined character set range and the character outline boundary coordinates along the horizontal direction of the image, compare the arrangement of the character content of adjacent fields in the horizontal position of the field, and collect the corresponding field character content and field segment coordinates to obtain the recognition field sequence. The system reads the character array set stored in the field order correction results, calls the optical character recognition engine deployed within the system, extracts the stroke topology and edge gradient features of the pixel connected domains within the independent envelope, and performs graphical comparison and matching with the underlying preset standard alphanumeric character dictionary to convert and read the semantic content of the first field "XLPE" and the semantic content of the second field "10KV". It retrieves the starting pixel coordinates and extreme value boundary range coordinates of each field after remapping processing, and unfolds the extracted character text data and corresponding spatial coordinate point columns along the horizontal axis into a one-dimensional comparison structure table. It extracts the updated starting horizontal values ​​810 and 910 in different fields for spatial order comparison, and binds the text entity "XLPE" with its closely linked first segment two-dimensional coordinate parameter group into a combined pair according to the order of coordinate size, and binds the second content "10KV" with the subsequent segment two-dimensional coordinate parameter group into a combined pair. The system verifies the logical matching order and spatial attachment correctness of all entities within the sequence, and stores them as a whole into a new retrieval sequence according to the horizontal positional rules. This result indicates that the pure semantic text extracted by the system visually already possesses accurate two-dimensional spatial anchor point attributes. By summarizing the above structure sequences that have completed the deep binding of spatial location and semantic content, the recognition field sequence is obtained.

[0030] S402: Call the identification field sequence, extract the field segment and field content arrangement rules from the material coding structure, compare the identification field sequence and field content arrangement rules with the field segment positions one by one, compare the character outline boundary closing direction and pixel coordinates, mark the positions with consistent boundary direction and coordinates as matching points and associate them with the field start position to obtain the field matching start coordinates; The system retrieves the semantic content of the first character from the identified field sequence, accesses the material coding structure specification document configured within the device, and verifies that the extracted content "XLPE" falls within the defined range of standard English letters specified in the specification. The normal direction vector of the outer edge pixels of the character is extracted to quantify the closure extension direction of the boundary. This vector is compared with the outward normal vector preset by the standard grid node to verify that its actual closure and expansion direction is completely consistent with the standard system. The remapped starting coordinates 810 and 410 of the sequence are read and their spatial positions are compared with the physical area calibration reference starting points 808 and 412 specified in the specification. The actual Euclidean spatial straight-line error between the two points is approximately 2.828 pixels. The system, considering the average hardware positioning error and camera environmental jitter characteristics, sets the overlap distance threshold to 5 pixels. Since the actual measurement error strictly falls within the threshold control range, it is determined that the currently extracted area boundary achieves precise overlap in both spatial extension direction and physical placement. This result demonstrates that the system successfully identified the optimal fitting point between the coded text and the physical warehouse label grid system. The coordinates corresponding to this high degree of fit were calibrated as the global matching reference point and associated with the depth of the corresponding field's spatial starting point to obtain the starting coordinates for field matching.

[0031] S403: Based on the starting coordinates of the field matching, connect the starting pixel coordinates of all fields progressively in the horizontal direction of the image, keep the connection range within the segment corresponding to the starting coordinates of the field matching and form a path relationship, extract the character content of the path-covered field along the path direction, and concatenate the character content of the field according to the field arrangement order to obtain the material inventory number information.

[0032] The system reads the recorded field matching starting coordinate data group and sequentially extracts the starting pixel coordinates of the first, second, and third fields, which have been calibrated and confirmed. Along the horizontal geometric direction increasing along the x-axis, these isolated spatial pixel coordinates are connected by directed, continuous mathematical line segments, forming a topological line path that runs from beginning to end. Simultaneously, the system strictly limits the activity extension range of this connecting line segment to within the original field segment coordinate boundaries to construct a one-way, forced access mechanism without branching. Following the unambiguous path constructed above, the system sequentially probes into the corresponding field envelope, accurately extracting the three sets of semantic text blocks covered by the path endpoints. According to the physical order of the path connections, the obtained text "XLPE", "10KV", and "001" are forcibly assembled by inserting standard character breakpoints "-" between blocks. The advantage of this method is that by establishing a strongly coupled spatial coordinate directional path access mechanism, it completely avoids the risks of text assembly errors and semantic inversion caused by the overlapping of disordered characters from multiple lines within the same region. Combine and generate a target sequence string that is structurally complete and logically unique to obtain the material inventory number information.

[0033] Please see Figure 6 The steps for obtaining the visual inventory results of power materials are as follows: S501: Based on the material inventory number information and the location information output during the drone inspection process, extract the number content, number recognition time, location output time and location coordinates, compare the correspondence between the number recognition time and the location output time in the same inspection batch, match the number content with the location coordinates associated with the corresponding location output time to obtain the number location mapping relationship. The system retrieves the inventory number information "XLPE-10KV-001" and extracts the time point 10:05:12 from the system operation log where the camera's associated hardware shutter was triggered and completed recognition. Simultaneously, it reads the hardware output time 10:05:15 from the inspection equipment bus, which includes real-time physical 3D spatial positioning coordinates. Comparing the timestamps of these two timestamps reveals an absolute time difference of 3 seconds. Based on the measured characteristics of the response delay of equipment mechanical components and the physical delay of the electromagnetic signal return from the Global Positioning System, a time tolerance benchmark of 5 seconds is set for the associated window within the same inspection batch. Given that the actual hardware time difference is within the specified tolerance benchmark, the system determines that the visual capture action and the spatial coordinate mapping action belong to a closely related real inspection physical event. According to the inspection sequence, the system forcibly binds the acquired material number plain text with the received 3D spatial coordinates, integrating them into a composite data pair with both a timestamp and a spatial absolute positioning anchor point. The system stores the relevant mapping parameter combinations to obtain the number-position mapping relationship.

[0034] S502: Call the number position mapping relationship, extract the number content, character outline boundary coordinates, pixel coordinate position and associated position coordinates within the same inspection batch, compare the correspondence between the number content item by item, compare the shape relationship of the character outline boundary coordinates with the pixel coordinate position overlap relationship, divide the numbers with the same boundary shape and the same coordinate position into duplicate items, and obtain the duplicate number division identifier. The numbering and location mapping record table was retrieved, and the first and second entries in the batch with the content "XLPE-10KV-001" were extracted. The corresponding timestamps were obtained as 10:05:12 and 10:08:20, respectively, each carrying its associated independent three-dimensional spatial coordinates. For the discrete character outline boundary pixel data of these two sets of identical content, their polygon extreme values ​​were extracted, and an area overlap ratio cross-comparison operation was performed. The actual cross-union ratio (CUI) representing the shape similarity between the two was approximately 0.9056. Based on the set contour consistency judgment benchmark parameter of 0.85, representing the homologous features, it was confirmed that the shape features of these two sets of graphics were extremely similar. Further extraction of their physical spatial coordinates and calculation of their spatial straight-line span distance showed it to be 4 meters, meeting the set ten-meter co-location overlap judgment limit. This result indicates that the inspection equipment redundantly recorded the same pile of goods from adjacent physical locations at different times. The system added exclusive classification labels to multiple corresponding records that were confirmed to be physically homologous and met the spatial consistency judgment to delineate duplicate groups, obtaining duplicate number classification labels.

[0035] S503: Based on the duplicate numbering, identify the duplicate item number, extract the associated location coordinates in the mapping relationship between the duplicate item number, the drone inspection time sequence and the number position, filter the duplicate items whose inspection time sequence is the first number, remove the mapping items corresponding to subsequent duplicate numbers, and store the retained numbers and associated location coordinates according to the inspection batch to obtain the visual inventory results of power materials.

[0036] The system retrieves a data list containing duplicate IDs and performs time-series-based redundancy removal on data groups labeled "duplicates." It extracts the time-series codes of all UAV system captures within the same group, compares the values ​​of times such as 10:05:12 and 10:08:20, and determines that the smaller value (10:05:12) occupies the first position on the timeline based on the chronological order of events. The system retains the ID mapping entry with the first time and all its associated 3D spatial physical coordinate parameters, directly cleaning up and removing redundant and duplicate records generated from 10:08:20 and all subsequent times to free up system storage resources. After data purification, the remaining clean material IDs and coordinate parameters without overlap are encapsulated according to the associated batch number and persistently written to the backend database. This generates an output data package with a standard query message format for direct access by upper-level storage equipment, resulting in a visual inventory of power materials.

[0037] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A machine vision-based method for inventorying electrical materials using unmanned aerial vehicles (UAVs), characterized in that, Includes the following steps: S1: Acquire video frames of the drone inspection path, convert the pixel grayscale and extract the brightness, delineate the continuous area based on the brightness difference of the horizontal adjacent pixels, identify the pixel adjacency and remove the interrupted area, extract the pixel coordinates of the contour, and obtain the set of boundary coordinates of the identified area. S2: Extract character outlines based on the boundary coordinate set of the identified area and expand them horizontally. The spacing between adjacent outlines forms a sequence. The position is determined according to the difference in adjacent spacing. The horizontal distribution is divided into segments. The characters in each segment are merged according to the boundary contact to obtain the field segment character distribution set. S3: Based on the character distribution set of the field segment, extract the pixel coordinates of each field to form a field sequence. The order of the material code field is compared with the field sequence bit by bit. The consistent outline and overlapping pixels are the alignment points. The starting pixel of the unaligned field is compared with the previous field according to the horizontal displacement change. The same direction offset is divided into the same direction segment, and the direction change is divided into the alternating segment. The field of the same direction segment is horizontally shifted and mapped to the starting pixel. The field of the alternating segment is horizontally shifted and the range is defined to obtain the field order correction result. S4: Based on the field order correction results, extract the field content to form an identification sequence and expand it horizontally. Compare the identification sequence with the code segment by segment. If the outline is consistent and the pixels overlap, use it as a matching point to determine the starting position. Connect the starting pixels of all fields in the horizontal direction to form a path connection sequence. Extract the field content along the path and splice it to obtain the material inventory number information.

2. The method for inventorying power supplies by UAV based on machine vision according to claim 1 is characterized in that: The set of boundary coordinates of the identified area includes the coordinate range of the outer contour of the area, the boundary closure shape identifier, the spatial coverage of the area, and the set of valid area identifiers. The set of character distribution of field segments includes the segment location division identifier, the segment span range, the segment character aggregation unit, and the segment order relationship identifier. The field order correction result includes the field arrangement order identifier, the field segment affiliation identifier, the field alignment benchmark identifier, and the overall field offset status identifier. The material inventory numbering information includes the number character combination content, the number field structure unit, the number sequence order identifier, and the number unique identification identifier.

3. The method for inventorying power supplies by UAV based on machine vision according to claim 1 is characterized in that: The steps for obtaining the boundary coordinate set of the identified region are as follows: S101: Acquire images of cable reel identification stickers and insulator packaging box labels collected by the UAV during the inspection of the power storage site along the inspection path, perform grayscale conversion on the video frames, record the pixel row and column positions and pixel brightness status, extract the brightness distribution content in the image area of ​​the identification sticker and packaging box label according to the pixel arrangement order, and obtain the pixel brightness distribution record. S102: Based on the pixel brightness distribution record, the brightness status of the current pixel and the horizontally adjacent pixels are compared point by point along the horizontal direction of the image. The position of the brightness status difference between adjacent pixels is marked. The pixels corresponding to the brightness status difference are merged according to the horizontal coordinate connection relationship. The area range composed of the horizontal brightness change is delineated to obtain the horizontal brightness change area. S103: Based on the horizontal brightness change area, identify the horizontal and vertical adjacency relationships of pixels within the area, mark the interruption positions of the horizontal and vertical adjacency relationships within the area, remove the areas with interrupted adjacency relationships, extract the contours of the retained area boundary pixels according to the continuous connection relationship, and output the pixel coordinate set to obtain the boundary coordinate set of the identified area.

4. The method for inventorying power supplies by UAV based on machine vision according to claim 1 is characterized in that: The steps for obtaining the character distribution set of the field segment are as follows: S201: Based on the boundary coordinate set of the identified area, extract the character pixel connected boundary within the boundary coordinate range, extract the circumscribed contour of the character pixel connected boundary, and expand the character circumscribed contour center pixel coordinate and contour boundary pixel coordinate along the horizontal direction of the image to obtain the character contour horizontal arrangement sequence. S202: Call the character outline horizontal arrangement sequence, extract the center pixel coordinate interval of adjacent character outlines along the horizontal direction of the image, form a spacing sequence according to the horizontal position, compare the horizontal distance change between the current interval and the previous interval item by item, mark the position corresponding to the distance change according to the arrangement order, and obtain the outline spacing change position index. S203: Based on the outline spacing change position index, divide the outer contours of the characters on both sides of the change position into field segments according to the continuous distribution of the horizontal pixel coordinates, filter the contact relationship of the outer contours of adjacent characters in the same segment, merge the contacting characters into a character set and collect them in the order of the segment arrangement to obtain the field segment character distribution set.

5. The method for inventorying power supplies by UAV based on machine vision according to claim 1 is characterized in that: The steps for obtaining the field order correction result are as follows: S301: Based on the character distribution set of the field segment, extract the character pixel coordinate distribution in each field and form a field sequence. Extract the field arrangement order from the material coding structure as a reference sequence. Compare the field sequence with the reference sequence according to the horizontal position of the field. Mark the position where the character outline boundary shape is consistent and the pixel coordinates coincide as the alignment start point to obtain the field alignment coordinates. S302: Call the field alignment coordinates, extract the starting pixel coordinates of the field that has not formed an alignment start point and the starting pixel coordinates of the previous field, compare the positional relationship of the starting pixel coordinates item by item along the horizontal direction of the image, compare the offset direction of the starting pixel coordinates of adjacent fields, and mark the offset areas in the same direction and the areas with changed offset directions according to the horizontal position of the field to obtain the offset segment identifier. S303: Based on the offset segment identifier, for the same-direction segment, the overall horizontal position of the field is moved and the starting pixel coordinates of the field are remapped; for the alternating segment, the field boundary is moved horizontally and the character set range is redefined. The remapped starting pixel coordinates of the field and the redefined character set are combined according to the field arrangement order to obtain the field order correction result.

6. The method for inventorying power supplies by UAV based on machine vision according to claim 1 is characterized in that: The steps for obtaining the inventory number information of the materials are as follows: S401: Based on the field order correction results, extract the character content of each field, expand the starting pixel coordinates of the remapped field, the redefined character set range and the character outline boundary coordinates along the horizontal direction of the image, compare the arrangement of the character content of adjacent fields in the horizontal position of the field, and collect the corresponding field character content and field segment coordinates to obtain the recognition field sequence. S402: Call the identification field sequence, extract the field segment and field content arrangement rules from the material coding structure, compare the identification field sequence and field content arrangement rules with the field segment positions one by one, compare the overlapping positions of the character outline boundary closing direction and pixel coordinates, mark the positions with consistent boundary directions and overlapping coordinates as matching points and associate them with the field starting position to obtain the field matching starting coordinates; S403: Based on the field matching start coordinates, connect all field start pixel coordinates progressively in the horizontal direction of the image, keep the connection range within the segment corresponding to the field matching start coordinates and form a path relationship, extract the path covering field character content along the path direction, and concatenate the field character content according to the field arrangement order to obtain the material inventory number information.

7. The method for inventorying power supplies by unmanned aerial vehicles based on machine vision according to claim 1 is characterized in that, The method further includes step S5: S5: Based on the material inventory number information and the drone location information, the numbers are associated. The numbers in the same batch are compared one by one. Duplicate items are identified if the outlines are consistent and the pixels overlap. The first number is retained according to the inspection time and duplicate numbers are removed. The associated location information is stored to obtain the visual inventory results of power materials. The visual inventory results of the power materials include the correspondence between the number and the location, the inventory batch affiliation identifier, the set of valid numbers, and the spatial distribution information of the materials.

8. The method for inventorying power supplies by UAV based on machine vision according to claim 7 is characterized in that: The steps for obtaining the visual inventory results of the power materials are as follows: S501: Based on the material inventory number information and the location information output during the UAV inspection process, extract the number content, number recognition time, location output time and location coordinates, compare the number recognition time and location output time within the same inspection batch to determine the order of inspection time, and match the number content with the location coordinates associated with the corresponding location output time to obtain the number location mapping relationship. S502: Call the number position mapping relationship to extract the number content, character outline boundary coordinates, pixel coordinate positions and associated position coordinates within the same inspection batch, compare the correspondence between the number content item by item, compare the shape relationship of the character outline boundary coordinates with the overlap relationship of the pixel coordinate positions, and divide the numbers with the same boundary shape and overlapping coordinate positions into duplicate items to obtain the duplicate number division identifier. S503: Based on the duplicate numbering identifier, extract the associated position coordinates in the mapping relationship between the duplicate item number, the drone inspection time sequence and the number position, filter the duplicate items whose inspection time sequence is the first number, remove the mapping items corresponding to subsequent duplicate numbers, and store the retained numbers and associated position coordinates according to the inspection batch to obtain the visual inventory results of power materials.