WO2022226995A1 - 基于有序点集的处理方法、处理装置及电子设备 - Google Patents

基于有序点集的处理方法、处理装置及电子设备 Download PDF

Info

Publication number
WO2022226995A1
WO2022226995A1 PCT/CN2021/091468 CN2021091468W WO2022226995A1 WO 2022226995 A1 WO2022226995 A1 WO 2022226995A1 CN 2021091468 W CN2021091468 W CN 2021091468W WO 2022226995 A1 WO2022226995 A1 WO 2022226995A1
Authority
WO
WIPO (PCT)
Prior art keywords
point
ordered
subsequent
points
type
Prior art date
Application number
PCT/CN2021/091468
Other languages
English (en)
French (fr)
Inventor
刘双岭
Original Assignee
北京城市网邻信息技术有限公司
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 北京城市网邻信息技术有限公司 filed Critical 北京城市网邻信息技术有限公司
Priority to PCT/CN2021/091468 priority Critical patent/WO2022226995A1/zh
Publication of WO2022226995A1 publication Critical patent/WO2022226995A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles

Definitions

  • Embodiments of the present disclosure relate to a processing method, a processing apparatus, and an electronic device based on an ordered point set.
  • one of the focuses of shape analysis is how to effectively extract the discriminative shape features of objects and use them for subsequent tasks such as recognition, classification, and retrieval.
  • Human vision is very sensitive to the contour of the target or its corners, and even the two-dimensional contour of the target or its corners can transmit enough shape information to the human visual system to identify it accurately. Human vision only needs to rely on the contour of the target, and even when the contour of the obtained target is incomplete, it can correctly identify the target. Therefore, in many cases, it is only necessary to analyze the boundary pixels of the target to extract the shape features with strong identification ability.
  • a processing method based on an ordered point set includes: selecting a point in the ordered point set as a starting point; based on a predetermined search direction, searching in the ordered point set to determine a first subsequent point of the starting point, and based on the predetermined search direction, in the Searching in an ordered set of points to determine a second follow-up point of the first follow-up point; and identifying a point of the first follow-up point based on the positional relationship between the starting point, the first follow-up point, and the second follow-up point type, where the point type is one of a convex or concave point type.
  • the ordered set of points corresponds to the outline of an image (eg, a graphic, such as a floor plan).
  • the method further includes: using the first subsequent point as an update starting point, using the second subsequent point as updating the first subsequent point, and repeating the following operations until a stopping condition is satisfied: based on the predetermined search direction, search in the ordered point set to determine the update second follow-up point of the update first follow-up point; based on the positional relationship between the update start point, the update first follow-up point, and the update second follow-up point identifying the point type of the updated first follow-up point; and using the updated first follow-up point as the update start point and the updated second follow-up point as the update first follow-up point.
  • the stopping condition includes at least one of: no point is found in the ordered set of points in the search direction, the update starting point is the same as the starting point, or all of the ordered point set The point type of the point is recognized.
  • identifying the point type of the first subsequent point based on the positional relationship among the starting point, the first subsequent point, and the second subsequent point includes: based on the starting point and the second subsequent point The relative position of the vector formed by the point and the first subsequent point identifies the point type of the first subsequent point.
  • identifying the point type of the first follow-up point based on the relative position of the vector formed by the starting point and the second follow-up point and the first follow-up point includes: when the first follow-up point is located in the When the vector and the remaining points in the ordered set of points are within the closed contour formed by the remaining points other than the first subsequent point, identifying the point type of the first subsequent point as a concave point type; and/or when the first subsequent point is located in the When the vector and the remaining points in the ordered set of points are outside the closed contour formed by the remaining points other than the first subsequent point, the point type of the first subsequent point is identified as a convex point type.
  • the starting point is one of one or more corner points in the shape outline of the image
  • the one or more corner points include the first point in the convex point set of the ordered point set.
  • One or more bumps located at the edge in one direction or the second direction, the first direction and the second direction being perpendicular to each other.
  • the starting point is a corner point with the smallest abscissa and the smallest ordinate among the one or more corner points.
  • it also includes presenting in the image points of the point type identified in the ordered point set that are of the concave point type.
  • the lookup direction is one of a clockwise direction or a counterclockwise direction.
  • a processing apparatus based on an ordered point set includes: a starting point selection module configured to select a point in the ordered point set as a starting point; and a point type identification module configured to: based on a predetermined search direction, search in the ordered point set to determine A first follow-up point to the starting point, and based on the predetermined search direction, searches in the ordered set of points to determine a second follow-up point to the first follow-up point, and based on the starting point, the first follow-up point, and the The positional relationship between the second subsequent points identifies the point type of the first subsequent point, where the point type is one of a convex point type or a concave point type.
  • the ordered set of points corresponds to the outline of an image (e.g., a graphic, such as a floor plan).
  • the point type identification module is further configured to: use the first subsequent point as an update starting point, use the second subsequent point as an update first subsequent point, and repeat the following operations until the stopping condition is satisfied : based on the search direction, search in the ordered point set to determine the update second follow-up point of the update first follow-up point, based on the update start point, the update first follow-up point, and the update second follow-up point.
  • the positional relationship is used to identify the point type of the update first follow-up point, and the update first follow-up point as the update start point and the update second follow-up point as the update first follow-up point.
  • the stopping condition includes at least one of: no point is found in the set of points in the search direction, an update starting point is the same as the starting point, or a point for all points in the set of points types are recognized.
  • the processing device further includes a concave point presentation module configured to: present in the image the points whose point types identified in the ordered point set are concave point types.
  • the point type identification module includes a point type identification sub-module configured to: identify the first subsequent point based on the relative position of the vector formed by the starting point and the second subsequent point and the first subsequent point The point type of a subsequent point.
  • the point type identification sub-module is configured to: when the first subsequent point is located outside the closed contour formed by the vector and the remaining points in the set of points other than the first subsequent point, identify The first subsequent point is a convex point; and/or when the first subsequent point is located within the closed contour formed by the vector and the remaining points in the set of points other than the first subsequent point, identifying the first subsequent point as Pits.
  • the starting point is a corner point in the shape outline
  • the corner point is a convex point at an edge position in the first direction or the second direction in the convex point set of the point set
  • the first direction and the second direction are perpendicular to each other.
  • the lookup direction is one of a clockwise direction or a counterclockwise direction.
  • an electronic device includes: one or more processors; and memory for storing one or more computer programs that, when executed by the one or more processors, cause the one or more processors to execute One or more operations in the processing method described above.
  • the electronic device further includes a display configured to present in the image points of the identified point type as pit type.
  • a computer-readable storage medium on which one or more computer programs are stored, and when the one or more computer programs are executed by a processor, execute the processing method described above. one or more operations.
  • FIG. 1 shows a schematic diagram of an image (or graph) and a set of points corresponding to the image (or graph) according to some embodiments of the present disclosure
  • FIG. 2 shows a flowchart of a processing method based on an ordered point set according to at least one embodiment of the present disclosure
  • FIG. 3 shows a schematic diagram of a processing method based on an ordered point set according to at least one embodiment of the present disclosure
  • FIG. 4 shows a schematic structural diagram of an ordered point set-based processing apparatus according to at least one embodiment of the present disclosure.
  • FIG. 5 shows a block diagram of an electronic device according to an embodiment of the present disclosure
  • FIG. 6 shows a block diagram of an electronic device according to an embodiment of the present disclosure.
  • the point type of each point in the point set may include a concave point type or a convex point type.
  • the definition of the point type please refer to the following description.
  • the designer can perform interior design or perform intelligent assisted design based on the point type of each point in the point set of the image outline , so it can be convenient for designers to design, thereby reducing the workload of designers. For example, by providing (eg, presenting) to a user an image (eg, a graphic) with a particular type of point (eg, a pit), the user can be directly and clearly aware of a feature (eg, angle) of the image (eg, graphic) point).
  • a feature eg, angle
  • the type of points in the ordered point set can be determined (eg, identified) by deleting a point in the ordered point set and comparing the area of the contour formed by the remaining points with the ordered point set before deletion
  • the area of the contour composed of the points is used to determine the type of the point.
  • this method is computationally expensive and can only determine (eg, identify) the type of one point at a time. Therefore, the computational efficiency is low.
  • the embodiments of the present disclosure propose a processing method, processing apparatus and electronic device based on an ordered point set.
  • a processing method based on a point set includes: selecting a point in an ordered point set as a starting point; based on a predetermined search direction, searching in the ordered point set to determine the first point of the starting point a follow-up point, and based on the predetermined search direction, searching in the ordered set of points to determine a second follow-up point of the first follow-up point; and based on any of the starting point, the first follow-up point, and the second follow-up point
  • the positional relationship between the points is used to identify the point type of the first subsequent point, wherein the point type is one of a convex point type or a concave point type.
  • the processing method can process the ordered point set to obtain the point type of each point in the ordered point set.
  • points with a specific type eg, a concave point type
  • an ordered point set may be presented to facilitate interior design or smart-assisted design based on the identified point type, which can facilitate designers Design, thereby reducing the workload of designers.
  • a specific type eg, a concave point type
  • the user can be directly and clearly aware of a feature (eg, angle) of the image (eg, graphic) point).
  • an ordered point set may refer to a set composed of a plurality of ordered points.
  • an ordered set of points may correspond to the contours of an image.
  • the images may include two-dimensional images or three-dimensional images.
  • the outline of the image may be a two-dimensional figure such as a right-angled polygon.
  • it can be converted into a two-dimensional image and then processed using methods provided in accordance with various embodiments of the present disclosure.
  • various known methods can be employed to convert a three-dimensional image into a two-dimensional image.
  • Types of points in a point set may include concave points (also called concave vertices) and convex points (also called convex vertices).
  • the ordered set of points may include a set of concave points and a set of convex points, wherein the set of concave points includes at least one concave point, and the set of convex points includes at least one convex point.
  • the types of points in an ordered point set include only concave and convex types.
  • the type of the point in a graph corresponding to an ordered point set, when a certain point is the intersection point and the interior angle formed by two right-angled sides of the graph is smaller than the exterior angle, the type of the point is a convex point.
  • the interior angle formed by two right-angled sides of the graph with a point as the intersection point is greater than the exterior angle, the type of the point is concave.
  • the convex point at the edge position in the first direction or the second direction may be referred to as a corner point.
  • the corner points may include: the set of convex points with the smallest abscissa, and the convex point with the largest or smallest ordinate; the set of convex points with the largest abscissa, and the convex point with the largest or smallest ordinate; The convex point with the smallest ordinate is concentrated, and the convex point with the largest or smallest abscissa; the convex point with the largest ordinate is concentrated, and the convex point with the largest or smallest abscissa.
  • FIG. 1 shows a schematic diagram of an image (or graph) and an ordered set of points corresponding to the image (or graph) according to some embodiments of the present disclosure.
  • the convex points include A, B, D, E, G, H, I
  • the pits include C, F, J. Therefore, the convex point set is ⁇ A,B,D,E,G,H,I ⁇ , and the concave point set is ⁇ C,F,J ⁇ .
  • the graph corresponding to the ordered point set is a right-angled polygon formed by connecting the points in the point set in a certain order, for example, as shown by the dotted line in FIG.
  • an ordered point set may include a sequential point set and a reversed point set.
  • the sequential point set may refer to the point set ⁇ J,I,H,G,F,E,D,C,B,A ⁇ formed in the clockwise direction, and the reversed order point set may be in the counterclockwise direction
  • the formed point set ⁇ A,B,C,D,E,F,G,H,I,J ⁇ .
  • the subsequent points (eg, point B) of the point (eg, point A) may be in a predetermined direction (eg, counterclockwise) The point immediately following the point.
  • FIG. 1 What has been described above in conjunction with FIG. 1 is only an example of an ordered set of points related to an image outline (or graphic outline). However, the embodiments of the present disclosure are not limited thereto, and the embodiments of the present disclosure may be applied to other ordered point sets having similar shapes.
  • FIG. 2 shows a flowchart of a processing method 200 based on an ordered point set according to at least one embodiment of the present disclosure.
  • step S210 a point is selected as a starting point in the ordered point set.
  • step S210 may further include determining (eg, acquiring or receiving) an ordered set of points.
  • the ordered set of points can characterize the contours of the image.
  • the outline is a right-angled polygon.
  • step S210 may further include determining whether the number of points in the ordered point set is an even number greater than a predetermined threshold (eg, 4). If it is determined that the number of points in the ordered point set is an even number greater than a predetermined threshold (eg, 4), it can be determined that the contour of the image is a right-angled polygon, and the subsequent operation is continued, otherwise the operation is ended.
  • a predetermined threshold eg, 4
  • the ordered set of points may correspond to the shape contour of the image.
  • the shape outline may be the outline of an image, such as a two-dimensional image or a three-dimensional image.
  • the image may include a floor plan.
  • the floor plan may include a 2-dimensional (2D) floor plan or a 3-dimensional (3D) floor plan (alternatively, referred to as a three-dimensional floor plan).
  • the two-dimensional floor plan may be a flat floor plan of a house
  • the three-dimensional floor plan may be a three-dimensional model of the house.
  • the two-dimensional or three-dimensional floor plan can represent the various subspaces of the residence (for example, living room subspace, master bedroom subspace, secondary bedroom subspace, balcony subspace, toilet subspace, kitchen subspace, etc.) and the size of each subspace. location, etc.
  • a two-dimensional floor plan or a three-dimensional floor plan may be (alternatively, transformed or approximated) one or more right-angled polygons.
  • a three-dimensional floor plan it can be converted into a two-dimensional floor plan (ie, a flat floor plan), and then processed using the methods provided according to various embodiments of the present disclosure.
  • various known methods can be used to convert a three-dimensional floor plan into a two-dimensional floor plan, which is not limited by the embodiments of the present disclosure.
  • the shape outline may be a two-dimensional figure such as a right-angled polygon.
  • a right-angled polygon can refer to a polygon in which all angles are right angles.
  • the starting point may be selected from one or more corner points in the shape outline, the one or more corner points comprising the convex point set of the ordered point set in the first direction or the second direction
  • One or more bumps at the edge position, the first direction and the second direction are perpendicular to each other.
  • the first direction may be the X-axis direction
  • the second direction may be the Y-axis direction.
  • the starting point is a corner point with the smallest abscissa and the smallest ordinate among the one or more corner points.
  • At least one of the following methods can be used to determine the concave point set and the convex point set of the ordered point set: convex hull method, angle method, left and right point method, vector area method, vector product method, ray method , the slope method, and the pole order method. It should be noted that the embodiments of the present disclosure do not limit the method for determining the concave point set and the convex point set, and various known methods can be used to determine the concave point set and the convex point set.
  • step S220 based on a predetermined search direction, the ordered point set is searched to determine the first subsequent point of the starting point, and based on the predetermined search direction, the ordered point set is searched to determine the first subsequent point.
  • the second follow-up point of a follow-up point is searched to determine the first subsequent point.
  • the predetermined search direction is one of a clockwise direction or a counterclockwise direction.
  • step S230 the point type of the first follow-up point is identified based on the positional relationship between the starting point, the first follow-up point, and the second follow-up point, wherein the point type is a convex point type or a concave point type One of the point types.
  • identifying the point type of the first subsequent point based on the positional relationship among the starting point, the first subsequent point, and the second subsequent point includes: forming based on the starting point and the second subsequent point The relative position of the vector of and the first subsequent point to identify the point type of the first subsequent point.
  • the point type of the first subsequent point when the first subsequent point is located within a closed contour formed by the vector and the remaining points in the ordered set of points except the first subsequent point, the point type of the first subsequent point is identified as concave point type. On the contrary, when the first subsequent point is located outside the closed contour formed by the vector and the remaining points other than the first subsequent point in the ordered set of points, the point type of the first subsequent point is identified as a convex point type.
  • the relative position of the vector formed by the starting point and the second subsequent point and the first subsequent point can be simply and quickly identified.
  • the point type reduces the complexity of identifying the type of points in the ordered point set corresponding to the image contour, and saves computing resources.
  • the method 200 further includes: using the first subsequent point as an update starting point, using the second subsequent point as updating the first subsequent point, and repeating the following operations until a stopping condition is satisfied: based on the predetermined search direction, Search in the ordered set of points to determine the update second follow-up point of the update first follow-up point; identify the update start point based on the positional relationship between the update start point, the update first follow-up point, and the update second follow-up point updating the point type of the first follow-up point; and updating the first follow-up point as the update start point and updating the second follow-up point as the update first follow-up point.
  • the point type of each point in the ordered point set can be identified.
  • the stopping condition may include at least one of: no point is found in the ordered set of points in the seek direction, the update starting point is the same as the starting point, or a point of all points in the ordered set of points types are recognized. For example, if no point is found in the ordered point set in the search direction, it means that the search fails, and it can be considered that the execution of the identification method fails. If the update starting point is the same as the starting point, or the point type is identified for all points in the ordered set of points, the method is complete and subsequent steps can be performed, eg, storing or rendering points of a particular type. Through this cyclic manner, the types of multiple points (eg, all points) in the ordered point set corresponding to the image contour can be quickly identified, thus reducing the processing complexity and saving computing resources.
  • method 200 further includes storing points of a particular type (eg, a pit type) of the identified point types in the ordered set of points.
  • a particular type eg, a pit type
  • method 200 further includes outputting points of a particular type (eg, a pit type) identified in the ordered set of points.
  • a particular type eg, a pit type
  • method 200 further includes presenting (eg, via a display) in the image points of a particular type (eg, pit type) of point types identified in the ordered set of points.
  • presenting points of the pit type identified in the ordered set of points may include highlighting the points of the pit type.
  • presenting a point of the concave point type identified in the ordered set of points may include displaying a specific indicator (eg, a graphic having a specific shape) adjacent to the point of the concave point type to indicate that the point is of the concave point type.
  • the type is the pit type.
  • presenting a point whose point type identified in the ordered point set is a concave point type may include displaying indication information on or near the point indicating that the point type of a certain point is a concave point type.
  • embodiments of the present disclosure are not limited thereto, and any way may be used to present points of a particular type (eg, a pit type) identified in the ordered set of points.
  • presenting points with a specific type (eg, concave point type) in an ordered set of points it is possible to enable designers to perform interior design or intelligently assisted design based on the identified point types, which can facilitate designers to design, thereby reducing the need for designers workload.
  • the user can be directly and clearly aware of a feature (eg, angle) of the image (eg, graphic) point).
  • a feature eg, angle
  • the type of the point is determined by deleting a certain point in the ordered point set, forming the remaining points into a contour, and then judging the relative positional relationship between the point and the contour. In this way, the types of points in the ordered point set can be quickly identified, reducing the time complexity of the operation.
  • FIG. 3 shows a flowchart of a processing method 300 based on an ordered point set according to at least one embodiment of the present disclosure.
  • processing method 300 may be based on processing method 200 .
  • the description with reference to FIG. 2 may also be applied to various embodiments of the processing method 300 described in connection with FIG. 3 .
  • step S310 it is determined whether the number of points in the ordered point set is an even number greater than a predetermined threshold (eg, 4).
  • a predetermined threshold eg, 4
  • the ordered set of points may correspond to the shape contour of the image.
  • the shape outline may be the outline of an image, such as a two-dimensional image or a three-dimensional image.
  • the image may include a floor plan.
  • the floor plan may include a 2-dimensional (2D) floor plan or a 3-dimensional (3D) floor plan (alternatively, referred to as a three-dimensional floor plan).
  • the two-dimensional floor plan may be a flat floor plan of a house
  • the three-dimensional floor plan may be a three-dimensional model of the house.
  • the two-dimensional or three-dimensional floor plan can represent the various subspaces of the residence (for example, living room subspace, master bedroom subspace, secondary bedroom subspace, balcony subspace, toilet subspace, kitchen subspace, etc.) and the size of each subspace. location, etc.
  • the two-dimensional floor plan may be (or, be approximated as) a right-angled polygon.
  • a three-dimensional floor plan it can be converted into a two-dimensional floor plan (ie, a flat floor plan), and then processed using the methods provided according to various embodiments of the present disclosure.
  • various known methods can be used to convert the three-dimensional floor plan into a two-dimensional floor plan, which is not limited by the embodiments of the present disclosure.
  • the shape outline may be a two-dimensional figure such as a right-angled polygon.
  • a right-angled polygon can refer to a polygon in which all angles are right angles.
  • At least one of the following methods can be used to determine the concave point set and the convex point set of the ordered point set: convex hull method, angle method, left and right point method, vector area method, vector product method, ray method , the slope method, and the pole order method. It should be noted that the embodiments of the present disclosure do not limit the method for determining the concave point set and the convex point set, and various known methods can be used to determine the concave point set and the convex point set.
  • step S320 a point is selected as a starting point in the ordered point set.
  • the starting point may be selected from one or more corner points in the shape outline, the one or more corner points comprising the convex point set of the ordered point set in the first direction or the second direction
  • One or more bumps at the edge position, the first direction and the second direction are perpendicular to each other.
  • the first direction may be the X-axis direction
  • the second direction may be the Y-axis direction.
  • the starting point is a corner point with the smallest abscissa and the smallest ordinate among the one or more corner points.
  • step S330 based on a predetermined search direction, search in the ordered point set to determine the first follow-up point of the starting point, and based on the predetermined search direction, search in the ordered point set to determine the first follow-up point The second subsequent point of the point.
  • the predetermined search direction is one of a clockwise direction or a counter-clockwise direction.
  • step S340 the point type of the first follow-up point is identified based on the positional relationship among the starting point, the first follow-up point, and the second follow-up point, wherein the point type is a convex point type or a concave point type One of the point types.
  • identifying the point type of the first subsequent point based on the positional relationship among the starting point, the first subsequent point, and the second subsequent point includes: forming based on the starting point and the second subsequent point The relative position of the vector of and the first subsequent point to identify the point type of the first subsequent point.
  • the point type of the first subsequent point when the first subsequent point is located within a closed contour formed by the vector and the remaining points in the ordered set of points except the first subsequent point, the point type of the first subsequent point is identified as concave point type. On the contrary, when the first subsequent point is located outside the closed contour formed by the vector and the remaining points other than the first subsequent point in the ordered set of points, the point type of the first subsequent point is identified as a convex point type.
  • the relative position of the vector formed by the starting point and the second subsequent point and the first subsequent point can be simply and quickly identified.
  • the point type reduces the complexity of identifying the type of edge and corner points of the image and saves computing resources.
  • step S350 the first follow-up point is used as an update starting point, and the second follow-up point is used as an update first follow-up point.
  • step S360 based on the predetermined search direction, search is performed in the ordered point set to determine the updated second subsequent point of the updated first subsequent point.
  • step S370 the point type of the updated first subsequent point is identified based on the positional relationship among the updated starting point, the updated first subsequent point, and the updated second subsequent point.
  • identifying the point type of the update first follow-up point based on the positional relationship among the update start point, the update first follow-up point, and the update second follow-up point includes: based on the update start point and The relative position of the vector formed by the updated second subsequent point and the updated first subsequent point identifies the point type of the first subsequent point.
  • the point type of the first subsequent point is identified when the updated first subsequent point is located within a closed contour formed by the vector and the remaining points in the ordered set of points other than the updated first subsequent point is a pit type. On the contrary, when the updated first subsequent point is located outside the closed contour formed by the vector and the remaining points other than the first subsequent point in the ordered set of points, the point type of the updated first subsequent point is identified as a convex point type .
  • step S380 it is determined whether the stop condition is satisfied. If the stop condition is satisfied, the method 300 is ended, otherwise step S390 is executed.
  • the stopping condition may include at least one of: no point is found in the ordered set of points in the seek direction, the update starting point is the same as the starting point, or a point of all points in the ordered set of points types are recognized.
  • step S390 the updated first follow-up point is taken as the update start point and the updated second follow-up point is taken as the updated first follow-up point, and the process returns to step S360.
  • the point type of each point in the ordered point set can be determined (eg, identified).
  • the types of multiple points (eg, all points) in the ordered point set corresponding to the image contour can be quickly identified, thus reducing the processing complexity and saving computing resources.
  • method 300 further includes (eg, when a stopping condition is satisfied) storing or outputting points of a particular type (eg, pit type) identified in the ordered set of points.
  • a stopping condition e.g., a stopping condition
  • points of a particular type e.g, pit type
  • method 300 further includes presenting, via a display, points of a particular type (eg, pit type) of the identified point types in the ordered set of points in the image (eg, when a stop condition is satisfied).
  • presenting the points whose point types identified in the ordered set of points are of the concave point type may include highlighting the points of the concave point type.
  • presenting the points of the concave point type identified in the ordered set of points may include displaying a specific indicator (eg, a graphic of a specific shape, such as a circle) adjacent to the point type of the concave point type to indicate the point of the concave point type.
  • the point type is the concave point type.
  • presenting a point whose point type identified in the ordered point set is a concave point type may include displaying indication information on or near the point indicating that the point type of a certain point is a concave point type.
  • embodiments of the present disclosure are not limited thereto, and any way may be used to present points of a particular type (eg, a pit type) identified in the ordered set of points.
  • presenting points with a specific type (eg, concave point type) in an ordered set of points it is possible to enable designers to perform interior design or intelligently assisted design based on the identified point types, which can facilitate designers to design, thereby reducing the need for designers workload.
  • the type of the point is determined by deleting a certain point in the ordered point set, forming the remaining points into a contour, and then judging the relative positional relationship between the point and the contour. In this way, the types of points in the ordered point set can be quickly identified, reducing the time complexity of the operation.
  • the processing method based on an ordered point set according to at least one embodiment of the present disclosure is described above with reference to FIG. 2 and FIG. 3 .
  • the processing method described above in connection with FIG. 2 or FIG. 3 will be used below in conjunction with FIG. 4 to determine (eg, identify) the type of each point in the particular point set in FIG. 1 .
  • the determined ordered point set is ⁇ A,B,C,D,E,F,G,H,I,J ⁇
  • the convex point set is ⁇ A,B,D,E,G, H,I ⁇
  • the concave point set is ⁇ C,F,J ⁇
  • the graph outline corresponding to the point set ⁇ A,B,C,D,E,F,G,H,I,J ⁇ is a right-angled polygon.
  • an X-Y rectangular coordinate system as shown in FIG. 4 is established, and the point set is mapped to the X-Y rectangular coordinate system. It should be noted that the embodiments of the present disclosure are not limited to the image (or graph) shown in FIG. 4 , and can be applied to an image (or graph) whose outline is any shape.
  • a predetermined threshold eg, 4
  • the contour of the image is a right-angled polygon, and the following steps are continued.
  • corner point A can be selected as the starting point.
  • a predetermined search direction eg, counterclockwise
  • search in the ordered point set to determine the first subsequent point (point B) of the starting point and based on the predetermined search direction, in the ordered point set A search is made to determine the second subsequent point (point C) of the first subsequent point (point B).
  • the predetermined search direction is one of clockwise or counterclockwise.
  • various embodiments will be described with a counterclockwise direction as the search direction.
  • the clockwise direction is used as the search direction, a processing method similar to that of the described embodiment can be adopted.
  • the point of the first subsequent point (point B) is identified based on the positional relationship between the starting point (point A), the first subsequent point (point B), and the second subsequent point (point C) type, where the point type is one of a convex or concave point type.
  • the point type of the first subsequent point (point B) is the bump type.
  • the stopping condition may include at least one of the following: no point is found in the ordered point set in the search direction, the update start point is the same as the start point, or the point types of all points in the ordered point set are identified. Since the stop condition is not met, proceed with the following steps.
  • the first follow-up point (point B) is used as the update starting point
  • the second follow-up point (point C) is used as the update first follow-up point.
  • a search is made in the ordered set of points to determine the updated second subsequent point (point D) of the updated first subsequent point (point C).
  • the point type of the update first follow-up point is identified .
  • the update first subsequent point (point C) is located in the vector formed by the update starting point (point B) and the updated second subsequent point (point D) (ie, the vector BD formed by point B and point D)
  • the closed contour formed with the remaining points in the ordered set of points except the updated first subsequent point (point C) i.e., the closed contour formed by sequentially connecting the vectors BD, points E, F, G, H, I, J, A Contour
  • the point type of the updated first subsequent point (point C) can be identified as a concave point type.
  • the stopping condition may include at least one of the following: no point is found in the ordered point set in the search direction, the update start point is the same as the start point, or the point types of all points in the ordered point set are identified. Since the stop condition is not met, proceed with the following steps.
  • the update first follow-up point (point C) is used as the update start point
  • the update second follow-up point (point D) is used as the update first follow-up point.
  • a search is made in the ordered set of points to determine the updated second subsequent point (point E) of the updated first subsequent point (point D).
  • the updated first subsequent point (point D) is identified based on the positional relationship between the updated starting point (point C), the updated first subsequent point (point D), and the updated second subsequent point (point E). ) point type. Specifically, since the update first subsequent point (point D) is located in the vector formed by the update start point (point C) and the updated second subsequent point (point E) (ie, the vector CE formed by point C and point E)
  • the closed contour formed with the remaining points in the ordered set of points except the updated first subsequent point (point D) i.e., the closed contour formed by the sequential connection vectors CE, points F, G, H, I, J, A, B Outline
  • the point type of the updated first subsequent point (point D) can be identified as a convex point type.
  • point E is a convex point
  • point F is a concave point
  • point G is a convex point
  • point H is a convex point
  • point I is a convex point
  • point J is a concave point.
  • the stopping condition may include at least one of the following: no point is found in the ordered point set in the search direction, the update start point is the same as the start point, or the point types of all points in the ordered point set are identified. Since the stop condition is not met, proceed with the following steps. At this time, point J is the update start point, point A is the update first follow-up point, and point B is the update second follow-up point.
  • the updated first subsequent point (point A) is identified based on the positional relationship between the updated starting point (point J), the updated first subsequent point (point A), and the updated second subsequent point (point B). ) point type. Specifically, since the updated first subsequent point (point A) is located at the vector formed by the updated starting point (point J) and the updated second subsequent point (point B) (ie, the vector JB formed by point J and point B) A closed contour formed with the remaining points in the ordered set of points except the updated first subsequent point (point A) (that is, the closed contour formed by the sequential connection vectors JB, C, D, E, F, G, H, I ), the point type of the updated first subsequent point (point A) can be identified as a convex point type.
  • the processing method ends. Since the stopping condition is met (eg, the point types of all points in the ordered point set are identified), the processing method ends.
  • the above describes a method for determining (eg, identifying) each point in a particular ordered set of points ⁇ A,B,C,D,E,F,G,H,I,J ⁇ using the processing method described in conjunction with FIG. 4
  • An example method of the type for example, the type of the point is judged by deleting a certain point in the ordered set of points, forming a contour with the remaining points, and then judging the relative positional relationship between the point and the contour. In this way, the types of points in the ordered point set can be quickly identified, reducing the time complexity of the operation.
  • the exemplary embodiments described above are only for explaining the present disclosure, and the embodiments of the present disclosure are not limited thereto, and various changes may be made on this basis.
  • the number of points in the point set and the point type of each point are not limited to the example described in FIG. 4 .
  • each block in the flowchart or block diagrams may represent a module, segment, or portion of code that includes at least one executable instruction for implementing the specified logical function.
  • the functions noted in the blocks may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved.
  • FIG. 5 shows a schematic structural diagram of a point set-based processing apparatus according to at least one embodiment of the present disclosure.
  • the processing apparatus 500 may include: a starting point selection module 510 and a point type identification module 520 .
  • the starting point selection module 510 is configured to select a point in the ordered set of points as a starting point.
  • the ordered set of points may correspond to the shape contour of the image.
  • the shape contour may be the contour of an image, such as a two-dimensional image or a three-dimensional image.
  • the image may include a floor plan.
  • the floor plan may include a 2-dimensional (2D) floor plan or a 3-dimensional (3D) floor plan (alternatively, referred to as a three-dimensional floor plan).
  • the two-dimensional floor plan may be a flat floor plan of a house
  • the three-dimensional floor plan may be a three-dimensional model of the house.
  • the two-dimensional or three-dimensional floor plan can represent the various subspaces of the residence (for example, living room subspace, master bedroom subspace, secondary bedroom subspace, balcony subspace, toilet subspace, kitchen subspace, etc.) and the size of each subspace. location, etc.
  • the two-dimensional floor plan may be (or, be approximated as) a right-angled polygon.
  • a three-dimensional floor plan it can be converted into a two-dimensional floor plan (ie, a flat floor plan), and then processed using the methods provided according to various embodiments of the present disclosure.
  • various known methods can be used to convert a three-dimensional floor plan into a two-dimensional floor plan, which is not limited by the embodiments of the present disclosure.
  • the point type identification module 520 is configured to: based on a predetermined search direction, search in the ordered point set to determine the first subsequent point of the starting point, and based on the predetermined search direction, search in the ordered point set to determine the first subsequent point.
  • FIG. 6 shows a block diagram of an electronic device according to an embodiment of the present disclosure.
  • an electronic device 600 may include one or more processors 610 and memory 620 .
  • Memory 620 may be used to store one or more computer programs.
  • the processor 610 may include various processing circuits such as, but not limited to, one or more of a special purpose processor, a central processing unit, an application processor, or a communications processor.
  • the processor 610 may perform control over at least one other component of the electronic device 600, and/or perform communication-related operations or data processing.
  • Memory 620 may include volatile and/or nonvolatile memory.
  • one or more computer programs when executed by one or more processors 610, cause the one or more processors 610 to implement the processing methods described above. For example, to identify the point type of each point in an ordered set of points, where the point type is one of a convex point type or a concave point type.
  • the ordered set of points may correspond to the shape contour of the image.
  • the shape outline may be the outline of an image, such as a two-dimensional image or a three-dimensional image.
  • the image may include a floor plan.
  • the floor plan may include a 2-dimensional (2D) floor plan or a 3-dimensional (3D) floor plan (alternatively, referred to as a three-dimensional floor plan).
  • the two-dimensional floor plan may be a flat floor plan of a house
  • the three-dimensional floor plan may be a three-dimensional model of the house.
  • the two-dimensional or three-dimensional floor plan can represent the various subspaces of the residence (for example, living room subspace, master bedroom subspace, secondary bedroom subspace, balcony subspace, toilet subspace, kitchen subspace, etc.) and the size of each subspace. location, etc.
  • the two-dimensional floor plan may be (or, be approximated as) a right-angled polygon.
  • the one or more processors 610 may be configured to perform the following operations: select a point in the ordered set of points as a starting point; search in the ordered set of points to determine the starting point based on a predetermined search direction a first follow-up point of the starting point, and based on the predetermined search direction, searching in the ordered set of points to determine a second follow-up point of the first follow-up point; and based on the starting point, the first follow-up point, and the second follow-up point
  • the positional relationship between the subsequent points is used to identify the point type of the first subsequent point, wherein the point type is one of a convex point type or a concave point type.
  • the electronic device 600 can, for example, determine the type of the point by deleting a certain point in the ordered point set, composing the remaining points into a contour, and then judging the relative positional relationship between the point and the contour. In this way, the types of points in the ordered point set can be quickly identified, reducing the time complexity of the operation.
  • the electronic device 600 also includes a display configured to present in the image the identified point types of points of a particular type (eg, pit type). For example, presenting the points whose point types identified in the ordered set of points are of the concave point type may include highlighting the points of the concave point type. As another example, presenting the points of the concave point type identified in the ordered set of points may include displaying a specific indicator (eg, a graphic of a specific shape, such as a circle) adjacent to the point type of the concave point type to indicate the point of the concave point type.
  • the type of point is the concave point type.
  • presenting a point whose point type identified in the ordered point set is a concave point type may include displaying indication information on or near the point indicating that the point type of a certain point is a concave point type.
  • embodiments of the present disclosure are not limited thereto, and any way may be used to present points of a particular type (eg, a pit type) identified in the ordered set of points.
  • presenting points with a specific type (eg, concave point type) in an ordered set of points it is possible to enable designers to perform interior design or intelligently assisted design based on the identified point types, which can facilitate designers to design, thereby reducing the need for designers workload.
  • the user can be directly and clearly aware of a feature (eg, angle) of the image (eg, graphic) point).
  • a feature eg, angle
  • electronic device 600 in embodiments of the present disclosure may include devices such as smart phones, tablet personal computers (PCs), servers, mobile phones, video phones, e-book readers, desktop PCs, laptop computers, netbook computers, personal Digital Assistants (PDAs), Portable Multimedia Players (PMPs), MP3 Players, Mobile Medical Devices, Cameras or Wearable Devices (e.g. Head Mounted Devices (HMDs), Electronic Clothes, Electronic Wristbands, Electronic Necklaces, Electronic Accessories, electronic tattoos or smart watches) etc.
  • PDAs personal Digital Assistants
  • PMPs Portable Multimedia Players
  • MP3 Players MP3 Players
  • Mobile Medical Devices e.g. Head Mounted Devices (HMDs), Electronic Clothes, Electronic Wristbands, Electronic Necklaces, Electronic Accessories, electronic tattoos or smart watches
  • HMDs Head Mounted Devices
  • HMDs Head Mounted Devices
  • Electronic Clothes Electronic Wristbands
  • Electronic Necklaces Electronic Necklaces
  • Electronic Accessories electronic tattoos or smart watches
  • module may include a unit configured in hardware, software, or firmware and/or any combination thereof, and may be used interchangeably with other terms (eg, logic, logical blocks, components, or circuits).
  • a module may be a single integral component or the smallest unit or component that performs one or more functions.
  • the module may be implemented mechanically or electronically, and may include, but is not limited to, special purpose processors, CPUs, Application Specific Integrated Circuit (ASIC) chips, Field Programmable Gate Arrays (FPGAs) known or to be developed to perform certain operations ) or programmable logic device.
  • ASIC Application Specific Integrated Circuit
  • FPGAs Field Programmable Gate Arrays
  • an apparatus eg, a module or a function thereof
  • a method eg, an operation or a step
  • a computer-readable storage medium eg, memory 502 , eg, in the form of a program module
  • the instructions may enable the processor to perform corresponding functions.
  • Computer readable media may include, for example, hard disks, floppy disks, magnetic media, optical recording media, DVDs, magneto-optical media.
  • the instructions may include code created by a compiler or code executable by an interpreter.
  • Modules or programming modules according to various embodiments of the present disclosure may include at least one or more of the above-described components, some of them may be omitted, or other additional components may also be included. operations performed by modules, programming modules, or other components according to various embodiments of the present disclosure may be performed sequentially, in parallel, repeatedly, or heuristically, or at least some operations may be performed in a different order or omitted, or Additional actions can be added.

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)

