CN115908536A - Object volume measuring method, device, equipment and storage medium - Google Patents
Object volume measuring method, device, equipment and storage medium Download PDFInfo
- Publication number
- CN115908536A CN115908536A CN202211192674.7A CN202211192674A CN115908536A CN 115908536 A CN115908536 A CN 115908536A CN 202211192674 A CN202211192674 A CN 202211192674A CN 115908536 A CN115908536 A CN 115908536A
- Authority
- CN
- China
- Prior art keywords
- triangular
- triangular mesh
- point cloud
- cloud data
- measured object
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 37
- 230000011218 segmentation Effects 0.000 claims abstract description 9
- 238000005259 measurement Methods 0.000 claims description 6
- 238000000638 solvent extraction Methods 0.000 claims description 4
- 238000000691 measurement method Methods 0.000 abstract description 6
- 238000010586 diagram Methods 0.000 description 20
- 238000004422 calculation algorithm Methods 0.000 description 12
- 238000004891 communication Methods 0.000 description 11
- 238000004364 calculation method Methods 0.000 description 8
- 238000004590 computer program Methods 0.000 description 6
- 230000001788 irregular Effects 0.000 description 4
- 230000003287 optical effect Effects 0.000 description 3
- 229910052731 fluorine Inorganic materials 0.000 description 2
- 125000001153 fluoro group Chemical group F* 0.000 description 2
- 230000006870 function Effects 0.000 description 2
- 230000003993 interaction Effects 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 238000013473 artificial intelligence Methods 0.000 description 1
- 230000001413 cellular effect Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000010801 machine learning Methods 0.000 description 1
- 239000013307 optical fiber Substances 0.000 description 1
- 238000005192 partition Methods 0.000 description 1
- 230000008569 process Effects 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 230000001953 sensory effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Images
Landscapes
- Length Measuring Devices With Unspecified Measuring Means (AREA)
Abstract
The present disclosure provides an object volume measurement method, apparatus, device and storage medium, the method comprising: the method comprises the steps of obtaining point cloud data of the surface of a measured object, dividing the point cloud data into a plurality of triangular meshes according to a preset division rule, and determining the target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of each triangular mesh on the bottom surface of the measured object. By adopting the method, the triangular mesh obtained by point cloud data segmentation can better reflect the fluctuation degree of the surface of the measured object, namely the actual characteristics of the measured object, so that the target volume precision of the measured object determined by the triangular mesh is higher.
Description
Technical Field
The present disclosure relates to the field of radar detection technologies, and in particular, to a method, an apparatus, a device, and a storage medium for measuring a volume of an object.
Background
Laser radar is a radar system that emits a laser beam to detect characteristics such as a position and a velocity of an object, and is currently widely used in the fields of detecting a distance and measuring a volume of an object.
The existing method for measuring the volume of an object based on a laser radar mainly comprises the steps of scanning the object to be measured by the laser radar to generate point cloud data, dividing the point cloud data into a plurality of quadrilateral grids by adopting a grid quadrilateral cutting algorithm, and calculating the volume of a quadrangular prism formed by the projection of each quadrilateral grid and the bottom surface of each grid, so as to obtain the volume of the object to be measured.
However, when the surface relief degree of the measured object is large, the quadrilateral grid obtained by using the grid quadrilateral cutting algorithm cannot accurately reflect the actual characteristics of the measured object, which results in a large error of the volume of the measured object obtained by calculation.
Disclosure of Invention
The present disclosure provides an object volume measuring method, apparatus, device and storage medium to at least solve the above technical problems in the prior art.
According to a first aspect of the present disclosure, there is provided an object volume measurement method, the method comprising:
acquiring point cloud data of the surface of a measured object, wherein the point cloud data is generated by data obtained by scanning the surface of the measured object by a preset radar, and the point cloud data comprises spatial coordinates of a plurality of points on the surface of the measured object;
dividing the point cloud data into a plurality of triangular meshes according to a preset segmentation rule, wherein any two vertexes of each triangular mesh are formed by two adjacent points in the point cloud data;
and determining the target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of the triangular mesh on the bottom surface of the measured object.
In an implementation manner, the dividing the point cloud data into a plurality of triangular meshes according to a preset segmentation rule includes:
and aiming at each point in the point cloud data, determining a triangle formed by two points which are adjacent to the point and are mutually adjacent to the point and the point as a triangular mesh, and obtaining a plurality of triangular meshes divided based on the point cloud data.
In an embodiment, the determining a target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of the triangular mesh on the bottom surface of the measured object includes:
projecting the triangular mesh to the bottom surface of the measured object aiming at each triangular mesh to obtain a projection triangle corresponding to the triangular mesh;
calculating the area of each triangular mesh, and calculating the projection height of each vertex of each triangular mesh on the bottom surface of the measured object;
aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh to be used as the volume of the triangular prism;
and calculating the sum of the volumes of the triangular prisms corresponding to the triangular meshes to serve as the target volume of the measured object.
In an embodiment, the calculating, for each triangular prism formed by the triangular mesh and the corresponding projection triangle, a product between an average value of projection heights of respective vertices of the triangular mesh and an area of the triangular mesh as a volume of the triangular prism includes:
aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh by adopting the following formula as the volume of the triangular prism:
wherein Δ V represents the volume of the triangular prism, T i,k 、T i,k+1 And T i+1,k Representing the three vertices of the triangular mesh,denotes the area, T 'of the triangular mesh' i,k 、T’ i,k+1 And T' i+1,k And representing projection points of three vertexes of the triangular mesh on the bottom surface of the measured object, wherein i represents the ith row in the point cloud data, and k represents the kth column in the point cloud data.
According to a second aspect of the present disclosure, there is provided an object volume measuring device, the device comprising:
the system comprises a point cloud data acquisition module, a point cloud data acquisition module and a data processing module, wherein the point cloud data acquisition module is used for acquiring point cloud data of the surface of a measured object, the point cloud data is generated by data obtained by scanning the surface of the measured object by a preset radar, and the point cloud data comprises spatial coordinates of a plurality of points on the surface of the measured object;
the mesh division module is used for dividing the point cloud data into a plurality of triangular meshes according to a preset division rule, wherein any two vertexes of each triangular mesh are formed by two adjacent points in the point cloud data;
and the volume determining module is used for determining the target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of each triangular mesh on the bottom surface of the measured object.
In an implementation manner, the mesh dividing module is specifically configured to determine, for each point in the point cloud data, a triangle formed by two points that are adjacent to the point and are adjacent to each other and the point as a triangle mesh, and obtain a plurality of triangle meshes divided based on the point cloud data.
In an implementation manner, the volume determining module is specifically configured to, for each triangular mesh, project the triangular mesh onto the bottom surface of the object to be measured, so as to obtain a projection triangle corresponding to the triangular mesh; calculating the area of each triangular mesh, and calculating the projection height of each vertex of each triangular mesh on the bottom surface of the measured object; aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh to be used as the volume of the triangular prism; and calculating the sum of the volumes of the triangular prisms corresponding to the triangular meshes to serve as the target volume of the measured object.
In an implementation manner, the volume determining module is specifically configured to, for a triangular prism formed by each triangular mesh and a corresponding projection triangle, calculate a product between an average value of projection heights of respective vertices of the triangular mesh and an area of the triangular mesh as a volume of the triangular prism, by using the following formula:
wherein Δ V represents the volume of the triangular prism, T i,k 、T i,k+1 And T i+1,k Representing the three vertices of the triangular mesh,denotes the area, T 'of the triangular mesh' i,k 、T’ i,k+1 And T' i+1,k And representing projection points of three vertexes of the triangular mesh on the bottom surface of the measured object, wherein i represents the ith row in the point cloud data, and k represents the kth column in the point cloud data.
According to a third aspect of the present disclosure, there is provided an electronic device comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the methods of the present disclosure.
According to a fourth aspect of the present disclosure, there is provided a non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of the present disclosure.
According to the method provided by the embodiment of the disclosure, the point cloud data is divided into a plurality of triangular meshes, and the target volume of the measured object can be determined by utilizing the area of each triangular mesh and the projection height of each vertex of each triangular mesh on the bottom surface of the measured object. The triangular mesh obtained by point cloud data segmentation can reflect the fluctuation degree of the surface of the measured object, namely the actual characteristics of the measured object, so that the target volume precision of the measured object determined by the triangular mesh is higher.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The above and other objects, features and advantages of exemplary embodiments of the present disclosure will become readily apparent from the following detailed description read in conjunction with the accompanying drawings. Several embodiments of the present disclosure are illustrated by way of example, and not by way of limitation, in the figures of the accompanying drawings and in which:
in the drawings, the same or corresponding reference numerals indicate the same or corresponding parts.
FIG. 1 is a schematic diagram of a method for partitioning point cloud data using a grid quadrilateral cutting algorithm;
FIG. 2 is a schematic diagram of a point cloud volume envelope formed by dividing point cloud data using a grid quadrilateral cutting algorithm;
fig. 3 is a schematic flow chart of an implementation of a method for measuring a volume of an object according to an embodiment of the present disclosure;
FIG. 4 is a schematic diagram of an object volume measurement system provided by embodiments of the present disclosure;
FIG. 5 is a schematic diagram of a point cloud provided by an embodiment of the present disclosure;
fig. 6 is a schematic diagram of partitioning point cloud data by an irregular triangular mesh model according to the embodiment of the present disclosure;
fig. 7 is a schematic diagram of dividing partial point cloud data of a measured object according to the embodiment of the present disclosure;
FIG. 8 is a schematic diagram of an envelope of a point cloud volume formed by triangular meshes provided in an embodiment of the present disclosure;
fig. 9 is a schematic structural diagram of an object volume measuring device provided in the embodiment of the present disclosure;
fig. 10 shows a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
In order to make the objects, features and advantages of the present disclosure more apparent and understandable, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present disclosure, and it is apparent that the described embodiments are only a part of the embodiments of the present disclosure, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments disclosed herein without making any creative effort, shall fall within the protection scope of the present disclosure.
Fig. 1 is a schematic diagram of dividing point cloud data by using a grid quadrilateral cutting algorithm, and as shown in fig. 1, in the existing method for measuring the volume of an object based on a laser radar, the method mainly scans a measured object 101 by using the laser radar to obtain point cloud data formed by points 102 on the surface of a plurality of measured objects, then divides the point cloud data by using the grid quadrilateral cutting algorithm to obtain a plurality of quadrilateral grids, and then calculates the volume of a quadrangular prism formed by the projection of each quadrilateral grid and the bottom surface of the grid, thereby obtaining the volume of the measured object. Specifically, fig. 2 is a schematic diagram of a point cloud volume envelope formed by dividing point cloud data by using a grid quadrilateral cutting algorithm, as shown in fig. 2, after the point cloud data is divided into a plurality of quadrilateral grids by using the grid quadrilateral cutting algorithm, the object 201 to be measured can be divided into a plurality of quadrangular prisms 202 according to the quadrilateral grids, and then the volume of the object 201 to be measured can be obtained by calculating the sum of the volumes of the quadrangular prisms 202. The grid quadrilateral cutting algorithm may be a regular grid division algorithm. However, when the surface undulation degree of the measured object is large, the quadrilateral grid obtained by using the grid quadrilateral cutting algorithm cannot accurately reflect the actual characteristics of the measured object, which may cause a large error of the volume of the measured object obtained by calculation.
Therefore, in order to improve the accuracy of the volume of the object to be measured, the present disclosure provides an object volume measuring method, apparatus, device, and storage medium. The method provided by the disclosure can be applied to electronic equipment such as computers, tablet computers and mobile phones.
The technical solutions of the embodiments of the present disclosure will be described below with reference to the drawings in the embodiments of the present disclosure.
Fig. 3 is a schematic flow chart of an implementation of a method for measuring a volume of an object according to an embodiment of the present disclosure, as shown in fig. 3, the method includes:
s301, point cloud data of the surface of the measured object is obtained.
The point cloud data is generated by data obtained by scanning the surface of the measured object by a preset radar. The preset radar can adopt a single-line laser radar, and the angle measurement range of the single-line laser radar can reach 120 degrees by 120 degrees, so that the angle measurement range is large, and the accuracy of scanning the measured object is higher.
In this embodiment, the laser radar driven by the two stepping motors may be used to scan the surface of the measured object, and generate the point cloud data of the surface of the measured object. Fig. 4 is a schematic diagram of an object volume measurement system provided in an embodiment of the present disclosure, where the object volume measurement system includes a ball machine with a wireless communication device and a laser radar, and an upper computer. The object volume measuring method provided by the embodiment of the disclosure is applied to an upper computer, and the upper computer can be electronic equipment such as a computer and a tablet computer.
As shown in fig. 4, the wireless communication device is installed outside the dome camera, the laser radar is installed in the dome camera, the laser radar can scan the surface of the measured object to generate point cloud data, the upper computer can send an instruction for acquiring the point cloud data to the dome camera through the wireless communication device, and the dome camera can send the generated point cloud data to the upper computer after receiving the instruction, so that the upper computer can determine the volume of the measured object according to the point cloud data.
In this embodiment, the point cloud data includes spatial coordinates of a plurality of points on the surface of the measured object. Fig. 5 is a schematic diagram of a point cloud provided by the embodiment of the present disclosure, as shown in fig. 5, a point cloud generated by scanning a surface of a measured object by a laser radar includes a plurality of points 501 on the surface of the measured object, and spatial coordinate data of the plurality of points 501 constitute point cloud data. In fig. 5, an x-axis, a y-axis, and a z-axis represent an abscissa axis, an ordinate axis, and an ordinate axis of a preset spatial coordinate system, wherein the x-axis and the y-axis are two coordinate axes located on the bottom surface of the measured object.
S302, dividing the point cloud data into a plurality of triangular meshes according to a preset division rule.
And any two vertexes of each triangular mesh are formed by two adjacent points in the point cloud data.
In this embodiment, the point cloud data is divided into a plurality of triangular meshes rather than the point cloud data into quadrangular meshes, so that the surface of the object to be measured can be divided more finely, and the triangular meshes can reflect the fluctuation degree of the object to be measured more than the quadrangular meshes, so that the determination of the volume of the object to be measured by using the triangular meshes is more accurate.
Specifically, the step of dividing the point cloud data into a plurality of triangular meshes according to a preset segmentation rule may include: and aiming at each point in the point cloud data, determining a triangle formed by two points which are adjacent to the point and are mutually adjacent to the point and the point as a triangular mesh, and obtaining a plurality of triangular meshes divided based on the point cloud data. For example, the point cloud data may be divided by using an irregular triangular mesh model to obtain a plurality of triangular meshes.
Fig. 6 is a schematic diagram of partitioning point cloud data by an irregular triangular mesh model according to an embodiment of the present disclosure, where as shown in fig. 6, points a, B, C, D, and E are all points in the point cloud data, and taking point a as an example, an irregular triangular mesh model may be used to partition triangles ABC, triangles ACD, and triangles ADE from the point cloud data.
And S303, determining the target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of the triangular mesh on the bottom surface of the measured object.
The projection height of each vertex of the triangular mesh on the bottom surface of the measured object is the height of the curved surface of the triangular mesh. In this embodiment, after the point cloud data is divided into a plurality of triangular meshes, the area of each triangular mesh multiplied by the average height of the mesh curved surface may be used to calculate the volume of a triangular prism formed by the projection of each triangular mesh and the triangular mesh itself on the bottom surface of the object to be measured, and then the sum of the volumes of the triangular prisms is used as the target volume of the object to be measured. That is, in this embodiment, the target volume of the object to be measured can be obtained by dividing the point cloud data into a plurality of triangular meshes and further dividing the object to be measured into a plurality of triangular prisms and then accumulating the volumes of all triangular prisms of the object to be measured, using the concept of infinitesimal elements. Since the triangular mesh infinitesimal is finer than the quadrangular mesh infinitesimal, the target volume of the object to be measured obtained by accumulating the volumes of the triangular prisms corresponding to the triangular meshes is also more accurate.
In an implementation, the determining a target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of the triangular mesh on the bottom surface of the measured object may include steps A1 to A4:
step A1, aiming at each triangular mesh, projecting the triangular mesh to the bottom surface of the measured object to obtain a projection triangle corresponding to the triangular mesh.
Fig. 7 is a schematic diagram of dividing partial point cloud data of a measured object according to the embodiment of the present disclosure, as shown in fig. 7, a point T i,k (x i,k ,y i,k ,z i,k )、T i,k+1 (x i,k+1 ,y i,k+1 ,z i,k+1 ) And T i+1,k (x i+1,k ,y i+1,k ,z i+1,k ) Is three points in the point cloud data, and point T' i,k 、T′ i,k+1 And T' i+1,k Are each T i,k 、T i,k+1 And T i+1,k Projected points in the xoy coordinate system. Namely triangular T' i,k T′ i,k+1 T′ i+1,k For triangular meshes T i,k T i,k+1 T i+1,k The corresponding projection triangle. Wherein the xoy coordinate system is a coordinate system established based on the bottom surface of the measured object.
And step A2, calculating the area of each triangular mesh, and calculating the projection height of each vertex of each triangular mesh on the bottom surface of the measured object.
Taking fig. 7 as an example, the following formula can be used to calculate the triangular mesh T i,k T i,k+1 T i+1,k Area of (d):
wherein,representing a triangular mesh T i,k T i,k+1 T i+1,k Area, x i,k 、y i,k And z i,k Are respectively a point T i,k Abscissa, ordinate and ordinate, x i,k+1 、y i,k+1 And z i,k+1 Are respectively a point T i,k+1 Abscissa, ordinate and ordinate, x i+1,k 、y i+1,k And z i+1,k Are respectively a point T i+1,k The abscissa, the ordinate, and the ordinate.
The projection height of each vertex of each triangular mesh on the bottom surface of the measured object is equal to the value of the vertical coordinate thereof, as shown in fig. 7, the triangular mesh T i,k T i,k+1 T i+1,k The projection heights of the three vertexes on the bottom surface of the measured object are vertical coordinate values z of the three vertexes i,k 、z i,k+1 And z i+1,k 。
And step A3, aiming at the triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh as the volume of the triangular prism.
Specifically, for a triangular prism formed by each triangular mesh and the corresponding projection triangle, the following formula may be adopted to calculate the product between the average value of the projection heights of the vertices of the triangular mesh and the area of the triangular mesh as the volume of the triangular prism:
wherein Δ V represents the volume of the triangular prism, T i,k 、T i,k+1 And T i+1,k Representing the three vertices of the triangular mesh,denotes the area, T 'of the triangular mesh' i,k 、T’ i,k+1 And T' i+1,k And representing projection points of three vertexes of the triangular mesh on the bottom surface of the measured object, wherein i represents the ith row in the point cloud data, and k represents the kth column in the point cloud data.
Will be provided withT i,k T′ i,k =z i,k 、T i+1,k T′ i+1,k =z i+1,k And T i,k+1 T′ i,k+1 =z i,k+1 Substituting the volume calculation formula into the volume calculation formula to further obtain the volume calculation formula of the triangular prism as follows:
the sum V of the volumes of the respective triangular prisms shown in fig. 7 k Comprises the following steps:
wherein n represents the total line number of the point cloud data.
And A4, calculating the sum of the volumes of the triangular prisms corresponding to the triangular meshes to serve as the target volume of the measured object.
In this embodiment, the sum of the volumes of the triangular prisms corresponding to all the triangular meshes divided based on the point cloud data of the object to be measured may be calculated, and the sum may be used as the target volume of the object to be measured.
In this embodiment, the target volume of the measured object can also be directly calculated by using the following formula:
wherein V represents a target volume of the object to be measured; n represents the total row number of the point cloud data; m represents the total row number of the point cloud data; x is a radical of a fluorine atom i,k 、y i,k And z i,k Respectively representing the abscissa, ordinate and ordinate of the point of the ith row and the kth column in the point cloud data; x is the number of i,k+1 、y i,k+1 And z i,k+1 Respectively representing the abscissa, ordinate and ordinate of the point of the ith row and the (k + 1) th column in the point cloud data; x is a radical of a fluorine atom i+1,k 、y i+1,k And z i+1,k Respectively are the abscissa, ordinate and ordinate of the point of the (i + 1) th row and the k column in the point cloud data.
Fig. 8 is a schematic diagram of a point cloud volume envelope formed by triangular meshes, as shown in fig. 8, the point cloud data of a measured object may be divided into a plurality of triangular meshes by using the concept of a infinitesimal element, to obtain a schematic diagram of a point cloud volume envelope corresponding to the measured object, and then, for each triangular mesh, a triangular prism formed by projection of the triangular mesh on a coordinate system xoy may be used to convert the volume of the measured object into the volumes of a plurality of triangular prisms, and then, the volume of each triangular prism may be calculated and accumulated, so as to obtain the volume of the measured object.
By adopting the method provided by the embodiment of the disclosure, the point cloud data is divided into a plurality of triangular meshes, and the target volume of the measured object can be determined by utilizing the area of each triangular mesh and the projection height of each vertex of the triangular mesh on the bottom surface of the measured object. The triangular mesh obtained by point cloud data segmentation can reflect the fluctuation degree of the surface of the measured object, namely the actual characteristics of the measured object, so that the target volume precision of the measured object determined by the triangular mesh is higher.
Based on the same inventive concept, according to the object volume measuring method provided by the above embodiment of the present disclosure, correspondingly, another embodiment of the present disclosure further provides an object volume measuring device, a schematic structural diagram of which is shown in fig. 9, specifically including:
a point cloud data obtaining module 901, configured to obtain point cloud data of a surface of an object to be measured, where the point cloud data is generated by data obtained by scanning the surface of the object to be measured by using a preset radar, and the point cloud data includes spatial coordinates of multiple points on the surface of the object to be measured;
a mesh dividing module 902, configured to divide the point cloud data into a plurality of triangular meshes according to a preset division rule, where any two vertices of each triangular mesh are formed by two adjacent points in the point cloud data;
and a volume determining module 903, configured to determine a target volume of the measured object based on an area of each triangular mesh and a projection height of each vertex of the triangular mesh on the bottom surface of the measured object.
In an implementation manner, the mesh dividing module 902 is specifically configured to determine, for each point in the point cloud data, a triangle formed by two points that are adjacent to the point and are adjacent to each other and the point as a triangle mesh, and obtain a plurality of triangle meshes divided based on the point cloud data.
In an implementation manner, the volume determining module 903 is specifically configured to, for each triangular mesh, project the triangular mesh onto the bottom surface of the object to be measured, so as to obtain a projection triangle corresponding to the triangular mesh; calculating the area of each triangular mesh, and calculating the projection height of each vertex of each triangular mesh on the bottom surface of the measured object; aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh to be used as the volume of the triangular prism; and calculating the sum of the volumes of the triangular prisms corresponding to the triangular meshes to serve as the target volume of the measured object.
In an implementation manner, the volume determining module 903 is specifically configured to, for each triangular prism formed by a triangular mesh and a corresponding projection triangle, calculate a product between an average value of projection heights of vertices of the triangular mesh and an area of the triangular mesh as a volume of the triangular prism by using the following formula:
wherein Δ V represents the volume of the triangular prism, T i,k 、T i,k+1 And T i+1,k Representing the three vertices of the triangular mesh,denotes the area, T 'of the triangular mesh' i,k 、T’ i,k+1 And T' i+1,k And representing projection points of three vertexes of the triangular mesh on the bottom surface of the measured object, wherein i represents the ith row in the point cloud data, and k represents the kth column in the point cloud data.
By adopting the device provided by the embodiment of the disclosure, the point cloud data is divided into a plurality of triangular meshes, and the target volume of the measured object can be determined by utilizing the area of each triangular mesh and the projection height of each vertex of each triangular mesh on the bottom surface of the measured object. The triangular mesh obtained by point cloud data segmentation can reflect the fluctuation degree of the surface of the measured object, namely the actual characteristics of the measured object, so that the target volume precision of the measured object determined by the triangular mesh is higher.
The present disclosure also provides an electronic device and a readable storage medium according to an embodiment of the present disclosure.
FIG. 10 shows a schematic block diagram of an example electronic device 1000 that can be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. Electronic devices may also represent various forms of mobile devices, such as personal digital processors, cellular telephones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not intended to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 10, the apparatus 1000 includes a computing unit 1001 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM) 1002 or a computer program loaded from a storage unit 1008 into a Random Access Memory (RAM) 1003. In the RAM 1003, various programs and data necessary for the operation of the device 1000 can also be stored. The calculation unit 1001, the ROM1002, and the RAM 1003 are connected to each other by a bus 1004. An input/output (I/O) interface 1005 is also connected to bus 1004.
A number of components in device 1000 are connected to I/O interface 1005, including: an input unit 1006 such as a keyboard, a mouse, and the like; an output unit 1007 such as various types of displays, speakers, and the like; a storage unit 1008 such as a magnetic disk, an optical disk, or the like; and a communication unit 1009 such as a network card, a modem, a wireless communication transceiver, or the like. The communication unit 1009 allows the device 1000 to exchange information/data with other devices through a computer network such as the internet and/or various telecommunication networks.
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, field Programmable Gate Arrays (FPGAs), application specific integrated circuits (AS ics), application Specific Standard Products (ASSPs), systems on a chip (SOCs), complex Programmable Logic Devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server may be a cloud server, a server of a distributed system, or a server with a combined blockchain.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and the present disclosure is not limited herein.
Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present disclosure, "a plurality" means two or more unless specifically limited otherwise.
The above description is only for the specific embodiments of the present disclosure, but the scope of the present disclosure is not limited thereto, and any person skilled in the art can easily think of the changes or substitutions within the technical scope of the present disclosure, and shall cover the scope of the present disclosure. Therefore, the protection scope of the present disclosure should be subject to the protection scope of the claims.
Claims (10)
1. A method of volumetric measurement of an object, the method comprising:
acquiring point cloud data of the surface of a measured object, wherein the point cloud data is generated by data obtained by scanning the surface of the measured object by a preset radar, and the point cloud data comprises spatial coordinates of a plurality of points on the surface of the measured object;
dividing the point cloud data into a plurality of triangular meshes according to a preset segmentation rule, wherein any two vertexes of each triangular mesh are formed by two adjacent points in the point cloud data;
and determining the target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of the triangular mesh on the bottom surface of the measured object.
2. The method of claim 1, wherein the dividing the point cloud data into a plurality of triangular meshes according to a preset segmentation rule comprises:
and aiming at each point in the point cloud data, determining a triangle formed by two points which are adjacent to the point and are mutually adjacent to the point and the point as a triangular mesh, and obtaining a plurality of triangular meshes divided based on the point cloud data.
3. The method of claim 1, wherein determining the target volume of the object to be measured based on the area of each triangular mesh and the projected height of each vertex of the triangular mesh on the bottom surface of the object to be measured comprises:
projecting the triangular mesh to the bottom surface of the measured object aiming at each triangular mesh to obtain a projection triangle corresponding to the triangular mesh;
calculating the area of each triangular mesh, and calculating the projection height of each vertex of each triangular mesh on the bottom surface of the measured object;
aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh to be used as the volume of the triangular prism;
and calculating the sum of the volumes of the triangular prisms corresponding to the triangular meshes to serve as the target volume of the measured object.
4. The method according to claim 3, wherein calculating, for each triangular prism formed by the triangular mesh and the corresponding projection triangle, a product between an average value of projection heights of respective vertices of the triangular mesh and an area of the triangular mesh as a volume of the triangular prism comprises:
aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh by adopting the following formula as the volume of the triangular prism:
wherein Δ V represents the volume of the triangular prism, T i,k 、T i,k+1 And T i+1,k Representing the three vertices of the triangular mesh,denotes the area, T 'of the triangular mesh' i,k 、T’ i,k+1 And T' i+1,k And representing projection points of three vertexes of the triangular mesh on the bottom surface of the measured object, wherein i represents the ith row in the point cloud data, and k represents the kth column in the point cloud data.
5. An object volume measuring device, characterized in that the device comprises:
the system comprises a point cloud data acquisition module, a point cloud data acquisition module and a data processing module, wherein the point cloud data acquisition module is used for acquiring point cloud data of the surface of a measured object, the point cloud data is generated by data obtained by scanning the surface of the measured object by a preset radar, and the point cloud data comprises spatial coordinates of a plurality of points on the surface of the measured object;
the mesh division module is used for dividing the point cloud data into a plurality of triangular meshes according to a preset division rule, wherein any two vertexes of each triangular mesh are formed by two adjacent points in the point cloud data;
and the volume determining module is used for determining the target volume of the measured object based on the area of each triangular mesh and the projection height of each vertex of each triangular mesh on the bottom surface of the measured object.
6. The apparatus according to claim 5, wherein the mesh partitioning module is specifically configured to determine, for each point in the point cloud data, two points that are adjacent to the point and are adjacent to each other, and a triangle formed by the two points as a triangle mesh, so as to obtain a plurality of triangle meshes partitioned based on the point cloud data.
7. The apparatus according to claim 5, wherein the volume determination module is specifically configured to, for each triangular mesh, project the triangular mesh onto the bottom surface of the object to be measured, so as to obtain a projection triangle corresponding to the triangular mesh; calculating the area of each triangular mesh, and calculating the projection height of each vertex of each triangular mesh on the bottom surface of the measured object; aiming at a triangular prism formed by each triangular mesh and the corresponding projection triangle, calculating the product of the average value of the projection height of each vertex of the triangular mesh and the area of the triangular mesh to be used as the volume of the triangular prism; and calculating the sum of the volumes of the triangular prisms corresponding to the triangular meshes to serve as the target volume of the measured object.
8. The apparatus according to claim 7, wherein the volume determination module is specifically configured to, for each triangular prism formed by a triangular mesh and a corresponding projection triangle, calculate a product between an average value of projection heights of respective vertices of the triangular mesh and an area of the triangular mesh as a volume of the triangular prism by using the following formula:
wherein Δ V represents the volume of the triangular prism, T i,k 、T i,k+1 And T i+1,k Representing the three vertices of the triangular mesh,denotes the area, T 'of the triangular mesh' i,k 、T’ i,k+1 And T' i+1,k And representing projection points of three vertexes of the triangular mesh on the bottom surface of the measured object, wherein i represents the ith row in the point cloud data, and k represents the kth column in the point cloud data.
9. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-4.
10. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of any one of claims 1-4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211192674.7A CN115908536A (en) | 2022-09-28 | 2022-09-28 | Object volume measuring method, device, equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211192674.7A CN115908536A (en) | 2022-09-28 | 2022-09-28 | Object volume measuring method, device, equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN115908536A true CN115908536A (en) | 2023-04-04 |
Family
ID=86473310
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211192674.7A Pending CN115908536A (en) | 2022-09-28 | 2022-09-28 | Object volume measuring method, device, equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115908536A (en) |
-
2022
- 2022-09-28 CN CN202211192674.7A patent/CN115908536A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3910543A2 (en) | Method for training object detection model, object detection method and related apparatus | |
CN113077548A (en) | Collision detection method, device, equipment and storage medium for object | |
CN116030103B (en) | Method, device, apparatus and medium for determining masonry quality | |
CN117760402A (en) | Hanging basket posture adjustment method, device, equipment and storage medium | |
CN113029136A (en) | Method, apparatus, storage medium, and program product for positioning information processing | |
CN115908536A (en) | Object volume measuring method, device, equipment and storage medium | |
CN108931213B (en) | Flatness detection method, device, equipment and storage medium | |
CN114565683B (en) | Precision determination method, device, equipment, medium and product | |
CN114812576A (en) | Map matching method and device and electronic equipment | |
CN115049590A (en) | Image processing method and device, electronic equipment and storage medium | |
CN114972511A (en) | Method and device for determining pose of calibration object, electronic equipment and storage medium | |
CN115153632A (en) | Ultrasonic imaging positioning system, method, device, equipment and storage medium | |
CN114596362A (en) | High-point camera coordinate calculation method and device, electronic equipment and medium | |
CN114565721A (en) | Object determination method, device, equipment, storage medium and program product | |
CN114647816A (en) | Method, device and equipment for determining lane line and storage medium | |
CN117119160B (en) | Projection control method and device, electronic equipment and storage medium | |
CN114509813B (en) | Method and device for determining coal seam thickness based on trough waves and electronic equipment | |
CN116152326B (en) | Distance measurement method and device for three-dimensional model, electronic equipment and storage medium | |
CN114581647B (en) | Confidence post-processing method, device, equipment and storage medium | |
CN114419187B (en) | Map construction method and device, electronic equipment and readable storage medium | |
CN115002906B (en) | Object positioning method, device, medium and computing equipment | |
CN117193566B (en) | Touch screen detection method and device, electronic equipment and storage medium | |
CN115984176A (en) | High-precision map environment change detection method, device and equipment and automatic driving vehicle | |
CN118298027A (en) | Calibration device, external parameter calibration method and device, electronic equipment and storage medium | |
CN117742243A (en) | Equipment action collision prediction method and device, electronic equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |