Camera frustum voxel discretization method based on ppm threshold and voxel efficiency factor

CN122906142APending Publication Date: 2026-10-13HARBIN INSTITUTE OF TECHNOLOGY (SHENZHEN) (INSTITUTE OF SCIENCE AND TECHNOLOGY INNOVATION HARBIN INSTITUTE OF TECHNOLOGY SHENZHEN)
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611407925.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-11
Publication Date
2026-10-13

AI Technical Summary

Technical Problem

[0005]因此,现有技术虽然分别具备连续视锥建模、像素密度规划和三维体素化等技术手段,但这些手段多服务于各自场景,缺少面向相机视锥离散化的一体化方法

Benefits of technology

(1)通过计算阈值距离,能够根据PPM阈值准确确定视锥的有效深度,为后续体素离散提供了精确的几何范围依据。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122906142A_ABST
    Figure CN122906142A_ABST
Patent Text Reader

Abstract

The application discloses a camera view frustum voxel discretization method based on a PPM threshold and a voxel efficiency factor, and comprises the following steps: calculating a threshold distance according to camera imaging parameters and a PPM threshold; establishing a local view frustum coordinate system, and determining a candidate voxel range based on the threshold distance, the camera imaging parameters and a candidate voxel size; projecting a vertex of each candidate voxel in the candidate voxel range to the local view frustum coordinate system, and screening out a discrete view frustum voxel set; dividing the discrete view frustum voxel set into an internal voxel set and an edge voxel set, calculating a voxel efficiency factor to correct the area contribution of the edge voxel, and obtaining a discrete area estimation value; and selecting a voxel size meeting an error requirement from the candidate voxel size based on the error between the discrete area estimation value and a continuous theoretical area. The application can generate a stable, accurate and comparable discrete view frustum voxel set under different camera parameters, PPM thresholds and voxel sizes, and provides a reliable basic input for subsequent space calculation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer vision technology, and in particular to a camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor. Background Technology

[0002] Camera frustums are fundamental geometric objects in 3D graphics, computer vision, and visual simulation systems. Existing graphics rendering and simulation platforms typically construct continuous frustums based on camera pose, field of view, near clipping plane, and far clipping plane, and use them for frustum clipping, object culling, rendering range determination, or geometric representation of the visible region. These methods focus on determining whether an object is within the frustum or needs to be rendered; they generally do not require converting the frustum itself into a 3D discrete set with a uniform voxel scale that can be stored and queried in batches.

[0003] In video surveillance, machine vision, and imaging system planning, existing solutions often use pixels per meter (PPM) or similar metrics to evaluate imaging resolution at different distances, and divide the effective distance or working area according to task levels such as detection, observation, recognition, and confirmation. While these solutions can indicate whether an image at a certain distance meets the requirements of a specific observation task, they typically remain at the level of two-dimensional imaging quality or distance partitioning, without providing a standardized calculation process for discretizing the three-dimensional frustum range determined by the PPM threshold into a set of voxels.

[0004] In the field of 3D data processing and spatial indexing, voxelization techniques are commonly used to convert existing 3D geometric data such as point clouds, triangular meshes, solid models, or depth maps into regular voxel meshes. These methods focus on the occupancy of the processed object itself, surface sampling, or spatial indexing efficiency. Voxel sizes are generally set by engineering experience, storage budget, or algorithm resolution. For open geometric ranges such as camera frustums, which are jointly defined by imaging parameters and pixel density thresholds, existing general voxelization methods typically do not simultaneously handle threshold distance calculation, layer-by-layer frustum filling, edge voxel fraction correction, and scale error evaluation.

[0005] Therefore, while existing technologies possess techniques such as continuous frustum modeling, pixel density planning, and 3D voxelization, these techniques primarily serve their respective scenarios and lack an integrated approach for camera frustum discretization. Especially when continuous frustums are required as input for subsequent spatial calculations, existing methods often rely on manually setting the truncation distance and mesh resolution, and frequently handle voxels crossed by the frustum boundary by either accepting or discarding all voxels. This makes it difficult to guarantee the reproducibility and comparability of discretization results under different camera parameters, different PPM thresholds, and different voxel scales.

[0006] The above background information is provided only to aid in understanding the concept and technical solution of this invention. It does not necessarily belong to the prior art of this patent application. In the absence of clear evidence that the above information was disclosed on the filing date of this patent application, the above background information should not be used to evaluate the novelty and inventiveness of this application. Summary of the Invention

[0007] To address the aforementioned technical issues, this invention proposes a camera frustum voxel discretization method based on a PPM (Pixels Per Meter) threshold and a voxel efficiency factor. Given camera imaging parameters, a PPM threshold, and candidate voxel scales, the continuous camera frustum is converted into a discrete voxel set. Furthermore, during the discretization process, edge voxels are corrected with fractional weights, and an error index is used to determine a suitable grid scale.

[0008] To achieve the above objectives, the present invention adopts the following technical solution: In a first aspect, the present invention discloses a camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor, comprising the following steps: S1: Calculate the threshold distance based on the camera imaging parameters and the PPM threshold; S2: Establish a local frustum coordinate system, and determine the candidate voxel range based on the threshold distance, camera imaging parameters, and candidate voxel size; project the vertex of each candidate voxel within the candidate voxel range onto the local frustum coordinate system, and filter out a discrete frustum voxel set according to the relationship between the vertex of each candidate voxel and the frustum boundary surface; S3: Divide the discrete frustum voxel set into internal voxels and edge voxels, and calculate the voxel efficiency factor to correct the area contribution of edge voxels, so as to obtain the discrete area estimate. S4: Based on the error between the discrete area estimate and the continuous theoretical area, select the voxel scale that meets the error requirement from the candidate voxel scales.

[0009] Preferably, the threshold distance calculated in step S1 is:

[0010] In the formula, Indicates the first The threshold distance corresponding to each PPM threshold, where L is the camera focal length. For pixel size, For the first Each PPM threshold.

[0011] Preferably, the establishment of the local frustum coordinate system in step S2 specifically includes: establishing a local frustum coordinate system with the camera viewpoint as the origin and the viewing axis direction as the depth axis based on the camera pose parameters.

[0012] Preferably, determining the candidate voxel range in step S2 based on the threshold distance, camera imaging parameters, and candidate voxel size specifically includes: Using the camera viewpoint as the near-end reference point of the view cone, and the far-end section at a distance from the threshold along the visual axis as the far-end boundary of the view cone; Calculate the dimensions of the distal boundary of the visual cone based on the threshold distance and the field of view angle; By combining the local frustum coordinate system, the coordinate range of the near-end reference point of the continuous frustum and the corner point of the far-end boundary of the frustum in the global coordinate system can be obtained; The coordinate range is adjusted according to the candidate voxel size to form a candidate voxel bounding box that can cover continuous view frustums, which serves as the candidate voxel range.