Abstract

一种基于有序点集的处理方法、处理装置及电子设备。该处理方法包括:在有序点集中选择一个点作为起始点;基于预定查找方向,在有序点集中查找以确定起始点的第一后续点,并且基于预定查找方向,在有序点集中查找以确定第一后续点的第二后续点,基于起始点、第一后续点、以及第二后续点之间的位置关系来识别第一后续点的点类型,其中点类型为凸点类型或凹点类型之一。该处理方法能够有效地识别有序点集中点的点类型,降低了基于有序点集的处理方法的复杂度。

Description

基于有序点集的处理方法、处理装置及电子设备 技术领域
本公开的实施例涉及一种基于有序点集的处理方法、处理装置及电子设备。
背景技术
在计算机视觉中,形状分析的焦点之一就是如何有效地抽取目标具有辨识力的形状特征并用于后续的识别、分类、检索等任务。人的视觉对目标的轮廓或其中的角点非常敏感,甚至目标的二维轮廓或其中的角点也能给人的视觉系统传递足够的形状信息对其进行准确的识别。人的视觉仅需借助于目标的轮廓线,甚至在得到的目标的轮廓不完整的情况下,也能正确地识别目标。因此在很多情况下,仅需对目标的边界像素点进行分析,就可以抽取出具有强的辨识能力的形状特征。
发明内容
根据本公开的至少一实施例,提供了一种基于有序点集的处理方法。该处理方法包括:在该有序点集中选择一个点作为起始点;基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点;以及基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点类型或凹点类型之一。
例如,在一些实施方式中,该有序点集对应于图像(例如,图形,诸如户型图)的轮廓。
例如,在一些实施方式中,该方法还包括:将该第一后续点作为更新起始点,将该第二后续点作为更新第一后续点,以及重复以下操作直至满足停止条件:基于该预定查找方向,在该有序点集中查找以确定该更新第一后续点的更新第二后续点;基于该更新起始点、该更新第一后续点、以及该更新第二后续点之间的位置关系来识别该更新第一后续点的点类型;以及将该更新第一后 续点作为更新起始点并且将该更新第二后续点作为更新第一后续点。
例如,在一些实施方式中,该停止条件包括以下中的至少一个:在该查找方向上在该有序点集中未查找到点、更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别。
例如,在一些实施方式中,基于该起始点、该第一后续点、该第二后续点之间的位置关系来识别该第一后续点的点类型包括:基于该起始点和该第二后续点形成的向量与该第一后续点的相对位置来识别该第一后续点的点类型。
例如,在一些实施方式中,基于该起始点和该第二后续点形成的向量与该第一后续点的相对位置来识别该第一后续点的点类型包括:当该第一后续点位于该向量与该有序点集中除该第一后续点以外的剩余点形成的封闭轮廓之内时,识别该第一后续点的点类型为凹点类型;和/或当该第一后续点位于该向量与该有序点集中除该第一后续点以外的剩余点形成的封闭轮廓之外时,识别该第一后续点的点类型为凸点类型。
例如,在一些实施方式中,该起始点为该图像的形状轮廓中的一个或多个边角点之一,该一个或多个边角点包括该有序点集的凸点集中的在第一方向或第二方向上处于边缘位置的一个或多个凸点,该第一方向与该第二方向相互垂直。
例如,在一些实施方式中,在该有序点集位于直角坐标系的情况下,该起始点为该一个或多个边角点中的横坐标最小并且纵坐标最小的边角点。
例如,在一些实施方式中,还包括在该图像中呈现该有序点集中所识别的点类型为凹点类型的点。
例如,在一些实施方式中,该查找方向是顺时针方向或逆时针方向之一。
根据本公开的至少一实施例,提供了一种基于有序点集的处理装置。该处理装置包括:起始点选择模块,被配置为在该有序点集中选择一个点作为起始点;和点类型识别模块,被配置为:基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点,以及基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点类型或凹点类型之一。
例如,在一些实施方式中,该有序点集对应于图像(例如,图形,诸如户 型图)的轮廓。
例如,在一些实施方式中,该点类型识别模块还被配置为:将该第一后续点作为更新起始点,将该第二后续点作为更新第一后续点,以及重复以下操作直至满足停止条件:基于查找方向,在该有序点集中查找以确定该更新第一后续点的更新第二后续点,基于该更新起始点、该更新第一后续点、以及该更新第二后续点之间的位置关系来识别该更新第一后续点的点类型,以及将该更新第一后续点作为更新起始点并且将该更新第二后续点作为更新第一后续点。
例如,在一些实施方式中,该停止条件包括以下中的至少一个:在该查找方向上在该点集中未查找到点、更新起始点与该起始点相同、或该点集中的所有点的点类型都被识别。
例如,在一些实施方式中,该处理装置还包括凹点呈现模块,被配置为:在该图像中呈现该有序点集中所识别的点类型为凹点类型的点。
例如,在一些实施方式中,该点类型识别模块包括点类型识别子模块,被配置为:基于该起始点和该第二后续点形成的向量与该第一后续点的相对位置来识别该第一后续点的点类型。
例如,在一些实施方式中,该点类型识别子模块被配置为:当该第一后续点位于该向量与该点集中除该第一后续点以外的剩余点形成的封闭轮廓之外时,识别该第一后续点为凸点;和/或当该第一后续点位于该向量与该点集中除该第一后续点以外的剩余点形成的封闭轮廓之内时,识别该第一后续点为凹点。
例如,在一些实施方式中,该起始点为该形状轮廓中的边角点,该边角点为该点集的凸点集中的在第一方向或第二方向上处于边缘位置的凸点,该第一方向与该第二方向相互垂直。
例如,在一些实施方式中,该查找方向是顺时针方向或逆时针方向之一。
根据本公开的至少一实施例,还提供了一种电子设备。该电子设备包括:一个或多个处理器;和存储器,用于存储一个或多个计算机程序,当一个或多个计算机程序被一个或多个处理器执行时,使得一个或多个处理器执行如上描述的处理方法中的一个或多个操作。
例如,在一些实施方式中,该电子设备还包括显示器,被配置为在该图像中呈现所识别的点类型为凹点类型的点。
根据本公开的至少一实施例,还提供了一种计算机可读存储介质,其上存储有一个或多个计算机程序,当一个或多个计算机程序被处理器执行时执行如上描述的处理方法中的一个或多个操作。
附图说明
为了更清楚地说明本公开实施例的技术方案,下面将对本公开实施例的附图作简单地介绍。明显地,下面描述的附图仅仅涉及本公开的一些实施例,而非对本公开的限制。
图1示出了根据本公开的一些实施例的图像(或图形)以及与该图像(或图形)对应的点集的示意图;
图2示出了根据本公开的至少一实施例的基于有序点集的处理方法的流程图;
图3示出了根据本公开的至少一实施例的基于有序点集的处理方法的示意图;
图4示出了根据本公开的至少一实施例的基于有序点集的处理装置的结构示意图;以及
图5示出了根据本公开的实施例的电子设备的框图;
图6示出了根据本公开的实施例的电子设备的框图。
具体实施方式
为使本公开实施例的目的、技术方案和优点更加清楚,下面将结合附图,对本公开实施例的技术方案进行清楚、完整地描述。显然,所描述的实施例是本公开的一部分实施例,而不是全部的实施例。基于所描述的本公开的实施例,本领域普通技术人员在无需创造性劳动的前提下所获得的所有其他实施例,都属于本公开保护的范围。
这里用于描述本发明的实施例的术语并非旨在限制和/或限定本发明的范围。
例如,除非另外定义,本公开使用的技术术语或者科学术语应当为本发明所属领域内具有一般技能的人士所理解的通常意义。
应该理解的是,本公开中使用的“第一”、“第二”以及类似的词语并不 表示任何顺序、数量或者重要性,而只是用来区分不同的组成部分。除非上下文另外清楚地指出,否则单数形式“一个”、“一”或者“该”等类似词语也不表示数量限制,而是表示存在至少一个。
将进一步理解的是,术语“包括”或者“包含”等类似的词语意指出现该词前面的元件或者物件涵盖出现在该词后面列举的元件或者物件及其等同,而不排除其他元件或者物件。“连接”或者“相连”等类似的词语并非限定于物理的或者机械的连接,而是可以包括电性的连接,不管是直接的还是间接的。“上”、“下”、“左”、“右”等仅用于表示相对位置关系,当被描述对象的绝对位置改变后,则该相对位置关系也可能相应地改变。
对于由点集(例如,有序点集)组成的图像轮廓,确定(例如,识别)点集中的每个点的点类型可能是有利的。点集中的每个点的点类型可以包括凹点类型或凸点类型,关于点类型的定义可以参考之后的描述。例如,在计算机视觉或计算机辅助设计领域,确定(例如,识别)有序点集中各个有序点的点类型是有利的。例如,作为应用的示例,在确定(例如,识别)图像轮廓的点集中的各个点的点类型后,设计人员能够基于图像轮廓的点集中的各个点的点类型进行室内设计或进行智能辅助设计,因此能够方便设计人员进行设计,从而减轻设计人员的工作量。例如,通过向用户提供(例如,呈现)图像(例如,图形)中具有特定类型的点(例如,凹点),能够使用户直接、清楚地获知图像(例如,图形)的特征(例如,角点)。
例如,可以采用这样的方法确定(例如,识别)有序点集中的点的类型,该方法通过删除有序点集中的某个点,将剩余点组成的轮廓的面积与删除前有序点集中的点组成的轮廓的面积来判断该点的类型。然而,该方法的计算量大,并且一次只能确定(例如,识别)一个点的类型。因此计算效率低。
为了解决至少以上问题,本公开的实施例提出了一种基于有序点集的处理方法、处理装置及电子设备。
根据本公开的至少一实施例,一种基于点集的处理方法包括:在有序点集中选择一个点作为起始点;基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点;以及基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点 类型或凹点类型之一。
根据本公开的实施例的处理方法能够对有序点集进行处理以获得有序点集中的各个点的点类型。例如,在一些实施方式中,可以呈现有序点集中具有特定类型(例如,凹点类型)的点,以便于设计人员基于识别的点类型进行室内设计或进行智能辅助设计,这能够方便设计人员进行设计,从而减轻设计人员的工作量。例如,通过向用户提供(例如,呈现)图像(例如,图形)中具有特定类型的点(例如,凹点),能够使用户直接、清楚地获知图像(例如,图形)的特征(例如,角点)。
下面,将参考附图详细地说明本公开的实施例。应当注意的是,不同的附图中相同的附图标记将用于指代已描述的相同的元件。
在本公开的实施例中,有序点集可以指由多个有序点构成的集合。例如,有序点集可以对应于图像的轮廓。图像可以包括二维图像或三维图像。例如,图像的轮廓可以是诸如直角多边形的二维图形。例如,对于三维图像,可以将其转换为二维图像,并且然后使用根据本公开的各种实施例提供的方法来进行处理。例如,可以采用已知的各种方法来将三维图像转换为二维图像。
点集(例如,有序点集)中的点的类型可以包括凹点(也称为凹顶点)和凸点(也称为凸顶点)。因此,有序点集可以包括凹点集和凸点集,其中凹点集中包括至少一个凹点,凸点集包括至少一个凸点。例如,有序点集中的点的类型仅包括凹点类型和凸点类型。在本公开的实施例中,在与有序点集对应的图形中,当以某个点为交点的、图形的两个直角边形成的内角小于外角时,则该点的类型为凸点。相反,当以某个点为交点的、图形的两个直角边形成的内角大于外角时,则该点的类型为凹点。另外,在本公开的实施例中,在凸点集中,在第一方向或第二方向上处于边缘位置的凸点可以被称为边角点。例如,在二维直角坐标系中,边角点可以包括:横坐标最小的凸点集中,纵坐标最大或最小的凸点;横坐标最大的凸点集中,纵坐标最大或最小的凸点;纵坐标最小的凸点集中,横坐标最大或最小的凸点;纵坐标最大的凸点集中,横坐标最大或最小的凸点。
图1示出了根据本公开的一些实施例的图像(或图形)以及与该图像(或图形)对应的有序点集的示意图。参考图1,对于确定的有序点集{A,B,C,D,E,F,G,H,I,J},凸点包括A、B、D、E、G、H、I,凹点包括C、F、J。因此, 凸点集为{A,B,D,E,G,H,I},凹点集为{C,F,J}。与有序点集相对应的图形为将点集中的各个点按照一定的顺序连接形成的直角多边形,例如,如图1中的虚线所示。进一步参考图1,对于凸点集{A,B,D,E,G,H,I},边角点包括A、B、D、E、G、H、I。例如,有序点集可以包括顺序点集和逆序点集。继续参考图1,顺序点集可以指在顺时针方向形成的点集{J,I,H,G,F,E,D,C,B,A},并且逆序点集可以是在逆时针方向形成的点集{A,B,C,D,E,F,G,H,I,J}。在本公开的实施例中,为了便于描述,对于有序点集中的某个点(例如点A),该点(例如,点A)的后续点(例如,点B)可以为在预定方向上(例如,逆时针方向)紧接着该点的点。
以上结合图1描述的仅是与图像轮廓(或图形轮廓)有序点集的示例。然而本公开的实施例不限于此,并且本公开的实施例可以应用于其它具有类似形状的有序点集。
图2示出了根据本公开的至少一实施例的基于有序点集的处理方法200的流程图。
参考图2,在步骤S210,在有序点集中选择一个点作为起始点。
在一些实施方式中,步骤S210还可以包括确定(例如,获取或接收)有序点集。例如,该有序点集可以表征图像的轮廓。特别地,该轮廓为直角多边形。
在一些实施方式中,步骤S210还可以包括确定有序点集中的点的数量是否是大于预定阈值(例如,4)的偶数。如果确定有序点集中的点的数量是大于预定阈值(例如,4)的偶数,则可以确定图像的轮廓是直角多边形,则继续进行后续的操作,否则结束操作。通过对图像的形状轮廓的有序点集中的点的数量进行判断后,再执行后续的点类型的识别操作,能够避免对不具有特定形状(例如,无法识别其角点)的图形进行无效处理,节约了计算资源。
在一些实施方式中,有序点集可以对应于图像的形状轮廓。例如,形状轮廓可以是图像(诸如,二维图像或三维图像)的轮廓。在一些示例中,图像可以包括户型图。例如,户型图可以包括2维(2D)户型图或3维(3D)户型图(或者,称为立体户型图)。例如,二维户型图可以是住宅的平面户型图,三维户型图可以是住宅的三维立体模型图。二维户型图或三维户型图可以表征住宅的各个子空间(例如,客厅子空间、主卧子空间、次卧子空间、阳台子 空间、厕所子空间、厨房子空间等)和各个子空间的位置排布等。特别地,二维户型图或三维户型图可以为(或者,被转换或近似为)一个或多个直角多边形。例如,对于三维户型图,可以将其转换为二维户型图(即,平面户型图),然后使用根据本公开的各种实施例提供的方法来进行处理。例如,可以采用已知的各种方法来将三维户型图转换为二维户型图,本公开的实施例对此不做限制。
例如,形状轮廓可以是诸如直角多边形的二维图形。直角多边形可以指所有的角均为直角的多边形。
例如,该起始点可以从该形状轮廓中的一个或多个边角点中选择,该一个或多个边角点包括该有序点集的凸点集中的在第一方向或第二方向上处于边缘位置的一个或多个凸点,该第一方向与该第二方向相互垂直。例如,在将点集映射到二维平面直角坐标系(X-Y直角坐标系)的情况下,第一方向可以为X轴方向,第二方向可以为Y轴方向。
在一些实施方式中,在该有序点集位于直角坐标系的情况下,该起始点为该一个或多个边角点中的横坐标最小并且纵坐标最小的边角点。
在一些实施方式中,可以采用以下方法中的至少一个来确定有序点集的凹点集和凸点集:凸壳法、角度法、左右点法、向量面积法、向量积法、射线法、斜率法以及极点顺序法。需要说明,本公开的实施例不限制确定凹点集和凸点集的方法,可以采用已知的各种方法来确定凹点集和凸点集。
继续参考图2,在步骤S220,基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点。
在一些实施方式中,预定查找方向是顺时针方向或逆时针方向之一。
接下来,在步骤S230,基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点类型或凹点类型之一。
在一些实施方式中,基于该起始点、该第一后续点、该第二后续点之间的位置关系来识别该第一后续点的点类型包括:基于该起始点和该第二后续点形成的向量与该第一后续点的相对位置来识别该第一后续点的点类型。
在一些实施方式中,当该第一后续点位于该向量与该有序点集中除该第 一后续点以外的剩余点形成的封闭轮廓之内时,识别该第一后续点的点类型为凹点类型。相反,当该第一后续点位于该向量与该有序点集中除该第一后续点以外的剩余点形成的封闭轮廓之外时,识别该第一后续点的点类型为凸点类型。
在本公开的实施例中,考虑图像轮廓的直角多边形的特性,通过该起始点和该第二后续点形成的向量与该第一后续点的相对位置能够简单快速地识别该第一后续点的点类型,降低了对与图像轮廓对应的有序点集中的点的类型识别的复杂度,节约了计算资源。
在一些实施方式中,方法200还包括:将该第一后续点作为更新起始点,将该第二后续点作为更新第一后续点,以及重复以下操作直至满足停止条件:基于该预定查找方向,在该有序点集中查找以确定该更新第一后续点的更新第二后续点;基于该更新起始点、该更新第一后续点、以及该更新第二后续点之间的位置关系来识别该更新第一后续点的点类型;以及将该更新第一后续点作为更新起始点并且将该更新第二后续点作为更新第一后续点。通过循环执行上述操作,可以识别有序点集中的各个点的点类型。
在一些示例中,停止条件可以包括以下中的至少一个:在该查找方向上在该有序点集中未查找到点、更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别。例如,如果在该查找方向上在该有序点集中未查找到点,则表示查找失败,可以认为该识别方法的执行失败。如果更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别,则表示该方法完成,并且可以执行后续步骤,例如,存储或呈现特定类型的点。通过这种循环的方式,能够快速地识别与图像轮廓对应的有序点集中的多个点(例如,所有点)的类型,因此降低了处理的复杂度,节约了计算资源。
在一些实施方式中,方法200还包括存储该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。
在一些实施方式中,方法200还包括输出该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。
在一些实施方式中,方法200还包括(例如,通过显示器)在该图像中呈现该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括突出显示点类型 为凹点类型的点。又例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括在点类型为凹点类型的点附件显示特定指示符(例如,具有特定形状的图形)来指示该点的类型为凹点类型。又例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括在该点上或附近显示指示某个点的点类型为凹点类型的指示信息。然而,本公开的实施例不限于此,可以采用任何方式来呈现该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。通过呈现有序点集中具有特定类型(例如,凹点类型)的点,可以使得设计人员能够基于识别的点类型进行室内设计或进行智能辅助设计,这能够方便设计人员进行设计,从而减轻设计人员的工作量。例如,通过向用户提供(例如,呈现)图像(例如,图形)中具有特定类型的点(例如,凹点),能够使用户直接、清楚地获知图像(例如,图形)的特征(例如,角点)。
以上描述了根据本公开的一些实施例的基于有序点集的处理方法。在该方法中,通过删除有序点集中的某个点,将剩余点组成一个轮廓,然后判断该点与轮廓的相对位置关系来判断该点的类型。以这种方式,能够快速识别有序点集中的点的类型,减小了运算的时间复杂度。
图3示出了根据本公开的至少一实施例的基于有序点集的处理方法300的流程图。例如,处理方法300可以基于处理方法200。因此,参考图2的描述也可以应用于结合图3描述的处理方法300的各种实施例。
参考图3,在步骤S310,确定有序点集中的点的数量是否为大于预定阈值(例如,4)的偶数。
在一些实施方式中,有序点集可以对应于图像的形状轮廓。例如,形状轮廓可以是图像(诸如,二维图像或三维图像)的轮廓。在一些示例中,图像可以包括户型图。例如,户型图可以包括2维(2D)户型图或3维(3D)户型图(或者,称为立体户型图)。例如,二维户型图可以是住宅的平面户型图,三维户型图可以是住宅的三维立体模型图。二维户型图或三维户型图可以表征住宅的各个子空间(例如,客厅子空间、主卧子空间、次卧子空间、阳台子空间、厕所子空间、厨房子空间等)和各个子空间的位置排布等。特别地,二维户型图可以为(或者,被近似为)直角多边形。例如,对于三维户型图,可以将其转换为二维户型图(即,平面户型图),然后使用根据本公开的各种实施例提供的方法来进行处理。例如,可以采用已知的各种方法来将三维户型图 转换为二维户型图,本公开的实施例对此不做限制。
如果确定有序点集中的点的数量大于预定阈值并且为偶数(例如,4),则可以确定图像的轮廓是直角多边形,则继续执行操作S320,否则结束操作。通过对图像的形状轮廓的有序点集中的点的数量进行判断后,再执行后续的点类型的识别操作,能够避免对非直角多边形的图形进行无效处理,节约了计算资源。
例如,形状轮廓可以是诸如直角多边形的二维图形。直角多边形可以指所有的角均为直角的多边形。
在一些实施方式中,可以采用以下方法中的至少一个来确定有序点集的凹点集和凸点集:凸壳法、角度法、左右点法、向量面积法、向量积法、射线法、斜率法以及极点顺序法。需要说明,本公开的实施例不限制确定凹点集和凸点集的方法,可以采用已知的各种方法来确定凹点集和凸点集。
继续参考图2,在步骤S320,在有序点集中选择一个点作为起始点。
例如,该起始点可以从该形状轮廓中的一个或多个边角点中选择,该一个或多个边角点包括该有序点集的凸点集中的在第一方向或第二方向上处于边缘位置的一个或多个凸点,该第一方向与该第二方向相互垂直。例如,在将点集映射到二维平面直角坐标系(X-Y直角坐标系)的情况下,第一方向可以为X轴方向,第二方向可以为Y轴方向。
在一些实施方式中,在该有序点集位于直角坐标系的情况下,该起始点为该一个或多个边角点中的横坐标最小并且纵坐标最小的边角点。
接下来,在步骤S330,基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点。
在一些实施方式中,预定查找方向顺时针方向或逆时针方向之一。
接下来,在步骤S340,基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点类型或凹点类型之一。
在一些实施方式中,基于该起始点、该第一后续点、该第二后续点之间的位置关系来识别该第一后续点的点类型包括:基于该起始点和该第二后续点形成的向量与该第一后续点的相对位置来识别该第一后续点的点类型。
在一些实施方式中,当该第一后续点位于该向量与该有序点集中除该第一后续点以外的剩余点形成的封闭轮廓之内时,识别该第一后续点的点类型为凹点类型。相反,当该第一后续点位于该向量与该有序点集中除该第一后续点以外的剩余点形成的封闭轮廓之外时,识别该第一后续点的点类型为凸点类型。
在本公开的实施例中,考虑图像轮廓的直角多边形的特性,通过该起始点和该第二后续点形成的向量与该第一后续点的相对位置能够简单快速地识别该第一后续点的点类型,降低了对图像的边角点的类型识别的复杂度,节约了计算资源。
然后,在步骤S350,将该第一后续点作为更新起始点,将该第二后续点作为更新第一后续点。
接下来,在步骤S360,基于该预定查找方向,在该有序点集中查找以确定该更新第一后续点的更新第二后续点。
然后,在步骤S370,基于该更新起始点、该更新第一后续点、以及该更新第二后续点之间的位置关系来识别该更新第一后续点的点类型。
在一些实施方式中,基于该更新起始点、该更新第一后续点、以及该更新第二后续点之间的位置关系来识别该更新第一后续点的点类型包括:基于该更新起始点和该更新第二后续点形成的向量与该更新第一后续点的相对位置来识别该第一后续点的点类型。
在一些实施方式中,当该更新第一后续点位于该向量与该有序点集中除该更新第一后续点以外的剩余点形成的封闭轮廓之内时,识别该第一后续点的点类型为凹点类型。相反,当该更新第一后续点位于该向量与该有序点集中除该第一后续点以外的剩余点形成的封闭轮廓之外时,识别该更新第一后续点的点类型为凸点类型。
接下来,在步骤S380,判断是否满足停止条件。如果满足停止条件,则结束方法300,否则执行步骤S390。
在一些示例中,停止条件可以包括以下中的至少一个:在该查找方向上在该有序点集中未查找到点、更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别。
在步骤S390,将该更新第一后续点作为更新起始点并且将该更新第二后 续点作为更新第一后续点,返回步骤S360。
通过循环执行上述步骤S360至步骤S390,可以确定(例如,识别)有序点集中的各个点的点类型。通过这种循环的方式,能够快速地识别与图像轮廓对应的有序点集中的多个点(例如,所有点)的类型,因此降低了处理的复杂度,节约了计算资源。
在一些实施方式中,方法300还包括(例如,在满足停止条件时)存储或输出该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。
在一些实施方式中,方法300还包括(例如,在满足停止条件时)通过显示器在该图像中呈现该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括突出显示点类型为凹点类型的点。又例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括在点类型为凹点类型的点附件显示特定指示符(例如,特定形状的图形,诸如圆)来指示该点的类型为凹点类型。又例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括在该点上或附近显示指示某个点的点类型为凹点类型的指示信息。然而,本公开的实施例不限于此,可以采用任何方式来呈现该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。通过呈现有序点集中具有特定类型(例如,凹点类型)的点,可以使得设计人员能够基于识别的点类型进行室内设计或进行智能辅助设计,这能够方便设计人员进行设计,从而减轻设计人员的工作量。
以上描述了根据本公开的一些实施例的基于有序点集的处理方法。在该方法中,通过删除有序点集中的某个点,将剩余点组成一个轮廓,然后判断该点与轮廓的相对位置关系来判断该点的类型。以这种方式,能够快速识别有序点集中的点的类型,减小了运算的时间复杂度。
以上结合图2和图3描述了根据本公开的至少一实施例的基于有序点集的处理方法。下面将结合图4,使用以上结合图2或图3描述的处理方法确定(例如,识别)图1中的特定的点集中的各个点的类型。在这种情况下,确定的有序点集为{A,B,C,D,E,F,G,H,I,J},凸点集为{A,B,D,E,G,H,I},凹点集为{C,F,J},点集{A,B,C,D,E,F,G,H,I,J}对应的图形轮廓为直角多边形。为了便于描述,建立如图4中所示的X-Y直角坐标系,并将点集映射到该X-Y直角坐标系。需要说明的是,本公开的实施例不限于图4示出的图像 (或图形),并且可以应用于其轮廓为任何形状的图像(或图形)。
首先,确定图像的有序点集{A,B,C,D,E,F,G,H,I,J}中的点的数量是否为大于预定阈值(例如,4)的偶数。该实施例中,因为有序点集中的点的数量大于预定阈值(例如,4),所以可以确定图像的轮廓是直角多边形,则继续执行下述步骤。
然后,在图像的有序点集{A,B,C,D,E,F,G,H,I,J}中选择一个点作为起始点。例如,可以选择边角点A作为起始点。
接下来,基于预定查找方向(例如,逆时针方向),在该有序点集中查找以确定该起始点的第一后续点(点B),并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点(点B)的第二后续点(点C)。预定查找方向顺时针方向或逆时针方向之一。以下的描述中,将以逆时针方向作为查找方向来描述各个实施例。当以顺时针方向作为查找方向时,可以采用与描述的实施例类似的处理方法。
接下来,基于该起始点(点A)、该第一后续点(点B)、以及该第二后续点(点C)之间的位置关系来识别该第一后续点(点B)的点类型,其中该点类型为凸点类型或凹点类型之一。具体地,由于该第一后续点(点B)位于该起始点(点A)和该第二后续点(点C)形成的向量(即,点A和点C形成的向量AC)与该有序点集中除该更新第一后续点以外的剩余点形成的封闭轮廓(即,顺序连接向量AC、点D、E、F、G、H、I、J形成的封闭轮廓)之外,可以识别该第一后续点(点B)的点类型为凸点类型。
接下来,判断是否满足停止条件。停止条件可以包括以下中的至少一个:在该查找方向上在该有序点集中未查找到点、更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别。由于不满足停止条件,则继续进行以下步骤。
然后,将该第一后续点(点B)作为更新起始点,将该第二后续点(点C)作为更新第一后续点。
接下来,基于该预定查找方向(例如,逆时针方向),在该有序点集中查找以确定该更新第一后续点(点C)的更新第二后续点(点D)。
然后,基于该更新起始点(点B)、该更新第一后续点(点C)、以及该更新第二后续点(点D)之间的位置关系来识别该更新第一后续点的点类型。 具体地,由于该更新第一后续点(点C)位于该更新起始点(点B)和该更新第二后续点(点D)形成的向量(即,点B和点D形成的向量BD)与该有序点集中除该更新第一后续点(点C)以外的剩余点形成的封闭轮廓(即,顺序连接向量BD、点E、F、G、H、I、J、A形成的封闭轮廓)之内,可以识别该更新第一后续点(点C)的点类型为凹点类型。
接下来,判断是否满足停止条件。停止条件可以包括以下中的至少一个:在该查找方向上在该有序点集中未查找到点、更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别。由于不满足停止条件,则继续进行以下步骤。
然后,将该更新第一后续点(点C)作为更新起始点,将该更新第二后续点(点D)作为更新第一后续点。
接下来,基于该预定查找方向(例如,逆时针方向),在该有序点集中查找以确定该更新第一后续点(点D)的更新第二后续点(点E)。
然后,基于该更新起始点(点C)、该更新第一后续点(点D)、以及该更新第二后续点(点E)之间的位置关系来识别该更新第一后续点(点D)的点类型。具体地,由于该更新第一后续点(点D)位于该更新起始点(点C)和该更新第二后续点(点E)形成的向量(即,点C和点E形成的向量CE)与该有序点集中除该更新第一后续点(点D)以外的剩余点形成的封闭轮廓(即,顺序连接向量CE、点F、G、H、I、J、A、B形成的封闭轮廓)之外,可以识别该更新第一后续点(点D)的点类型为凸点类型。
采用类似的方法,可以识别点E为凸点,点F为凹点,点G为凸点,点H为凸点,点I为凸点,点J为凹点。
在识别了点J的点类型后,判断是否满足停止条件。停止条件可以包括以下中的至少一个:在该查找方向上在该有序点集中未查找到点、更新起始点与起始点相同、或该有序点集中的所有点的点类型都被识别。由于不满足停止条件,则继续进行以下步骤。此时,点J为更新起始点,点A为更新第一后续点,并且点B为更新第二后续点。
然后,基于该更新起始点(点J)、该更新第一后续点(点A)、以及该更新第二后续点(点B)之间的位置关系来识别该更新第一后续点(点A)的点类型。具体地,由于该更新第一后续点(点A)位于该更新起始点(点J) 和该更新第二后续点(点B)形成的向量(即,点J和点B形成的向量JB)与该有序点集中除该更新第一后续点(点A)以外的剩余点形成的封闭轮廓(即,顺序连接向量JB、C、D、E、F、G、H、I形成的封闭轮廓)之外,可以识别该更新第一后续点(点A)的点类型为凸点类型。
接下来,判断是否满足停止条件。由于满足停止条件(例如,有序点集中的所有点的点类型都被识别),则结束该处理方法。
以上描述了一种采用结合图4描述的处理方法确定(例如,识别)特定的有序点集{A,B,C,D,E,F,G,H,I,J}中的各个点的类型的示例方法。在该方法中,例如,通过删除有序点集中的某个点,将剩余点组成一个轮廓,然后判断该点与轮廓的相对位置关系来判断该点的类型。以这种方式,能够快速识别有序点集中的点的类型,减小了运算的时间复杂度。需要说明,以上描述的示例实施例仅是为了解释本公开,本公开的实施例不限于此,在此基础上,可以进行各种改变。例如,点集中的点的数量和各个点的点类型不限于图4中描述的示例。
以上描述了根据本公开的各种实施例的基于点集的处理方法。应当理解,附图中的流程图和框图图示了根据本公开的各种实施例的方法、装置、系统和计算机可读存储介质的可能实现的体系架构、功能和操作。例如,流程图或框图中的每个框可以表示包括用于实现指定的逻辑功能的至少一个可执行指令的模块、段或代码部分。还应该注意的是,在一些替代实施方式中,方框中提到的功能可以不按照附图中指出的顺序发生。例如,取决于所涉及的功能,连续示出的两个框实际上可以基本上同时执行,或者框有时可以以相反的顺序执行。还将注意到,框图和/或流程图的每个框以及框图和/或流程图中的框的组合可以由执行指定功能或动作的基于专用硬件的系统、或专用硬件和计算机指令的组合来实现。
图5示出了根据本公开的至少一实施例的基于点集的处理装置的结构示意图。
参考图5,该处理装置500可以包括:起始点选择模块510和点类型识别模块520。
起始点选择模块510被配置为在该有序点集中选择一个点作为起始点。
在一些实施方式中,有序点集可以对应于图像的形状轮廓。例如,形状轮 廓可以是图像(诸如,二维图像或三维图像)的轮廓。在一些示例中,图像可以包括户型图。例如,户型图可以包括2维(2D)户型图或3维(3D)户型图(或者,称为立体户型图)。例如,二维户型图可以是住宅的平面户型图,三维户型图可以是住宅的三维立体模型图。二维户型图或三维户型图可以表征住宅的各个子空间(例如,客厅子空间、主卧子空间、次卧子空间、阳台子空间、厕所子空间、厨房子空间等)和各个子空间的位置排布等。特别地,二维户型图可以为(或者,被近似为)直角多边形。例如,对于三维户型图,可以将其转换为二维户型图(即,平面户型图),然后使用根据本公开的各种实施例提供的方法来进行处理。例如,可以采用已知的各种方法来将三维户型图转换为二维户型图,本公开的实施例对此不做限制。
点类型识别模块520被配置为:基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点,以及基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点类型或凹点类型之一。
关于起始点选择模块510和点类型识别模块520的具体配置可以参考以上描述的方法实施例,这里省略对其的详细描述。
图6示出了根据本公开的实施例的电子设备的框图。
参考图6,电子设备600可以包括一个或多个处理器610和存储器620。存储器620可以用于存储一个或多个计算机程序。
处理器610可以包括各种处理电路,诸如但不限于专用处理器、中央处理单元、应用处理器或通信处理器中的一种或更多种。处理器610可以对电子设备600的至少一个其他组件执行控制、和/或执行与通信相关的操作或数据处理。
存储器620可以包括易失性和/或非易失性存储器。
在一些实施方式中,当一个或多个计算机程序被一个或多个处理器610执行时,使得一个或多个处理器610实现如上描述的处理方法。例如,以识别有序点集中的每个点的点类型,其中所述点类型为凸点类型或凹点类型之一。
在一些实施方式中,有序点集可以对应于图像的形状轮廓。例如,形状轮廓可以是图像(诸如,二维图像或三维图像)的轮廓。在一些示例中,图像可 以包括户型图。例如,户型图可以包括2维(2D)户型图或3维(3D)户型图(或者,称为立体户型图)。例如,二维户型图可以是住宅的平面户型图,三维户型图可以是住宅的三维立体模型图。二维户型图或三维户型图可以表征住宅的各个子空间(例如,客厅子空间、主卧子空间、次卧子空间、阳台子空间、厕所子空间、厨房子空间等)和各个子空间的位置排布等。特别地,二维户型图可以为(或者,被近似为)直角多边形。
在一些实施方式中,一个或多个处理器610可以被配置为执行以下操作:在该有序点集中选择一个点作为起始点;基于预定查找方向,在该有序点集中查找以确定该起始点的第一后续点,并且基于该预定查找方向,在该有序点集中查找以确定该第一后续点的第二后续点;以及基于该起始点、该第一后续点、以及该第二后续点之间的位置关系来识别该第一后续点的点类型,其中该点类型为凸点类型或凹点类型之一。由此,电子设备600可以例如,通过删除有序点集中的某个点,将剩余点组成一个轮廓,然后判断该点与轮廓的相对位置关系来判断该点的类型。以这种方式,能够快速识别有序点集中的点的类型,减小了运算的时间复杂度。
在一些实施方式中,该电子设备600还包括显示器,显示器被配置为在该图像中呈现所识别的点类型为特定类型(例如,凹点类型)的点。例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括突出显示点类型为凹点类型的点。又例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括在点类型为凹点类型的点附件显示特定指示符(例如,特定形状的图形,诸如圆)来指示该点的类型为凹点类型。又例如,呈现该有序点集中所识别的点类型为凹点类型的点可以包括在该点上或附近显示指示某个点的点类型为凹点类型的指示信息。然而,本公开的实施例不限于此,可以采用任何方式来呈现该有序点集中所识别的点类型为特定类型(例如,凹点类型)的点。通过呈现有序点集中具有特定类型(例如,凹点类型)的点,可以使得设计人员能够基于识别的点类型进行室内设计或进行智能辅助设计,这能够方便设计人员进行设计,从而减轻设计人员的工作量。例如,通过向用户提供(例如,呈现)图像(例如,图形)中具有特定类型的点(例如,凹点),能够使用户直接、清楚地获知图像(例如,图形)的特征(例如,角点)。
例如,本公开的实施例中的电子设备600可以包括诸如智能电话、平板 个人计算机(PC)、服务器、移动电话、视频电话、电子书阅读器、台式PC、膝上型计算机、上网本计算机、个人数字助理(PDA)、便携式多媒体播放器(PMP)、MP3播放器、移动医疗设备、照相机或可穿戴设备(例如头戴式设备(HMD)、电子衣服、电子手环、电子项链、电子饰品、电子纹身或智能手表)等。
如本文所使用的,术语“模块”可以包括在硬件、软件或固件和/或其任何组合中配置的单元,并且可以与其他术语(例如逻辑、逻辑块、部件或电路)互换使用。模块可以是单个整体部件或执行一个或更多个功能的最小单元或部件。该模块可以机械地或电子地实现,并且可以包括但不限于已知的或将要被开发的执行某些操作的专用处理器、CPU、专用集成电路(ASIC)芯片、现场可编程门阵列(FPGA)或可编程逻辑器件。
根据本公开的实施例,设备(例如,模块或其功能)或方法(例如,操作或步骤)的至少一部分可以被实现为例如以程序模块的形式存储在计算机可读存储介质(例如,存储器502)中的指令。当由处理器(例如,处理器501)执行该指令时,该指令可以使处理器能够执行相应的功能。计算机可读介质可以包括例如硬盘、软盘、磁介质、光学记录介质、DVD、磁光介质。该指令可以包括由编译器创建的代码或者可由解释器执行的代码。根据本公开的各种实施例的模块或编程模块可以包括上述组件中的至少一个或更多个,可以省略其中的一些,或者还包括其他附加的组件。由根据本公开的各种实施例的模块、编程模块或其他组件执行的操作可以顺序地、并行地、重复地或启发地执行,或者至少一些操作可以以不同的顺序被执行或被省略,或者可以添加其他操作。
以上所述仅是本发明的示范性实施方式,而非用于限制本发明的保护范围,本发明的保护范围由所附的权利要求确定。

