Disclosure of Invention
The invention aims to solve the technical problems at least to a certain extent, and provides a pole tower labeling method.
The technical scheme adopted by the invention is as follows:
a pole tower labeling method comprises the following steps:
obtaining a path diagram, wherein the path diagram comprises a plurality of towers and paths among the towers;
and determining the labeling position of the current tower according to the path relation between the adjacent towers.
Preferably, when determining the labeling position of the current tower according to the path relation between the adjacent towers, the specific steps are as follows:
determining the labeling azimuth and anchor point coordinates of the current tower according to the path relation between the adjacent towers;
and determining the labeling position of the current tower according to the labeling azimuth and the anchor point coordinates of the current tower.
Further preferably, the noted orientation of the current tower includes up, down, left and right.
Further preferably, the labeling directions of the current tower are as follows:
when the front tower is the initial tower, and the azimuth angle from the front tower to the next tower is in the first quadrant and the second quadrant of the Cartesian plane coordinate system, the labeling azimuth of the front tower is left; when the azimuth angle from the current tower to the next tower is in the third quadrant and the fourth quadrant of the Cartesian plane coordinate system, the labeling azimuth of the current tower is right;
when the front tower is a middle tower, defining the azimuth Angle from the last tower to the current tower as PreAngle, and defining the azimuth Angle from the current tower to the next tower;
when the PreAngle is in the first quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the first quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is up;
when the PreAngle is in the first quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the first quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the second quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is lower;
when the PreAngle is in the second quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the second quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the second quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the third quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the third quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the third quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the third quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is lower;
when the PreAngle is in the fourth quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the fourth quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the fourth quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is up;
when the PreAngle is in the fourth quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is on the X positive half shaft and the Angle is on the first, four quadrants or Y positive half shaft, the labeling azimuth of the current tower is lower;
when the PreAngle is on the X positive half shaft and the Angle is on the second, third, Y negative half shaft or X positive half shaft, the labeling direction of the current tower is up;
when the PreAngle is on the X negative half shaft and the Angle is on the first, four quadrants or Y positive half shaft, the labeling azimuth of the current tower is lower;
when the PreAngle is on the X negative half shaft and the Angle is on the second, third, Y negative half shaft or the X negative half shaft, the labeling direction of the current tower is up;
when the PreAngle is on the Y positive half shaft and the Angle is on the first quadrant, the second quadrant, the X positive half shaft or the Y positive half shaft, the labeling direction of the current tower is left;
when the PreAngle is on the Y positive half shaft and the Angle is on the third, fourth or X negative half shaft, the labeling azimuth of the current tower is right;
when the PreAngle is on the Y negative half shaft and the Angle is on the first, second quadrants, X positive half shaft or Y negative half shaft, the labeling azimuth of the current tower is left;
when the PreAngle is on the Y negative half shaft and the Angle is on the third, fourth or X negative half shaft, the labeling azimuth of the current tower is right;
when the front tower is a termination tower, and the azimuth angle from the front tower to the last tower is in the first quadrant and the second quadrant of the Cartesian plane coordinate system, the labeling azimuth of the front tower is left; and when the azimuth angle from the current tower to the last tower is in the third quadrant or the fourth quadrant of the Cartesian plane coordinate system, the labeling azimuth of the current tower is right.
Further preferably, the anchor point coordinates of the current tower are determined according to the coordinates of the tower, the marked size and the offset parameter.
Further preferably, the anchor point coordinates of the current tower are (x_anno, y_anno), and the calculation formulas of x_anno and y_anno are as follows:
when the current tower's noted azimuth is left,
X_Anno=X_Pole-width–offsetX,
Y_Anno=Y_Pole–offsetY;
when the current tower's noted azimuth is right,
X_Anno=X_Pole+offsetX,
Y_Anno=Y_Pole–offsetY;
when the current pole tower is marked with an upper azimuth,
X_Anno=X_Pole–width/2+offsetX,
Y_Anno=Y_Pole+height+offsetY;
when the current pole tower is marked with a lower azimuth,
X_Anno=X_Pole–width/2+offsetX,
Y_Anno=Y_Pole+offsetY;
wherein X_Anno is the X-axis coordinate value of the anchor point, Y_Anno is the Y-axis coordinate value of the anchor point, X_Pole is the X-axis coordinate value of the tower position, Y_Pole is the Y-axis coordinate value of the tower, width is the marked width, height is the marked height, offsetX is the X-axis offset parameter of the anchor point relative to the tower position, offsetY is the Y-axis offset parameter of the anchor point relative to the tower position.
The beneficial effects of the invention are as follows:
1) The automatic labeling of the line path towers can be realized, the manual operation is avoided, and the design efficiency is improved; specifically, the method can realize the position information determination of the transformer through intelligent equipment with data processing and storage such as a smart phone, a tablet personal computer, a notebook computer or a desktop computer. In the implementation process, after the path diagram is acquired, the labeling position of the current tower can be determined through the path relation between the adjacent towers, so that manual operation is avoided, and the problems of large workload, error in the processing process and the like caused by manual operation are avoided;
2) The labeling of the gland path of the tower can be avoided, and the path diagram is beautified; specifically, the method and the device can directly confirm the azimuth and the anchor point of the tower marking through the intelligent equipment, determine the azimuth of the tower marking according to the azimuth between the tower and the last tower and/or the next tower, and determine the anchor point of the tower marking through the coordinates of the tower, the marked size and the offset parameter, thereby effectively avoiding the marking gland path of the tower and beautifying the path diagram in the marking process.
Detailed Description
The invention will be further elucidated with reference to the drawings and to specific embodiments. The present invention is not limited to these examples, although they are described in order to assist understanding of the present invention. Specific structural and functional details disclosed herein are merely representative of example embodiments of the invention. This invention may, however, be embodied in many alternate forms and should not be construed as limited to the embodiments set forth herein.
It will be understood that, although the terms first, second, etc. may be used herein to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another element. For example, a first element could be termed a second element, and, similarly, a second element could be termed a first element, without departing from the scope of example embodiments of the present invention.
It should be understood that for the term "and/or" that may appear herein, it is merely one association relationship that describes an associated object, meaning that there may be three relationships, e.g., a and/or B, may represent: a alone, B alone, and both a and B; for the term "/and" that may appear herein, which is descriptive of another associative object relationship, it means that there may be two relationships, e.g., a/and B, it may be expressed that: a alone, a alone and B alone; in addition, for the character "/" that may appear herein, it is generally indicated that the context associated object is an "or" relationship.
It will be understood that when an element is referred to herein as being "connected," "connected," or "coupled" to another element, it can be directly connected or coupled to the other element or intervening elements may be present. In contrast, when an element is referred to herein as being "directly connected" or "directly coupled" to another element, it means that there are no intervening elements present. In addition, other words used to describe relationships between elements (e.g., "between … …" pair "directly between … …", "adjacent" pair "directly adjacent", etc.) should be interpreted in a similar manner.
It is to be understood that the terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of example embodiments of the invention. As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises," "comprising," "includes," "including" and/or "including," when used herein, specify the presence of stated features, integers, steps, operations, elements, and/or components, and do not preclude the presence or addition of one or more other features, quantities, steps, operations, elements, components, and/or groups thereof.
It should be appreciated that in some alternative embodiments, the functions/acts noted may occur out of the order noted in the figures. For example, two figures shown in succession may in fact be executed substantially concurrently or the figures may sometimes be executed in the reverse order, depending upon the functionality/acts involved.
It should be understood that specific details are provided in the following description to provide a thorough understanding of the example embodiments. However, it will be understood by those of ordinary skill in the art that the example embodiments may be practiced without these specific details. For example, a system may be shown in block diagrams in order to avoid obscuring the examples with unnecessary detail. In other instances, well-known processes, structures, and techniques may be shown without unnecessary detail in order to avoid obscuring the example embodiments.
Example 1:
the embodiment provides a tower labeling method, as shown in fig. 1, comprising the following steps:
obtaining a path diagram, wherein the path diagram comprises a plurality of towers and paths among the towers;
and determining the labeling position of the current tower according to the path relation between the adjacent towers.
Specifically, when determining the labeling position of the current tower according to the path relation between the adjacent towers, the specific steps are as follows:
determining the labeling azimuth and anchor point coordinates of the current tower according to the path relation between the adjacent towers;
and determining the labeling position of the current tower according to the labeling azimuth and the anchor point coordinates of the current tower.
The embodiment can realize automatic labeling of the line path towers, avoid manual operation and improve design efficiency; specifically, the embodiment can realize the position information determination of the transformer through intelligent equipment with data processing and storage such as a smart phone, a tablet personal computer, a notebook personal computer or a desktop personal computer. In the implementation process, the marking position of the current pole tower can be determined through the path relation between the adjacent pole towers after the path diagram is acquired, so that manual operation is avoided, and the problems of large workload, error in the processing process and the like caused by manual operation are avoided.
In this embodiment, the current tower labeling orientation includes up, down, left, and right. It should be noted that, the labeling azimuth of the current tower is located above, below, left or right of the current tower, and can also be arranged above left, below right of the current tower, and the labeling azimuth comprises up, down, left and right, so that the labeling requirements of towers at different positions can be met, and the problem of poor attractiveness of tower labeling caused by excessive azimuth is avoided.
Specifically, the labeling directions of the current tower are as follows:
when the front tower is the initial tower, and the azimuth angle from the front tower to the next tower is in the first quadrant and the second quadrant of the Cartesian plane coordinate system, the labeling azimuth of the front tower is left; when the azimuth angle from the current tower to the next tower is in the third quadrant and the fourth quadrant of the Cartesian plane coordinate system, the labeling azimuth of the current tower is right;
when the front tower is a middle tower, defining the azimuth Angle from the last tower to the current tower as PreAngle, and defining the azimuth Angle from the current tower to the next tower;
when the PreAngle is in the first quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the first quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is up;
when the PreAngle is in the first quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the first quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the second quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is lower;
when the PreAngle is in the second quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the second quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the second quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the third quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the third quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the third quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is right;
when the PreAngle is in the third quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is lower;
when the PreAngle is in the fourth quadrant and the Angle is in the first quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the fourth quadrant and the Angle is in the second quadrant, the labeling azimuth of the current tower is left;
when the PreAngle is in the fourth quadrant and the Angle is in the third quadrant, the labeling azimuth of the current tower is up;
when the PreAngle is in the fourth quadrant and the Angle is in the fourth quadrant, the labeling azimuth of the current tower is left;
the specific table is shown below:
when the PreAngle is on the X positive half shaft and the Angle is on the first, four quadrants or Y positive half shaft, the labeling azimuth of the current tower is lower;
when the PreAngle is on the X positive half shaft and the Angle is on the second, third, Y negative half shaft or X positive half shaft, the labeling direction of the current tower is up;
when the PreAngle is on the X negative half shaft and the Angle is on the first, four quadrants or Y positive half shaft, the labeling azimuth of the current tower is lower;
when the PreAngle is on the X negative half shaft and the Angle is on the second, third, Y negative half shaft or the X negative half shaft, the labeling direction of the current tower is up;
when the PreAngle is on the Y positive half shaft and the Angle is on the first quadrant, the second quadrant, the X positive half shaft or the Y positive half shaft, the labeling direction of the current tower is left;
when the PreAngle is on the Y positive half shaft and the Angle is on the third, fourth or X negative half shaft, the labeling azimuth of the current tower is right;
when the PreAngle is on the Y negative half shaft and the Angle is on the first, second quadrants, X positive half shaft or Y negative half shaft, the labeling azimuth of the current tower is left;
when the PreAngle is on the Y negative half shaft and the Angle is on the third, fourth or X negative half shaft, the labeling azimuth of the current tower is right;
the specific table is shown below:
when the front tower is a termination tower, and the azimuth angle from the front tower to the last tower is in the first quadrant and the second quadrant of the Cartesian plane coordinate system, the labeling azimuth of the front tower is left; and when the azimuth angle from the current tower to the last tower is in the third quadrant or the fourth quadrant of the Cartesian plane coordinate system, the labeling azimuth of the current tower is right.
In this embodiment, the anchor point coordinates of the current tower are determined according to the coordinates of the tower, the marked size and the offset parameter.
Specifically, the anchor coordinates of the current tower are (x_anno, y_anno), and the calculation formulas of x_anno and y_anno are as follows:
when the current tower's noted azimuth is left,
X_Anno=X_Pole-width–offsetX,
Y_Anno=Y_Pole–offsetY;
when the current tower's noted azimuth is right,
X_Anno=X_Pole+offsetX,
Y_Anno=Y_Pole–offsetY;
when the current pole tower is marked with an upper azimuth,
X_Anno=X_Pole–width/2+offsetX,
Y_Anno=Y_Pole+height+offsetY;
when the current pole tower is marked with a lower azimuth,
X_Anno=X_Pole–width/2+offsetX,
Y_Anno=Y_Pole+offsetY;
wherein X_Anno is the X-axis coordinate value of the anchor point, Y_Anno is the Y-axis coordinate value of the anchor point, X_Pole is the X-axis coordinate value of the tower position, Y_Pole is the Y-axis coordinate value of the tower, width is the marked width, height is the marked height, offsetX is the X-axis offset parameter of the anchor point relative to the tower position, offsetY is the Y-axis offset parameter of the anchor point relative to the tower position.
According to the method, the position and the anchor point of the tower marking can be directly confirmed through the intelligent equipment, the position of the tower marking is determined according to the azimuth angle between the tower and the last tower and/or the next tower, and the anchor point of the tower marking is determined through the coordinates of the tower, the marked size and the offset parameters, so that the marking gland path of the tower is effectively avoided in the marking process, and the path diagram is beautified.
It will be apparent to those skilled in the art that the modules or steps of the invention described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, or they may alternatively be implemented in program code executable by computing devices, such that they may be stored in a memory device for execution by the computing devices, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps within them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The various embodiments described above are merely illustrative and may or may not be physically separate if reference is made to the unit being described as separate components; if a component is referred to as being a unit, it may or may not be a physical unit, may be located in one place, or may be distributed over multiple network elements. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
The above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some of the technical features thereof can be replaced by equivalents. Such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.
Finally, it should be noted that the invention is not limited to the alternative embodiments described above, but can be used by anyone in various other forms of products in the light of the present invention. The above detailed description should not be construed as limiting the scope of the invention, which is defined in the claims and the description may be used to interpret the claims.