[0013] Preferably, in step S2, the vertices of each candidate voxel within the candidate voxel range are projected onto the local frustum coordinate system, and a discrete frustum voxel set is selected based on the relationship between the vertices of each candidate voxel and the frustum boundary surface. Specifically, this includes: Project the vertices of each candidate voxel within the candidate voxel range onto the local frustum coordinate system to obtain the local coordinates of the vertices of each candidate voxel; based on the positional relationship between the local coordinates of the vertices of each candidate voxel and the boundary surfaces of each frustum determined by the threshold distance and the field of view angle, determine whether the candidate voxel intersects with the continuous camera frustum, and include all intersecting candidate voxels into the discrete frustum voxel set.

[0014] Preferably, determining whether a candidate voxel intersects with the continuous camera view frustum based on the positional relationship between the local coordinates of the vertices of each candidate voxel and the boundary surfaces of each view frustum specifically includes: If all vertices of a candidate voxel are located outside any side of the interface of the view frustum, then the candidate voxel is determined not to intersect with the view frustum of the continuous camera; otherwise, the candidate voxel is determined to intersect with the view frustum of the continuous camera.

[0015] Preferably, step S3 specifically includes: The discrete frustum voxel set is projected onto the geometric evaluation projection plane to generate a two-dimensional occupancy map. The occupancy units in the two-dimensional occupancy map are divided into internal voxel sets and edge voxel sets by morphological erosion operation. The geometric evaluation projection plane is the plane where the far end section of the continuous camera frustum is located and / or the lateral projection plane formed by the lateral boundary of the continuous camera frustum. Based on the internal voxel set and the edge voxel set, a voxel efficiency factor is calculated, which is used to weight and correct the area contribution of the edge voxels. Based on the voxel efficiency factor, the internal voxel set, and the edge voxel set, calculate the discrete area estimate of the discrete frustum voxel set on the geometric evaluation projection plane.

[0016] Preferably, the voxel efficiency factor calculated in step S3 for:

[0017] In the formula, Let be the theoretical geometric area of ​​the continuous view cone projected onto the geometric evaluation plane. For the number of edge voxels, For the number of internal voxels, Let be the voxel side length.

[0018] Preferably, in step S4, the error between the corrected discrete area and the continuous theoretical area is used. for:

[0019] In the formula, Voxel efficiency factor For the number of edge voxels, For the number of internal voxels, Let the voxel side length be , Let be the theoretical geometric area of ​​the continuous view cone projected onto the geometric evaluation plane.

[0020] In a second aspect, the present invention discloses a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the camera frustum discretization method described in the first aspect.

[0021] Compared with existing technologies, the advantages of this invention are as follows: By incorporating camera imaging parameters, PPM threshold, pose parameters, and candidate voxel scales into a unified calculation process, this invention achieves a standardized conversion from continuous camera frustums to discrete voxel sets. First, a local frustum coordinate system is established based on the camera pose, and voxel affiliation is determined by the projection relationship between candidate voxel vertices and the frustum boundary surface. This eliminates reliance on manual cross-section sampling or empirical projection discarding rules during the frustum discretization process, significantly improving the reproducibility and comparability of the discretization results. Second, by distinguishing frustum voxels into internal and edge voxels and using a voxel efficiency factor to perform fractional weight correction on edge voxels, the area deviation caused by fully selecting or discarding boundary voxels is effectively reduced, improving the estimation accuracy of the discrete area. Finally, by comparing the discretization results under different candidate voxel scales through discretization error comparison, and combining error requirements and computational requirements to select the voxel scale, the mesh scale selection is transformed from an empirical setting into a quantifiable error constraint problem, reducing uncertainty and improving the practicality and reliability of the method. The synergistic effect of these technical features enables the present invention to generate stable, accurate and comparable discrete frustum voxel sets under different camera parameters, PPM thresholds and voxel scales, providing a reliable basic input for subsequent spatial calculations.

[0022] In a further embodiment, the present invention also has the following beneficial effects: (1) By calculating the threshold distance, the effective depth of the view cone can be accurately determined based on the PPM threshold, providing a precise geometric range basis for subsequent voxel discretization.

[0023] (2) By establishing a local view frustum coordinate system and projecting the candidate voxel vertices onto this coordinate system, the view frustum voxel discretization of any pose camera is realized, which enhances the versatility and applicability of the method.

[0024] (3) By distinguishing between internal voxels and edge voxels through morphological erosion operations and combining voxel efficiency factors for area correction, the accuracy and reliability of discrete area estimation are further improved.

[0025] (4) Through the discrete error calculation and voxel scale selection mechanism, the method can automatically select the appropriate voxel scale according to the actual application requirements, thus balancing computational efficiency and discrete accuracy.

[0026] Other beneficial effects of the embodiments of the present invention will be further described below. Attached Figure Description

[0027] Figure 1 This is a schematic diagram of the camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor disclosed in a preferred embodiment of the present invention. Figure 2 This is a schematic diagram showing the relationship between camera imaging geometry and PPM threshold distance.

[0028] Figure 3 This is a schematic diagram of continuous view cone pixel discretization.

[0029] Figure 4a This is a schematic diagram of the 3D frustum range of a camera, which is a set of discrete frustum voxels. Figure 4b This is a schematic diagram of the projection range of the discrete set of frustum elements in the xz-axis view; Figure 4c This is a schematic diagram of the projection range of the discrete set of frustum elements in the yz-axis view; Figure 5a This is a comparison chart of estimation errors of the projected area of ​​the far-end section at different candidate voxel scales; Figure 5b This is a comparison chart of the estimation errors of the lateral projected area at different candidate voxel scales. Detailed Implementation

[0030] The embodiments of the present invention will be described in detail below. It should be emphasized that the following description is merely exemplary and not intended to limit the scope and application of the present invention.

[0031] In continuous view frustum modeling and clipping schemes, the system typically first reads parameters such as camera position, orientation, horizontal field of view, vertical field of view, near clipping plane, and far clipping plane to establish a continuous view frustum geometry bounded by several planes. Then, by using the relationship between points, bounding spheres, bounding boxes, or projection ranges and the view frustum plane, it determines whether the tested element is located within the view frustum. The output of this type of scheme is usually a "into / out-of-view frustum" judgment result or a continuous geometric range, rather than a discrete set of view frustums expressed at a uniform voxel scale.