Claims (20)

  1. 一种基于有序点集的处理方法,包括以下步骤:
    在所述有序点集中选择一个点作为起始点;
    基于预定查找方向,在所述有序点集中查找以确定所述起始点的第一后续点,并且基于所述预定查找方向,在所述有序点集中查找以确定所述第一后续点的第二后续点;以及
    基于所述起始点、所述第一后续点、以及所述第二后续点之间的位置关系来识别所述第一后续点的点类型,其中所述点类型为凸点类型或凹点类型之一。
  2. 根据权利要求1所述的处理方法,还包括:将所述第一后续点作为更新起始点,将所述第二后续点作为更新第一后续点,以及重复以下操作直至满足停止条件:
    基于所述预定查找方向,在所述有序点集中查找以确定所述更新第一后续点的更新第二后续点;
    基于所述更新起始点、所述更新第一后续点、以及所述更新第二后续点之间的位置关系来识别所述更新第一后续点的点类型;以及
    将所述更新第一后续点作为更新起始点并且将所述更新第二后续点作为更新第一后续点。
  3. 根据权利要求2所述的处理方法,其中,所述停止条件包括以下中的至少一个:在所述查找方向上在所述有序点集中未查找到点、更新起始点与起始点相同、或所述有序点集中的所有点的点类型都被识别。
  4. 根据权利要求1所述的处理方法,其中,基于所述起始点、所述第一后续点、所述第二后续点之间的位置关系来识别所述第一后续点的点类型包括:
    基于所述起始点和所述第二后续点形成的向量与所述第一后续点的相对位置来识别所述第一后续点的点类型。
  5. 根据权利要求4所述的处理方法,其中,基于所述起始点和所述第二后续点形成的向量与所述第一后续点的相对位置来识别所述第一后续点的点类型包括:
    当所述第一后续点位于所述向量与所述有序点集中除所述第一后续点以外的剩余点形成的封闭轮廓之内时,识别所述第一后续点的点类型为凹点类型;和/或
    当所述第一后续点位于所述向量与所述有序点集中除所述第一后续点以外的剩余点形成的封闭轮廓之外时,识别所述第一后续点的点类型为凸点类型。
  6. 根据权利要求1所述的处理方法,其中,所述起始点为所述有序点集中的一个或多个边角点之一,所述一个或多个边角点包括所述有序点集的凸点集中的在第一方向或第二方向上处于边缘位置的一个或多个凸点,所述第一方向与所述第二方向相互垂直。
  7. 根据权利要求6所述的处理方法,其中,在所述有序点集位于直角坐标系的情况下,所述起始点为所述一个或多个边角点中的横坐标最小并且纵坐标最小的边角点。
  8. 根据权利要求1所述的处理方法,还包括在与所述有序点集对应的图像中呈现所述有序点集中所识别的点类型为凹点类型的点。
  9. 根据权利要求1-8中任一所述的处理方法,其中,所述查找方向是顺时针方向或逆时针方向之一。
  10. 一种基于有序点集的处理装置,包括:
    起始点选择模块,被配置为在所述有序点集中选择一个点作为起始点;和
    点类型识别模块,被配置为:
    基于预定查找方向,在所述有序点集中查找以确定所述起始点的第一后续点,并且基于所述预定查找方向,在所述有序点集中查找以确定所述第一后 续点的第二后续点,以及
    基于所述起始点、所述第一后续点、以及所述第二后续点之间的位置关系来识别所述第一后续点的点类型,其中所述点类型为凸点类型或凹点类型之一。
  11. 根据权利要求10所述的处理装置,其中,所述点类型识别模块还被配置为:将所述第一后续点作为更新起始点,将所述第二后续点作为更新第一后续点,以及重复以下操作直至满足停止条件:
    基于查找方向,在所述有序点集中查找以确定所述更新第一后续点的更新第二后续点,
    基于所述更新起始点、所述更新第一后续点、以及所述更新第二后续点之间的位置关系来识别所述更新第一后续点的点类型,以及
    将所述更新第一后续点作为更新起始点并且将所述更新第二后续点作为更新第一后续点。
  12. 根据权利要求11所述的处理装置,其中,所述停止条件包括以下中的至少一个:在所述查找方向上在所述有序点集中未查找到点、更新起始点与所述起始点相同、或所述有序点集中的所有点的点类型都被识别。
  13. 根据权利要求10所述的处理装置,还包括凹点呈现模块,被配置为:在与所述有序点集对应的图像中呈现所述有序点集中所识别的点类型为凹点类型的点。
  14. 根据权利要求10所述的处理装置,其中,所述点类型识别模块包括点类型识别子模块,被配置为:
    基于所述起始点和所述第二后续点形成的向量与所述第一后续点的相对位置来识别所述第一后续点的点类型。
  15. 根据权利要求14所述的处理装置,其中,所述点类型识别子模块被配置为:
    当所述第一后续点位于所述向量与所述有序点集中除所述第一后续点以外的剩余点形成的封闭轮廓之外时,识别所述第一后续点为凸点;和/或
    当所述第一后续点位于所述向量与所述有序点集中除所述第一后续点以外的剩余点形成的封闭轮廓之内时,识别所述第一后续点为凹点。
  16. 根据权利要求10所述的处理装置,其中,所述起始点为所述有序点集中的边角点,所述边角点为所述有序点集的凸点集中的在第一方向或第二方向上处于边缘位置的凸点,所述第一方向与所述第二方向相互垂直,
    其中,在所述有序点集位于直角坐标系的情况下,所述起始点为所述边角点中的横坐标最小并且纵坐标最小的边角点。
  17. 根据权利要求10-16中任一所述的处理装置,其中,所述查找方向是顺时针方向或逆时针方向之一。
  18. 一种电子设备,包括:
    一个或多个处理器;和
    存储器,被配置为存储一个或多个计算机程序,当所述一个或多个计算机程序被所述一个或多个处理器执行时,使得所述一个或多个处理器执行如权利要求1至9中任一项所述的处理方法中的操作以识别有序点集中的每个点的点类型,其中所述点类型为凸点类型或凹点类型之一。
  19. 根据权利要求18所述的电子设备,还包括显示器,被配置为在与所述有序点集对应的图像中呈现所识别的点类型为凹点类型的点。
  20. 一种计算机可读存储介质,其上存储有一个或多个计算机程序,当所述一个或多个计算机程序被处理器执行时,使得所述一个或多个处理器执行如权利要求1至9中任一项所述的处理方法中的操作。