[0032] In pixel density distance planning schemes, the system calculates the pixel density (PPM) at different distances based on camera focal length, sensor size, pixel size, image resolution, or field of view width. The PPM is then compared with thresholds for tasks such as detection, observation, identification, and confirmation to obtain the maximum distance or working range corresponding to each task level. This type of scheme primarily addresses the correspondence between image quality and distance, and typically does not further process voxel filling and boundary discretization within the 3D view frustum.

[0033] In empirical sampling or projected mesh schemes, when the view frustum needs to be used for spatial calculations, engineering implementations may involve truncating multiple field-of-view sections along the camera's optical axis at fixed steps, or projecting the view frustum onto a two-dimensional or three-dimensional regular mesh, and then using the mesh cells where the sampling points fall or intersect as the approximate range of the view frustum. These schemes rely on preset sampling step sizes, cutoff distances, and selection rules, and the discretization results are prone to variation with changes in engineering parameters.

[0034] In general voxelization schemes, for existing 3D geometric data such as point clouds, triangular meshes, solid models, or depth maps, a regular 3D mesh is typically created first. Then, based on whether the geometric data falls into or passes through a certain mesh cell, that mesh cell is marked as an occupied voxel. The core of this type of scheme is the transformation of object geometry into an occupied mesh. The voxel scale is mostly determined by experience or computational resources. For open geometries like camera view frustums, which are jointly defined by imaging parameters, PPM thresholds, and optical axis directions, there is no dedicated threshold depth and boundary efficiency processing.

[0035] While the aforementioned pixel density planning methods can determine the distance thresholds corresponding to different imaging tasks, they typically do not further convert these distance thresholds into the number of discrete layers of the view frustum along the optical axis, the lateral boundary of each layer, and the corresponding voxel set. In other words, there is still a break in the computational chain between PPM distance planning and 3D view frustum discretization.

[0036] The results obtained by the above-mentioned empirical sampling or projected grid methods are not stable enough. When using fixed step size sampling, fixed cross-sectional interval or projected grid approximation, the discrete results are highly dependent on manually set sampling interval, cutoff distance and grid selection rules; and there is a lack of a unified parameter update mechanism when the camera focal length, pixel size, field of view or PPM threshold changes.

[0037] In boundary processing, continuous view frustum boundaries often cross some voxels. Simply including or excluding all boundary voxels will result in an overestimation or underestimation of the view frustum cross-sectional area and the number of voxels. Existing binarization occupancy processing lacks a voxel efficiency factor to describe the contribution of edge voxels, making it difficult to correct for boundary discretization errors.

[0038] Regarding grid scale selection, excessively large voxel scales lead to rough frustum boundaries and increased area errors, while excessively small voxel scales increase storage and computational requirements. Existing methods largely rely on empirical selection of voxel scales and lack a mechanism for quantitative comparison and selection among multiple candidate scales using discrete error indices.

[0039] In general, continuous frustum modeling, PPM distance planning, and general voxelization address different problems. However, existing technologies typically fail to integrate PPM threshold distance calculation, layer-by-layer frustum voxel filling, boundary voxel efficiency correction, and grid scale error evaluation into a closed-loop process. This results in difficulties in reproducing and comparing discrete frustum results generated under the same camera parameters. Therefore, existing technologies have not yet solved the following technical problem: how to convert continuous camera frustums into a discrete voxel set given camera imaging parameters, PPM threshold, and candidate voxel scales, and how to perform fractional weight correction on edge voxels during the discretization process, thereby determining a suitable grid scale using error indices.

[0040] To address the aforementioned issues, this invention proposes a fundamental tool-based method for discretizing camera frustum voxels. This method first calculates the effective depth of the frustum based on a PPM threshold and camera imaging parameters. Then, it determines the lateral boundaries layer by layer along the camera's optical axis and fills them with voxels. Subsequently, the voxels are divided into internal and edge voxels. The boundary area is corrected using a voxel efficiency factor, and the grid scale is selected based on the discretization error index. The output of this method is limited to the camera frustum voxel set, voxel efficiency factor, discretization error, and recommended voxel scale; it does not involve subsequent joint calculations of target objects or application evaluation.

[0041] like Figure 1 As shown, a preferred embodiment of the present invention discloses a camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor, comprising the following steps: S1: Calculate the threshold distance based on the camera imaging parameters and the PPM threshold; Here, PPM represents the number of pixels per meter on the target plane, used to characterize the spatial resolution capability achievable by a camera at a certain distance. PPM threshold Preferably, the pixel density level is determined based on the pixel density level in video surveillance or machine vision operating standards. For example, the corresponding PPM threshold can be determined by referring to the pixel density levels or requirements given for different video surveillance tasks in the publicly published international standard IEC 62676-4:2025 "Video surveillance systems for use in security applications – Part 4: Application guidelines". This standard is only an exemplary reference for setting the PPM threshold and does not constitute a limitation of the present invention; the PPM threshold can also be adjusted according to the target size, imaging quality, and task accuracy requirements.

[0042] The Johnson criterion uses the number of resolvable line pairs along the critical size direction of the target to characterize the spatial resolution required for visual tasks such as detection, orientation, recognition, or identification. According to the Nyquist-Shannon sampling criterion, to avoid aliasing of spatial frequency information, the image sampling frequency should be no less than twice the highest spatial frequency to be characterized. Therefore, the number of resolvable line pairs corresponding to the Johnson criterion can be converted into the minimum number of pixels along the critical size direction of the target, and combined with the actual spatial size of the target, the theoretical lower limit of PPM corresponding to different visual tasks can be obtained. The actual PPM threshold used can be determined based on this theoretical lower limit, combined with factors such as image contrast, signal-to-noise ratio, motion blur, image compression, and ambient lighting. In a specific embodiment, 40 PPM, 80 PPM, and 125 PPM can be used to represent the contour-level, recognition-level, and perception-level thresholds, respectively. The aforementioned 40 PPM, 80 PPM, and 125 PPM are operating thresholds based on the IEC 62676-4:2025 standard, i.e., for real-world imaging conditions. The above values ​​are only a set of thresholds in specific embodiments and do not limit the use of different PPM thresholds in other camera systems or other vision tasks.

[0043] Among them, camera imaging parameters include camera focal length Pixel size Horizontal field of view Vertical field of view Camera viewpoint coordinates .

[0044] like Figure 2 As shown, the relationship between camera imaging parameters, field of view, PPM threshold distance, and view frustum is illustrated. The optical center of the camera lens serves as the camera viewpoint, the CMOS sensor is located behind the lens, and the distance from the optical center of the lens to the CMOS sensor is the focal length. The CMOS sensor includes multiple pixels arranged horizontally and vertically, with the number of pixels being respectively... and The size of a single pixel is This results in an image with the corresponding pixel resolution.

[0045] The horizontal field of view of the camera is determined by the relationship between the light rays between the optical center of the lens and the boundary of the CMOS sensor. and vertical field of view And form a continuous camera view cone in front of the lens. At a distance of [missing information] from the camera viewpoint along the camera's view axis... The target plane is positioned perpendicular to the line of sight, and this target plane intersects with the line of sight of the continuous camera to form a corresponding line of sight. As the distance between the target plane and the camera viewpoint increases, the actual coverage area of ​​the line of sight increases, while the number of pixels in the CMOS sensor remains constant. Therefore, the number of pixels per unit length of the target plane gradually decreases.

[0046] When the target plane is located at a distance from the camera viewpoint When the position is specified, that position corresponds to the first... PPM threshold. Threshold distance It can be calculated based on camera focal length, pixel pitch, and PPM threshold. Areas within the threshold distance of the camera viewpoint meet the corresponding PPM requirement; beyond the threshold distance, the pixel density of the target area falls below the corresponding PPM threshold. For horizontal pixel counts... Horizontal field of view is The camera, at a distance pixel density at It can be represented as:

[0047] in, For pixel density, This refers to the number of horizontal pixels. The distance from the camera to the view frustum section. This is the horizontal field of view.

[0048] Based on the camera imaging geometry, the above formula can be further written as: (equation based on focal length) and pixel size Definite form:

[0049] Where L is the camera focal length and a is the pixel size. This formula shows that, given a PPM threshold, the effective depth of the camera is determined by the ratio of focal length to pixel size.

[0050] when Take the first i PPM threshold When, the corresponding threshold distance for:

[0051] in, Indicates the first The threshold distance corresponding to each PPM threshold is also called the effective cone depth. The method can be applied to multiple PPM thresholds. Calculate multiple This generates discrete cone pixel sets at different visual levels.

[0052] S2: Establish a local frustum coordinate system, and determine the candidate voxel range based on the threshold distance, camera imaging parameters, and candidate voxel size; project the vertex of each candidate voxel within the candidate voxel range onto the local frustum coordinate system, and filter out a discrete frustum voxel set according to the relationship between the vertex of each candidate voxel and the frustum boundary surface; Establishing a local frustum coordinate system specifically includes: based on the camera pose parameters, establishing a local frustum coordinate system with the camera viewpoint as the origin and the viewing axis direction as the depth axis. Further, the camera pose parameters... This can be represented as the direction of the line of sight. Horizontal axis and longitudinal axis Three orthogonal unit vectors can also be represented as an equivalent attitude matrix or rotation parameters.

[0053] Determining the candidate voxel range based on the threshold distance, camera imaging parameters, and candidate voxel sizes specifically includes: using the camera viewpoint as the near-end reference point of the frustum, and using the far-end section at a position along the visual axis at a distance from the threshold distance as the far-end boundary of the frustum; calculating the size of the far-end boundary of the frustum according to the threshold distance and the field of view; combining the local frustum coordinate system to obtain the coordinate range of the corner points of the near-end reference points of the continuous frustums and the far-end boundaries of the frustums in the global coordinate system; adjusting the coordinate range according to the candidate voxel sizes to form a candidate voxel bounding box that can cover the continuous frustums, which serves as the candidate voxel range.

[0054] Projecting the vertices of each candidate voxel within the candidate voxel range onto the local frustum coordinate system, and filtering out a discrete frustum voxel set based on the relationship between the vertices of each candidate voxel and the frustum boundary surfaces, specifically includes: projecting the vertices of each candidate voxel within the candidate voxel range onto the local frustum coordinate system to obtain the local coordinates of the vertices of each candidate voxel; determining whether the candidate voxel intersects with the continuous camera frustum based on the positional relationship between the local coordinates of the vertices of each candidate voxel and the boundary surfaces of the frustum determined by the threshold distance and the field of view angle, and including all intersecting candidate voxels into the discrete frustum voxel set. Further, determining whether a candidate voxel intersects with the continuous camera frustum based on the positional relationship between the local coordinates of the vertices of each candidate voxel and the boundary surfaces of the frustum specifically includes: if all vertices of a candidate voxel are located outside any side of the frustum interface, then the candidate voxel is determined not to intersect with the continuous camera frustum; otherwise, the candidate voxel is determined to intersect with the continuous camera frustum.

[0055] Determining the threshold distance Then, a local view frustum coordinate system is established based on the camera attitude. Specifically, after determining the threshold distance, the three-dimensional spatial coordinate system where the voxel mesh is located is used as the global coordinate system, and a local view frustum coordinate system is established based on the camera attitude. The local view frustum coordinate system has the camera viewpoint coordinates as the origin, the camera view axis direction as the depth axis, and the horizontal and vertical axes perpendicular to the depth axis as the view frustum section coordinate axes. In one embodiment, the camera's yaw angle, pitch angle, and roll angle are respectively... , and The camera attitude rotation matrix is ​​constructed using the ZYX Euler angle rotation order:

[0056] Multiplying the depth, lateral, and longitudinal axes of the camera in its initial state by the attitude rotation matrix yields the depth, lateral, and longitudinal axes in the global coordinate system. These three axes are mutually orthogonal and are all unit vectors. Camera attitude can also be represented using attitude matrices, quaternions, or other equivalent attitude parameters.

[0057] In one specific embodiment, the camera attitude parameters only include yaw angle, while pitch angle and roll angle are zero. Its depth axis, lateral axis, and longitudinal axis are as follows:

[0058]

[0059]

[0060] This local coordinate system uses camera viewpoint coordinates. Using the origin as the reference point and the camera's line of sight as the reference point... With depth as the axis and horizontal axis as the axis and longitudinal axis The axes are cross-sectional coordinates; the three axes are orthogonal to each other and can be determined by yaw angle, pitch angle, roll angle, attitude matrix or other equivalent attitude parameters.

[0061] For any spatial point Its coordinates relative to the camera viewpoint The local coordinates can be represented as:

[0062]

[0063]

[0064] in, For point Depth coordinates along the line of sight, The horizontal axis is... The vertical axis is represented by .

[0065] Continuous cones in depth The horizontal half width at the location and vertical half width It can be determined by the following formula:

[0066]

[0067] in, For horizontal field of view, This is the vertical field of view. With... Increase from 0 to The dimensions of the cone section increase proportionally.

[0068] The continuous view frustum referred to in this paper is a geometric view frustum that is defined by the camera viewpoint, field of view angle, and threshold distance and has not yet been discretized into voxels. The global coordinate system refers to the fixed three-dimensional spatial coordinate system used when establishing the voxel mesh; the local view frustum coordinate system is a coordinate system with the camera viewpoint as the origin that changes with the camera pose.