PCT/CN2021/091468 2021-04-30 2021-04-30 基于有序点集的处理方法、处理装置及电子设备 WO2022226995A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2021/091468 WO2022226995A1 (zh) 2021-04-30 2021-04-30 基于有序点集的处理方法、处理装置及电子设备

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2021/091468 WO2022226995A1 (zh) 2021-04-30 2021-04-30 基于有序点集的处理方法、处理装置及电子设备

Publications (1)

Publication Number Publication Date
WO2022226995A1 true WO2022226995A1 (zh) 2022-11-03

Family

ID=83847478

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/091468 WO2022226995A1 (zh) 2021-04-30 2021-04-30 基于有序点集的处理方法、处理装置及电子设备

Country Status (1)

Country Link
WO (1) WO2022226995A1 (zh)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130083982A1 (en) * 2011-09-30 2013-04-04 Fujifilm Corporation Medical image processing device, method and program
CN105787968A (zh) * 2016-03-22 2016-07-20 北京建飞无限科技有限公司 多边形中凹凸点的识别方法及装置
CN111080692A (zh) * 2019-12-18 2020-04-28 北京城市网邻信息技术有限公司 基于无序点集的处理方法、处理装置及电子设备
CN111145293A (zh) * 2019-12-18 2020-05-12 北京城市网邻信息技术有限公司 用于重建户型图轮廓的方法、装置及电子设备
CN111339336A (zh) * 2020-03-11 2020-06-26 贝壳技术有限公司 用于房屋户型数据的解析方法及系统
CN111522896A (zh) * 2020-04-23 2020-08-11 内蒙古师范大学 确定平面多边形凹凸点的方法及系统

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130083982A1 (en) * 2011-09-30 2013-04-04 Fujifilm Corporation Medical image processing device, method and program
CN105787968A (zh) * 2016-03-22 2016-07-20 北京建飞无限科技有限公司 多边形中凹凸点的识别方法及装置
CN111080692A (zh) * 2019-12-18 2020-04-28 北京城市网邻信息技术有限公司 基于无序点集的处理方法、处理装置及电子设备
CN111145293A (zh) * 2019-12-18 2020-05-12 北京城市网邻信息技术有限公司 用于重建户型图轮廓的方法、装置及电子设备
CN111339336A (zh) * 2020-03-11 2020-06-26 贝壳技术有限公司 用于房屋户型数据的解析方法及系统
CN111522896A (zh) * 2020-04-23 2020-08-11 内蒙古师范大学 确定平面多边形凹凸点的方法及系统

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
SHI WANMING: "The Method of Distinguishing the Polygon's Vertices Being Concave or Convex", JOURNAL OF COMPUTER-AIDED DESIGN & COMPUTER GRAPHICS, no. 3, 1 October 1990 (1990-10-01), pages 15 - 16, 23, XP055982267 *
ZHAO JUN, ZHANG GUI-MEI,QU SHI-RU: "Orientation and Convexity-Concavity Identification for Polygons Using Extremity Vertices Sequence", JOURNAL OF ENGINEERING GRAPHICS, no. 1, 28 February 2007 (2007-02-28), pages 55 - 59, XP055982274, ISSN: 1003-0158 *