[0069] In the specific discretization process, the method first uses the camera viewpoint coordinates. Threshold distance Field of view and voxel scale Determine candidate voxel bounding boxes that can enclose the continuous view frustum. Specifically, using camera viewpoint coordinates... As the near-end reference point of the visual cone, the distance along the visual axis is... The distal section at that point is used as the distal boundary of the view cone, according to and Calculate the horizontal half-width and vertical half-height of the far-end section separately; then, based on the camera viewpoint coordinates and the viewing axis direction of the local frustum coordinate system... Horizontal direction and longitudinal direction The near-end reference point and the four corner points of the far-end section of the continuous view frustum are transformed to the global coordinate system. The near-end reference point is the camera viewpoint. The four corner points of the far-end section are obtained by moving the camera viewpoint along the visual axis by the threshold distance, and then superimposing the corresponding positive or negative half-widths in the horizontal and vertical directions, respectively. Based on the minimum and maximum coordinate values ​​of the near-end reference point and the four far-end section corner points on each coordinate axis of the global coordinate system, the axis-aligned bounding range of the continuous view frustum is determined. According to the selected voxel scale, the lower bound of the bounding range is rounded outwards and downwards, and the upper bound is rounded outwards and upwards, forming a candidate voxel bounding box that can cover the continuous view frustum. The voxels within this candidate voxel bounding box are then used as the candidate voxel range.

[0070] For a candidate voxel within the candidate voxel range, the eight vertices of that voxel are respectively used as spatial points to be determined. For each vertex First, calculate its coordinates relative to the camera viewpoint. vector Then Projecting these coordinates onto the local frustum coordinate system along the visual axis, lateral direction, and longitudinal direction yields the local depth coordinates, lateral coordinates, and longitudinal coordinates of the vertex. Then, based on the vertex's relationship to the near end face, far end face, left interface, right interface, lower boundary face, and upper boundary face, a determination is made: if all eight vertices of a candidate voxel are located outside any one of the interfaces, the voxel is considered to have no intersection with the continuous frustum and is excluded; otherwise, the voxel is considered to have an occupancy relationship with the continuous frustum and is included in the discrete frustum voxel set. After the above candidate voxel selection and boundary surface relationship determination, the continuous view frustum is represented as a set of discrete view frustum voxels. The schematic result is as follows Figure 3 As shown. This vertex-boundary surface determination method allows for view frustum discretization independent of global coordinate axis orientation, making it applicable to arbitrary yaw angles and camera poses with pitch or roll. Specifically, in... Figure 3 In the diagram, different PPM thresholds correspond to different maximum observation distances. A higher PPM threshold corresponds to a shorter maximum observation distance; as the distance between the target and the camera increases, the pixel density of the target in the image gradually decreases. Based on the distances corresponding to each PPM threshold, the camera frustum can be divided into different PPM level regions, distinguished by different colors. The graded frustums are then discretized into voxels, resulting in a set of discrete frustum voxels with corresponding PPM levels. The different colors in the diagram are only used to represent different PPM levels and do not constitute a specific color limitation.

[0071] S3: Divide the discrete frustum voxel set into internal voxels and edge voxels, and calculate the voxel efficiency factor to correct the area contribution of edge voxels, so as to obtain the discrete area estimate. Specifically, step S3 includes: projecting the discrete frustum voxel set onto the geometric evaluation projection plane to generate a two-dimensional occupancy map, and using morphological erosion to distinguish the occupancy units in the two-dimensional occupancy map into an internal voxel set and an edge voxel set, wherein the geometric evaluation projection plane is the plane containing the far-end section of the continuous camera frustum and / or the lateral projection plane formed by the lateral boundary of the continuous camera frustum; calculating a voxel efficiency factor based on the internal voxel set and the edge voxel set, the voxel efficiency factor being used to weight and correct the area contribution of the edge voxels; and calculating the discrete area estimate of the discrete frustum voxel set on the geometric evaluation projection plane based on the voxel efficiency factor, the internal voxel set, and the edge voxel set.

[0072] Specifically, such as Figures 4a to 4c As shown, to calculate the voxel efficiency factor, the projection of a continuous view cone onto its geometric evaluation projection plane can be discretized into a two-dimensional occupancy map. Specifically, as... Figures 4a to 4c As shown, Figure 4a The conical region in the middle represents a continuous camera view cone defined by the camera viewpoint, horizontal field of view, vertical field of view, and threshold distance. The near end of this continuous camera view cone corresponds to the camera viewpoint, and its cross-sectional size gradually increases along the visual axis, terminating when it reaches the threshold distance corresponding to the PPM threshold.

[0073] Figure 4b and Figure 4c The projections of the continuous camera view frustum onto the xz and yz planes, and their mesh discretization results, are shown respectively. The light blue area represents the continuous geometry formed after the continuous camera view frustum is projected onto the corresponding plane; the dark blue mesh represents the occupied mesh cells obtained after discretizing the projected geometry according to the selected voxel scale.

[0074] Specifically, the corresponding projection surface is divided into a two-dimensional grid according to the selected voxel scale, and it is determined whether each two-dimensional grid cell intersects with the light blue continuous projection region. When a two-dimensional grid cell intersects with the continuous projection region, it is marked as an occupied cell; otherwise, it is marked as an unoccupied cell, thus forming a two-dimensional occupancy map. Since grid cells that partially intersect with the continuous projection region are also marked as occupied cells, the dark blue grid located at the projection boundary may only be partially covered by the light blue continuous projection region.

[0075] After obtaining the two-dimensional occupancy map, morphological erosion is performed on the occupancy cells. Occupancy cells that remain after erosion are designated as internal occupancy cells, while those present in the original two-dimensional occupancy map but removed after erosion are designated as edge occupancy cells. A voxel efficiency factor is used to weight and correct the area contribution of the edge occupancy cells. The colors in the image are only used to distinguish between continuous projection regions and discrete occupancy meshes and do not constitute a specific color limitation. The geometric evaluation projection surface includes the plane containing the far-end section of the view frustum and the lateral projection surface formed by the lateral boundary of the view frustum. When continuous view frustums are projected onto the aforementioned two-dimensional evaluation projection surface, some mesh cells are stably located inside the continuous geometric boundary, while other mesh cells are located near the boundary or are crossed by the continuous boundary. To avoid area errors caused by simply taking or discarding all cells, the method first constructs a two-dimensional occupancy map of the view frustum on the two-dimensional evaluation projection surface, where mesh cells covered by the projection of discrete view frustums are denoted as occupancy cells.

[0076] Subsequently, a morphological erosion operation is performed on the 2D occupancy map. The occupancy cells that remain after erosion are used as an internal voxel set. Occupying cells that existed in the original 2D occupancy graph but were removed after erosion are considered as edge voxel sets. In other words, the internal voxel set. The set of edge voxels corresponds to voxels that are stably located within the continuous cone projection region in their local neighborhood. This corresponds to voxels near the continuous cone projection boundary that may only be partially covered. Preferably, the morphological erosion operation uses a 3×3 grid cell square structural element and performs one erosion operation. The square structural element includes a central occupying cell and its eight surrounding adjacent cells; the central occupying cell is retained after erosion only if all grid cells in the central occupying cell and its eight neighboring areas are occupying cells. The occupying cells that are retained after erosion are designated as internal occupying cells, and the occupying cells that existed in the original 2D occupying map but were removed after erosion are designated as edge occupying cells.

[0077] set up This refers to the continuous theoretical area, that is, the theoretical geometric area of ​​the continuous view cones projected onto the geometric evaluation plane. For the number of internal voxels, For the number of edge voxels, Let be the voxel side length. Voxel efficiency factor. Calculate using the following formula:

[0078] In the formula, This represents the voxel efficiency factor, which is the voxel efficiency weight used when including each edge voxel in the area calculation. Through this factor, edge voxels are not simply included or discarded, but rather participate in the discrete area calculation with fractional weights.

[0079] When the number of edge voxels is not zero The sum of the internal voxel area and the corrected edge voxel area should be as close as possible to the continuous theoretical area. This achieves area conservation correction between the continuous geometric area and the discrete voxel area. The continuous theoretical area refers to the area of ​​the continuous geometric figure formed by the projection region of the continuous view frustum onto the selected geometric evaluation projection plane. This area is calculated using the geometric area formula of the corresponding projection figure based on the threshold distance, horizontal field of view, and vertical field of view of the view frustum. Specifically, when the geometric evaluation projection plane is the plane containing the far end section of the view frustum, the projection region of the continuous view frustum on this plane is rectangular, with its lateral width and longitudinal height determined by the threshold distance, horizontal field of view, and vertical field of view, respectively. When the geometric evaluation projection plane is the lateral projection plane of the view frustum, the projection region of the continuous view frustum is triangular or trapezoidal, and its continuous theoretical area can be calculated using the triangle or trapezoid area formula based on the cross-sectional dimensions at the near and far ends and the depth distance between them. When the near end is taken as the camera viewpoint, the lateral projection region is triangular; when the near end is located at a certain depth from the camera viewpoint, the lateral projection region is trapezoidal.

[0080] It should be noted that the above voxel efficiency factor It is a global average value used to correct the overall area contribution of edge voxels without excessively increasing computational complexity, thereby achieving an approximate conservation between the discrete estimated area and the continuous theoretical area. In practical applications, this factor can effectively reduce systematic area estimation bias.

[0081] S4: Based on the error between the discrete area estimate and the continuous theoretical area, select the voxel scale that meets the error requirement from the candidate voxel scales.

[0082] according to Then, the discrete area estimate can be calculated, and the discrete area estimation error between the discrete area estimate and the continuous theoretical area can be determined. Calculate using the following formula:

[0083] in, This represents the relative error between the estimated discrete area (corrected discrete area) and the continuous theoretical area. This discrete area estimation error can be used to evaluate the accuracy of frustum discretization at a given voxel scale.

[0084] Calculations were performed at multiple candidate voxel scales. This allows us to obtain the relationship between the discrete area estimation error and the grid scale. Generally speaking, the finer the voxel scale, the smaller the edge approximation error, but the greater the computational cost; the coarser the voxel scale, the lower the computational cost, but the edge error may increase rapidly.

[0085] In step S4, the discrete area estimation errors of the distal section and the lateral projection surface can be calculated separately. When selecting the voxel scale, the maximum of the two errors can be used as the evaluation criterion to ensure that the discretization accuracy meets the requirements under all viewpoints.

[0086] The method of this invention transforms grid scale selection from an empirical setting into an error-constrained problem. Specifically, a set of candidate voxel scales is first given, such as 0.625m, 1.25m, 2.5m, 5m, and 10m; then, for each candidate scale, frustum voxel discretization and voxel efficiency factoring are performed respectively. and relative error The calculation is performed; finally, a voxel scale that meets the preset error threshold and has an acceptable computational load is selected. The aforementioned set of candidate voxel scales is selected based on engineering experience and is only used to illustrate the comparison and selection process of voxel scales; in other embodiments, users can set different candidate scale ranges, number of scales, and scale intervals according to specific application requirements. The preset allowable error upper limit can be set by the user before calculation based on the specific application scenario, discrete accuracy requirements, the sensitivity of subsequent algorithms to errors, and available computing resources, and is not a fixed value. For example, in one embodiment, the preset allowable error upper limit can be set to 2%.

[0087] In a specific embodiment, a 1.25m voxel scale can be used as one of the candidate preferred scales. The scale is based on two parts: Firstly, when the representative spatial scale to be maintained is approximately 3m (in the architectural space application scenario addressed in this embodiment, the single-story height of the building is used as the representative spatial scale to be maintained in the discrete voxel model; considering that the floor height of common civil buildings such as residences is usually on the order of 3m, this embodiment takes 3m as the representative spatial scale), according to the Nyquist-Shannon sampling principle, the voxel side length should not be greater than half of this scale (referring to the representative spatial scale, i.e., 3m), so as to form at least two sampling intervals on this spatial scale. 1.25m satisfies this sampling requirement; secondly, calculations are still required separately in the candidate scale set. The computational complexity is compared to verify whether the discrete error at this scale meets the preset requirements. To illustrate the scale selection process described above, a specific example is used, taking the horizontal field of view angle... 73.80°, vertical field of view 58.80°, effective cone depth The voxel efficiency factor is 63.95m. The value was set to 0.4812, and the candidate voxel scales were set to 0.625m, 1.25m, 2.5m, 5m, and 10m. For the far-end section, the continuous geometric area was calculated based on the rectangular section at the effective depth of the view frustum; for the lateral projection surface, the continuous geometric area was calculated based on the trapezoidal projection region formed from the near-end depth to the far-end depth. Subsequently, a discrete occupancy map was constructed for each candidate voxel scale, and internal voxels and edge voxels were distinguished by morphological erosion. The area contribution of edge voxels was weighted using a voxel efficiency factor to obtain the corresponding discrete estimated area.