Similar Documents

Publication Publication Date Title
US10824862B2 (en) Three-dimensional object detection for autonomous robotic systems using image proposals
US10832079B2 (en) Determining an architectural layout
US11557085B2 (en) Neural network processing for multi-object 3D modeling
US10872227B2 (en) Automatic object recognition method and system thereof, shopping device and storage medium
WO2019018063A1 (en) FINAL GRAIN IMAGE RECOGNITION
CN111080692B (zh) 基于无序点集的处理方法、处理装置及电子设备
WO2020019664A1 (zh) 基于人脸的形变图像生成方法和装置
AU2013237718A1 (en) Method, apparatus and system for selecting a frame
US11941838B2 (en) Methods, apparatuses, devices and storage medium for predicting correlation between objects
WO2016206114A1 (en) Combinatorial shape regression for face alignment in images
US20240221353A1 (en) Method and apparatus for object localization in discontinuous observation scene, and storage medium
Cheng et al. Real-time and efficient 6-D pose estimation from a single RGB image
JP7268063B2 (ja) 低電力のリアルタイムオブジェクト検出用のシステム及び方法
US11908236B2 (en) Illumination detection method and apparatus for face image, and device and storage medium
US10438088B2 (en) Visual-saliency driven scene description
CN111145293B (zh) 用于重建户型图轮廓的方法、装置及电子设备
Pitteri et al. CorNet: generic 3D corners for 6D pose estimation of new objects without retraining
CN110009625B (zh) 基于深度学习的图像处理系统、方法、终端、及介质
TW201310358A (zh) 用以利用積分梯度投影作臉部追蹤之方法與裝置
US20160205382A1 (en) Method and apparatus for generating a labeled image based on a three dimensional projection
Sahloul et al. An accurate and efficient voting scheme for a maximally all-inlier 3D correspondence set
US11640708B1 (en) Scene graph-based scene re-identification
Hodan et al. A Summary of the 4th International Workshop on~ Recovering 6D Object Pose
US10304258B2 (en) Human feedback in 3D model fitting
WO2022226995A1 (zh) 基于有序点集的处理方法、处理装置及电子设备

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21938469

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21938469

Country of ref document: EP

Kind code of ref document: A1