[0088] In this embodiment, discrete error This can be expressed as the relative error between the discrete estimated area and the continuous geometric area, and output as a percentage. To reduce the influence of the voxel mesh starting position on the error statistics, multiple points can be sampled within a coarse voxel scale to measure the relative offset position of the camera or projection area, and the average error can be taken as the error evaluation result at that candidate voxel scale. Experimental results of the estimation errors of the projected area and lateral projected area of ​​the far end section of the view frustum at different candidate voxel scales are as follows: Figure 5a and Figure 5b As shown. According to the Nyquist-Shannon sampling principle, if the representative spatial scale to be maintained is approximately 3 m, then the side length of the candidate voxels should preferably be less than or equal to 1.5 m. Therefore, among the candidate scales mentioned above, 0.625 m and 1.25 m meet this sampling scale requirement. Combined with... Figure 5a and Figure 5b The experimental results show that the relative error of area estimation at the 1.25 m voxel scale is already at a low level; compared with the 0.625 m voxel scale, 1.25 m can significantly reduce the number of voxels and the amount of computation. Therefore, in this embodiment, considering the sampling scale constraint, discrete error and computational efficiency, 1.25 m is preferred as the voxel scale.

[0089] The candidate and preferred scales mentioned above are only used to illustrate the grid scale selection process and do not limit the invention from using different voxel scales under other camera parameters, other PPM thresholds, other spatial scales or other accuracy requirements.

[0090] In summary, in the preferred embodiment of the present invention, the camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor includes camera imaging parameters (including camera focal length) as input. Pixel size Horizontal field of view Vertical field of view Camera viewpoint coordinates Camera attitude parameters (Can be represented as the direction of the line of sight) Horizontal axis and longitudinal axis Three orthogonal unit vectors (which can also be represented as an equivalent pose matrix or rotation parameters), PPM threshold. and one or more candidate voxel scales The output includes the threshold distance corresponding to the PPM threshold. Discrete frustum set Internal voxel set and edge voxel set Voxel efficiency factor Discrete error The outputs are all discretized results of the camera frustum itself, which can be used as the basic input for subsequent algorithms. The method of this invention does not require or limit how subsequent algorithms use this discrete frustum. In one application, the above-mentioned discrete frustum voxel set can also be used as the basic input for privacy assessment or imaging impact assessment. For example, the PPM threshold can be interpreted as the imaging detail level that the camera can achieve at different distances, and the area of ​​building floors, building facades, or ground areas that it may cover can be estimated using the voxel range swept by the camera frustum in space, thereby providing a quantitative basis for the auxiliary analysis of privacy risks of mobile observation platforms such as UAVs, vehicle-mounted cameras, and ground inspection cameras. This application is only a subsequent use of the discrete frustum output results and does not change the core technical solution of this application, which is based on camera frustum voxel discretization, voxel efficiency correction, and grid scale selection.

[0091] The preferred embodiment of the present invention discloses a camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor, which includes the following method steps: (1) a global method for voxel discretization of camera frustum, which takes camera imaging parameters, PPM threshold, camera pose parameters and candidate voxel scale as inputs, and converts continuous camera frustums into a storable and queryable set of discrete voxels. (2) A continuous frustum discretization representation method based on camera pose, namely, determining the viewing axis direction, lateral direction and longitudinal direction according to the camera pose, and establishing a local frustum coordinate system; determining the candidate voxel range that can cover the continuous frustum in the global voxel mesh, and projecting the vertices of the candidate voxels onto the local frustum coordinate system; and then, based on the relationship between the projection results and the near end face, far end face and lateral boundary face of the frustum, selecting the discrete frustum voxel set. (3) The efficiency correction method for the boundary voxels of the view cone is to divide the discrete view cone voxels into internal voxels and edge voxels, and use the voxel efficiency factor. Fractional weight correction is applied to edge voxels to reduce the discrete area deviation caused by taking all or discarding all boundary voxels. (4) A voxel scale selection method based on discrete error, that is, generating a set of frustum voxels for multiple candidate voxel scales, calculating the voxel efficiency factor and discrete error respectively. The voxel scale is selected based on the preset error requirements and computational requirements.

[0092] The preferred embodiment of this invention discloses a camera frustum voxel discretization method based on PPM threshold and voxel efficiency factor, which has the following advantages: (1) Forming a complete frustum voxel discretization process. This invention incorporates camera imaging parameters, PPM threshold, attitude parameters and candidate voxel scale into the same calculation process, and outputs a storable and queryable set of frustum voxels, so that continuous frustums can be used as standardized discrete inputs for subsequent spatial calculations.

[0093] (2) The determination of voxel attribution is clearer. The present invention establishes a local frustum coordinate system based on the camera pose and determines the voxel attribution by the projection relationship between the candidate voxel vertices and the frustum boundary surface. This makes the frustum discretization process independent of manual cross-section sampling or empirical projection selection rules, and the results are easier to reproduce and compare.

[0094] (3) Boundary area error can be corrected. This invention distinguishes the view frustum voxels into inner voxels and edge voxels, and uses the voxel efficiency factor Fractional weighting is applied to edge voxels to reduce area bias caused by taking or discarding all boundary voxels.

[0095] (4) The choice of voxel scale is more quantifiable. This invention utilizes discrete error... By comparing the discretization results at different candidate voxel scales and combining error requirements with computational requirements, the voxel scale can be selected to reduce the uncertainty caused by relying entirely on experience to set the grid resolution.

[0096] In summary, the preferred embodiment of this invention discloses a method for determining the effective depth of the view frustum based on camera imaging parameters and pixel density thresholds, discretizing continuous camera view frustums into a three-dimensional voxel set at the voxel scale, and determining a suitable mesh scale through voxel efficiency factors and discretization error indices. This invention can serve as a fundamental view frustum discretization tool for various imaging systems, applicable to scenarios requiring the conversion of camera view frustums into a computable voxel set, such as UAV-borne cameras, vehicle-mounted or ship-mounted cameras, airborne or spaceborne imaging equipment, ground video surveillance equipment, mobile robot vision systems, augmented reality and digital twin simulation systems.

[0097] Another preferred embodiment of the present invention discloses a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the camera frustum discretization method as described in the preferred embodiment above.

[0098] Optionally, the aforementioned storage media may include, but are not limited to, USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks, and other media capable of storing computer programs.

[0099] This invention incorporates camera imaging parameters, PPM threshold, pose parameters, and candidate voxel scales into a single computational process. First, it calculates the effective depth of the frustum based on the PPM threshold, ensuring the discrete range matches the imaging resolution. Then, it establishes a local frustum coordinate system and projects candidate voxel vertices onto this system. The positional relationship between the vertices and the frustum boundary surface accurately determines voxel affiliation, eliminating reliance on manual cross-section sampling or empirical projection rules, thus improving the accuracy and reproducibility of the discretization results. Furthermore, it distinguishes between internal and edge voxels and applies a voxel efficiency factor to the edge voxels, effectively reducing area bias caused by fully selecting or discarding edge voxels. Finally, it compares the discretization results under different candidate voxel scales based on discretization errors, achieving quantitative selection of voxel scales based on error constraints and computational requirements. These synergistic technical features enable the efficient and accurate conversion of continuous camera frustums into a storable and queryable set of discrete voxels, providing standardized discrete input for subsequent spatial computations. Furthermore, the voxel efficiency factor corrects the area contribution of edge voxels, reducing discrete area estimation errors. The discrete accuracy of different voxel scales is evaluated quantitatively by using error indices, which supports the optimal selection of grid scale.

[0100] The background section of this invention may include background information about the problems or circumstances surrounding the invention, rather than a description of prior art by others. Therefore, the content included in the background section is not an admission of prior art by the applicant.

[0101] The above description provides a further detailed explanation of the present invention in conjunction with specific / preferred embodiments, and it should not be construed that the specific implementation of the present invention is limited to these descriptions. For those skilled in the art, various substitutions or modifications can be made to these described embodiments without departing from the concept of the present invention, and all such substitutions or modifications should be considered within the scope of protection of the present invention. In the description of this specification, the reference to terms such as "an embodiment," "some embodiments," "preferred embodiment," "example," "specific example," or "some examples," etc., indicates that the specific features, structures, materials, or characteristics described in connection with that embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any suitable manner in one or more embodiments or examples. Furthermore, those skilled in the art can combine and integrate different embodiments or examples and features of different embodiments or examples described in this specification without contradiction. Although the embodiments of the present invention and their advantages have been described in detail, it should be understood that various changes, substitutions, and modifications can be made herein without departing from the scope defined by the appended claims.

Claims

1. A method for discretizing camera frustum voxels based on PPM threshold and voxel efficiency factor, characterized in that, Includes the following steps: S1: Calculate the threshold distance based on the camera imaging parameters and the PPM threshold; S2: Establish a local frustum coordinate system, and determine the candidate voxel range based on the threshold distance, camera imaging parameters, and candidate voxel size; project the vertex of each candidate voxel within the candidate voxel range onto the local frustum coordinate system, and filter out a discrete frustum voxel set according to the relationship between the vertex of each candidate voxel and the frustum boundary surface; S3: Divide the discrete view frustum voxel set into internal voxels and edge voxels, and calculate the voxel efficiency factor to correct for the area contribution of edge voxels, thus obtaining a discrete area estimate; wherein, the voxel efficiency factor... for: In the formula, Let be the theoretical geometric area of ​​the continuous view cone projected onto the geometric evaluation plane. For the number of edge voxels, For the number of internal voxels, The side length of the voxel; S4: Based on the error between the discrete area estimate and the continuous theoretical area, select the voxel scale that meets the error requirement from the candidate voxel scales.

2. The camera frustum discretization method according to claim 1, characterized in that, The threshold distance calculated in step S1 is: In the formula, Indicates the first The threshold distance corresponding to each PPM threshold, where L is the camera focal length. For pixel size, For the first Each PPM threshold.

3. The camera frustum discretization method according to claim 1, characterized in that, The establishment of the local frustum coordinate system in step S2 specifically includes: establishing a local frustum coordinate system with the camera viewpoint as the origin and the viewing axis direction as the depth axis based on the camera pose parameters.

4. The camera frustum discretization method according to claim 1, characterized in that, Step S2, which determines the candidate voxel range based on the threshold distance, camera imaging parameters, and candidate voxel size, specifically includes: Using the camera viewpoint as the near-end reference point of the view cone, and the far-end section at a distance from the threshold along the visual axis as the far-end boundary of the view cone; Calculate the dimensions of the distal boundary of the visual cone based on the threshold distance and the field of view angle; By combining the local frustum coordinate system, the coordinate range of the near-end reference point of the continuous frustum and the corner point of the far-end boundary of the frustum in the global coordinate system can be obtained; The coordinate range is adjusted according to the candidate voxel size to form a candidate voxel bounding box that can cover continuous view frustums, which serves as the candidate voxel range.

5. The camera frustum discretization method according to claim 1, characterized in that, In step S2, the vertices of each candidate voxel within the candidate voxel range are projected onto the local frustum coordinate system. A discrete frustum voxel set is then selected based on the relationship between the vertices of each candidate voxel and the frustum boundary surface. Specifically, this includes: Project the vertices of each candidate voxel within the candidate voxel range onto the local frustum coordinate system to obtain the local coordinates of the vertices of each candidate voxel; based on the positional relationship between the local coordinates of the vertices of each candidate voxel and the boundary surfaces of each frustum determined by the threshold distance and the field of view angle, determine whether the candidate voxel intersects with the continuous camera frustum, and include all intersecting candidate voxels into the discrete frustum voxel set.

6. The camera frustum discretization method according to claim 5, characterized in that, Determining whether a candidate voxel intersects with the continuous camera view frustum based on the positional relationship between the local coordinates of the vertices of each candidate voxel and the boundary surfaces of each view frustum specifically includes: If all vertices of a candidate voxel are located outside any side of the interface of the view frustum, then the candidate voxel is determined not to intersect with the view frustum of the continuous camera; otherwise, the candidate voxel is determined to intersect with the view frustum of the continuous camera.

7. The camera frustum discretization method according to claim 1, characterized in that, Step S3 specifically includes: The discrete frustum voxel set is projected onto the geometric evaluation projection plane to generate a two-dimensional occupancy map. The occupancy units in the two-dimensional occupancy map are divided into internal voxel sets and edge voxel sets by morphological erosion operation. The geometric evaluation projection plane is the plane where the far end section of the continuous camera frustum is located and / or the lateral projection plane formed by the lateral boundary of the continuous camera frustum. Based on the internal voxel set and the edge voxel set, a voxel efficiency factor is calculated, which is used to weight and correct the area contribution of the edge voxels. Based on the voxel efficiency factor, the internal voxel set, and the edge voxel set, calculate the discrete area estimate of the discrete frustum voxel set on the geometric evaluation projection plane.

8. The camera frustum discretization method according to claim 1, characterized in that, In step S4, the error between the corrected discrete area and the continuous theoretical area is used as a basis. for: In the formula, Voxel efficiency factor For the number of edge voxels, For the number of internal voxels, Let the voxel side length be , Let be the theoretical geometric area of ​​the continuous view cone projected onto the geometric evaluation plane.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the camera frustum discretization method as described in any one of claims 1 to 8.