Socket point position ordering method and socket wiring method

文档序号:1953163 发布日期:2021-12-10 浏览:12次 中文

阅读说明:本技术 插座点位排序方法及插座布线方法 (Socket point position ordering method and socket wiring method ) 是由 马海山 李磊磊 于 2021-07-26 设计创作,主要内容包括:本发明提供一种插座点位排序方法及插座布线方法,该插座点位排序方法包括:计算房屋的起始房间到房屋的其他房间的最优路径;最优路径为起始房间到其他房间时穿过的门洞数量最少的路径;从预设的起始墙面开始,基于最优路径以预设的方向遍历所有墙面的插座点位;房屋的插座点位全部遍历完成后,根据插座点位的遍历结果得到房屋的插座点位的排序结果。本发明提供的插座点位排序方法及插座布线方法,通过计算房屋的起始房间到房屋的其他房间的最优路径,基于最优路径以预设的方向遍历所有墙面的插座点位,实现了对于插座点位的自动化优化排序,有利于得到用于布线的优选路径,以及提高布线效率。(The invention provides a socket point ordering method and a socket wiring method, wherein the socket point ordering method comprises the following steps: calculating the optimal path from the initial room of the house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to other rooms; traversing all socket point positions of the wall surface in a preset direction based on the optimal path from a preset initial wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations. According to the socket point sorting method and the socket wiring method, the optimal path from the initial room of the house to other rooms of the house is calculated, all the socket points on the wall surface are traversed in the preset direction based on the optimal path, automatic optimization sorting of the socket points is achieved, the optimal path for wiring is obtained, and wiring efficiency is improved.)

1. A socket point location ordering method is characterized by comprising the following steps:

calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms;

traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from the starting wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

2. The method of socket site ordering according to claim 1, further comprising:

judging whether the traversal path meets a door opening or not in the process of traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path; if the two rooms are in the optimal path, judging whether the door opening and the two rooms connected with the door opening are in the optimal path, if so, penetrating through the door opening, and continuously traversing the socket point positions on the wall surfaces of the next rooms; if not, the socket does not pass through the door opening, and other socket points on the current wall surface are traversed forwards continuously.

3. The socket site ordering method according to claim 1, wherein the starting room is a room in which a distribution box is located, the starting wall surface is a wall surface in which the distribution box is located, the distribution box is regarded as one socket site, and the starting site is the distribution box.

4. The method of claim 2, wherein before traversing the socket points of all walls in a predetermined direction based on the optimal path starting from a predetermined starting wall, the method further comprises: acquiring a point location list; the point location list comprises socket point locations and door opening point locations, and the socket point locations and the door opening point locations in the point location list are ordered according to the preset direction by taking a wall surface as a unit;

starting from a preset initial wall surface, traversing the socket point positions of all wall surfaces in a preset direction based on the optimal path, and specifically comprising the following steps: traversing the point location lists of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface;

the judging whether the door opening is met specifically comprises the following steps: and judging whether the door opening is met according to whether the door opening point is traversed.

5. The method of socket point location ranking according to claim 4, wherein prior to said calculating an optimal path from a starting room of a house to other rooms of said house, said method further comprises:

acquiring original house type data, and acquiring a data mapping relation according to the original house type data; the data mapping relation at least comprises the mapping relation between a room and a door opening, the mapping relation between a wall surface and a socket point position and the mapping relation between the wall surface and the door opening; and the data mapping relation is used for acquiring the optimal path, the starting wall surface, the starting room and the point location list.

6. A socket wiring method based on the socket site ordering method according to any one of claims 1 to 5, comprising:

and carrying out wiring processing on the socket point positions according to the sequencing result of the socket point positions of the house to generate a wiring loop.

7. The receptacle wiring method of claim 6, further comprising:

adding the wiring loop into the original house type data to obtain processed house type data; and pushing the processed house type data to a terminal for rendering by the terminal to obtain a house type graph with the distributed socket lines.

8. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor when executing the program performs the steps of the method of socket point ordering according to any of claims 1-5 or the steps of the method of socket wiring according to claim 6 or 7.

9. A non-transitory computer readable storage medium having stored thereon a computer program, which when executed by a processor, performs the steps of the outlet point sorting method according to any one of claims 1-5 or the steps of the outlet wiring method according to claim 6 or 7.

10. A computer program product comprising computer programs/instructions, characterized in that said computer programs/instructions, when executed by a processor, implement the steps of the outlet site ordering method according to any of claims 1-5 or the steps of the outlet wiring method according to claim 6 or 7.

Technical Field

The invention relates to the technical field of computers, in particular to a socket point position ordering method and a socket wiring method.

Background

The decoration BIM (Building Information Modeling) is a digital model which is based on various relevant Information data of decoration project and provides service for the whole life cycle design, construction and operation of the decoration project. The designer designs the decoration scheme for the customer using the BIM software, and cannot design the circuit diagram manually because the designer does not understand the rule of the circuit wiring, and even if the designer understands the rule of the circuit wiring, the manual design of the circuit diagram is troublesome. It is therefore desirable to implement an algorithm that automatically draws the current house type circuit, saving the designer time and reducing design errors, while the core of the automatic routing algorithm is the ordering of the sites in the loop.

At present, BIM software does not have automatic wiring capacity, designers can only manually wire, and during manual wiring, point positions are sequenced according to experience and then wired. Empirically ordering the sites may not result in a preferred path for routing, and may also result in inefficient routing.

Disclosure of Invention

Aiming at the problems in the prior art, the invention provides a socket point position ordering method and a socket wiring method.

The invention provides a socket point position ordering method, which comprises the following steps: calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms; traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from the starting wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

According to the socket point location ordering method provided by the invention, the method further comprises the following steps: judging whether the traversal path meets a door opening or not in the process of traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path; if the two rooms are in the optimal path, judging whether the door opening and the two rooms connected with the door opening are in the optimal path, if so, penetrating through the door opening, and continuously traversing the socket point positions on the wall surfaces of the next rooms; if not, the socket does not pass through the door opening, and other socket points on the current wall surface are traversed forwards continuously.

According to the socket point location sequencing method provided by the invention, the starting room is a room where a distribution box is located, the starting wall surface is a wall surface where the distribution box is located, the distribution box is regarded as one socket point location, and the starting point location is the distribution box.

According to the socket point location ordering method provided by the present invention, before traversing the socket point locations of all wall surfaces in a preset direction based on the optimal path starting from a preset starting wall surface, the method further includes: acquiring a point location list; the point location list comprises socket point locations and door opening point locations, and the socket point locations and the door opening point locations in the point location list are ordered according to the preset direction by taking a wall surface as a unit; starting from a preset initial wall surface, traversing the socket point positions of all wall surfaces in a preset direction based on the optimal path, and specifically comprising the following steps: traversing the point location lists of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; the judging whether the door opening is met specifically comprises the following steps: and judging whether the door opening is met according to whether the door opening point is traversed.

According to the socket point location ordering method provided by the invention, before the calculating of the optimal path from the starting room of the house to other rooms of the house, the method further comprises the following steps: acquiring original house type data, and acquiring a data mapping relation according to the original house type data; the data mapping relation at least comprises the mapping relation between a room and a door opening, the mapping relation between a wall surface and a socket point position and the mapping relation between the wall surface and the door opening; and the data mapping relation is used for acquiring the optimal path, the starting wall surface, the starting room and the point location list.

The invention also provides a socket wiring method, which comprises the following steps: and carrying out wiring processing on the socket point positions according to the sequencing result of the socket point positions of the house to generate a wiring loop.

According to the invention, the socket wiring method further comprises the following steps: adding the wiring loop into the original house type data to obtain processed house type data; and pushing the processed house type data to a terminal for rendering by the terminal to obtain a house type graph with the distributed socket lines.

The invention also provides a socket point position sequencing device, which comprises: an optimal path calculation module for: calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms; the socket point location sequencing module is used for: traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

The present invention also provides a socket wiring device, comprising: an automatic routing module to: and carrying out wiring processing on the socket point positions according to the sequencing result of the socket point positions of the house to generate a wiring loop.

The invention also provides an electronic device, which comprises a memory, a processor and a computer program which is stored on the memory and can run on the processor, wherein the processor executes the program to realize the socket position ordering method or the socket wiring method.

The present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of any of the above-described outlet site ordering methods or the outlet wiring methods.

The present invention also provides a computer program product comprising computer programs/instructions, wherein the computer programs/instructions, when executed by a processor, implement the steps of any of the above-mentioned socket location ordering methods or the socket wiring methods.

According to the socket point ordering method and the socket wiring method, the optimal path from the initial room of the house to other rooms of the house is calculated, the socket points on all wall surfaces are traversed in the preset direction based on the optimal path from the preset initial wall surface, and finally, the traversal is completed and the socket point ordering result is obtained, so that the automatic optimization ordering of the socket points is realized, the optimal path for wiring is favorably obtained, and the wiring efficiency is improved.

Drawings

In order to more clearly illustrate the technical solutions of the present invention or the prior art, the drawings needed for the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and those skilled in the art can also obtain other drawings according to the drawings without creative efforts.

FIG. 1 is a schematic flow chart of a socket site location sorting method according to the present invention;

FIG. 2 is a schematic diagram of an original home graph in the socket site ordering method according to the present invention;

FIG. 3 is a schematic diagram of an optimal path obtained based on the original house layout of FIG. 2 in the socket site location sorting method provided by the present invention;

fig. 4 is a schematic diagram illustrating arrangement of socket points on a wall surface in the socket point ordering method according to the present invention;

fig. 5 is a top view of a traversal path of wall socket points in the socket point sorting method according to the present invention;

FIG. 6 is a schematic flow chart of a socket wiring method provided by the present invention;

FIG. 7 is a second schematic flow chart of the socket wiring method provided by the present invention;

FIG. 8 is a schematic structural diagram of a socket site ordering apparatus provided in the present invention;

FIG. 9 is a schematic structural view of a receptacle wiring device provided by the present invention;

fig. 10 is a schematic structural diagram of an electronic device provided by the present invention.

Detailed Description

In order to make the objects, technical solutions and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is obvious that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.

The method for sorting the socket sites and the method for routing the sockets according to the present invention will be described with reference to fig. 1 to 10.

Fig. 1 is a schematic flow chart of a socket site location sorting method according to the present invention. As shown in fig. 1, the method includes:

step 101, calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings to pass through from the starting room to the other rooms.

The socket point position ordering method provided by the invention can be used for processing on the basis of the acquired house type data. First, an optimal path is calculated from the starting room of the house to the other rooms of the house. Wherein the starting room is a selected one of the rooms in the house. Because the circuit is usually routed through the door opening while traveling to the ground, the optimal path is the path with the least number of door openings from the starting room to the other rooms to save wiring loss.

Fig. 2 is a schematic diagram of an original home graph in the socket site location ordering method provided by the present invention. As shown in fig. 2, it is necessary to find an optimal path from the starting room to each of the other rooms.

Assuming the living room as the starting room, the first step is to calculate the optimal path from the living room to the other rooms, namely: the optimal path from the living room to any one room through the fewest rooms (i.e. the fewest number of door openings to pass through). When the optional paths are judged, the number of the door openings of the non-starting room can be judged, then the paths from the door openings to the starting room are respectively obtained, the obtained paths are used as the optional paths, and the optimal paths are screened from the optional paths.

Fig. 3 is a schematic diagram of an optimal path obtained based on the original house layout diagram of fig. 2 in the socket site location sorting method provided by the present invention. As shown in fig. 3, the optimal path screening results are as follows:

parlor-kitchen: living room, kitchen.

Living room-master bed: living room, master bed.

Parlor-secondary bed 1: there are two ways, one is: the other one of the two ways is as follows: the number of the door openings through which the first path passes is less obviously in the living room, the secondary lying room 2 and the secondary lying room 1, the first path is selected, and the final path is as follows: parlor, secondary bed 1.

Parlor-secondary lying 2: similarly, there are two paths, one is living room, sub-bed 1 and sub-bed 2, and the other is living room and sub-bed 2, obviously the number of door openings passed by the second path is less, and the obtained optimal path is: parlor, secondary bed 2.

Living room-toilet: living room, toilet.

Living room-balcony: living room, main bed and balcony.

Step 102, traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from a starting wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

A starting wall may be preset, which may or may not be located in the starting room. Starting from the starting wall surface, the jack points of all the wall surfaces are traversed in a preset direction (such as clockwise or counterclockwise) based on the calculated optimal path. The optimal path is used for optimizing the path traversing all the socket points of the wall surface in the preset direction. The optimization objective may be, for example, to minimize the wire length when routing in sequence based on the socket traversal results. When the socket point locations of all the wall surfaces are traversed in the preset direction from the preset initial wall surface, the socket point locations of all the wall surfaces can be traversed in the preset direction from the initial point location of the initial wall surface, and the initial point location can be set. And after all the socket point locations of the house are traversed, obtaining the sequencing results of all the socket point locations of the house according to the traversal results of the socket point locations. Whether the socket point locations of the house are completely traversed can be judged according to whether the starting point locations are traversed again.

Fig. 4 is a schematic diagram of arrangement of socket points on a wall surface in the socket point sorting method provided by the present invention. For example, if the wall shown in fig. 4 is a starting wall, the point 2 is a starting point, and the vector direction is a preset direction, the socket point of the wall is traversed from the point 2 along the preset direction. Then from point 2, traversal to point 3 may be further traversed to the adjacent wall or wall of the next room. And finally, after traversing each non-initial wall surface of the house, returning to the initial wall surface, and traversing the socket point location along the preset direction, namely traversing to the point location 1. When traversing to the point location 2 again, it is described that the socket point locations of the house are completely traversed, and the point location 2 is not repeatedly traversed any more.

According to the socket point ordering method provided by the invention, the optimal path from the starting room of the house to other rooms of the house is calculated, the socket points of all wall surfaces are traversed in the preset direction from the preset starting wall surface based on the optimal path, and finally, the traversal is completed and the socket point ordering result is obtained, so that the automatic optimization ordering of the socket points is realized, the optimal path for wiring is favorably obtained, and the wiring efficiency is improved.

According to the socket point location ordering method provided by the invention, the method further comprises the following steps: judging whether the traversal path meets a door opening or not in the process of traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path; if the two rooms are in the optimal path, judging whether the door opening and the two rooms connected with the door opening are in the optimal path, if so, penetrating through the door opening, and continuously traversing the socket point positions on the wall surfaces of the next rooms; if not, the socket does not pass through the door opening, and other socket points on the current wall surface are traversed forwards continuously.

In the traversing process, judging whether the traversing path meets a door opening or not; if the door opening is met, judging whether the door opening and two rooms connected with the door opening are in the optimal path. The optimal path includes at least an originating room, a target room, and a door opening between the two rooms. It can be appreciated, therefore, that the entry door must not be in the optimal path because the entry door is not a door opening between two rooms. As shown in fig. 2, the door opening between sub-bed 1 and sub-bed 2 is also not in the optimal path.

And if the door opening and the two rooms connected with the door opening are in the optimal path, the door opening is used for wiring, and the socket point of the wall surface of the next room is continuously traversed after the door opening passes through the door opening. The traversal process of the socket point positions of the wall surface is always carried out according to the preset direction of the wall surface. And if the door opening and the two rooms connected with the door opening are not in the optimal path, the other socket points on the current wall surface are continuously traversed forwards without passing through the door opening. And if the socket point of the current wall surface is completely traversed in the traversing process of the socket point of the wall surface, searching the adjacent wall surface of the current room according to the preset direction, and continuously traversing the socket point on the adjacent wall surface. And after all the socket point locations of the house are traversed, obtaining the sequencing results of all the socket point locations of the house according to the traversal results of the socket point locations.

Fig. 5 is a top view of a traversal path of wall socket bits in the socket bit sorting method provided by the present invention. As shown in fig. 5, starting from the wall surface where the distribution box is located (of course, other wall surfaces may be set as the starting wall surface), the whole room is scanned by rotating counterclockwise, and the final sequence of the traversal of the socket points on the wall surface is given by combining the calculated optimal path from the starting room to the other rooms in the house. As shown in fig. 5: when the second lying position 2 is scanned, a door opening 501 is encountered, and whether the traversal path passes through the door opening depends on whether each calculated optimal path includes the door opening, that is, whether the traversal path passes through the door opening, since none of the 6 optimal paths shown in fig. 3 passes through the door opening, at this time, the traversal path is selected to not pass through the door opening, and the traversal is continued for other socket points on the current wall surface. When the bathroom is scanned, a door opening is encountered, and the door opening is in the optimal path from the living room to the bathroom, so that the socket point of the wall surface in the bathroom is traversed continuously through the door opening.

As shown in fig. 4, the arrangement of the socket points on the wall surface in the socket point ordering method is schematically illustrated, and the wall surface shown in fig. 4 may be, for example, the wall surface 502 in fig. 5, and is performed in a preset direction in the traversal process of the socket points on each wall surface. As shown in fig. 4, 3 socket point locations are arranged on the wall surface, which are respectively point locations 1-3, and when the socket point locations on the wall surface are traversed, the socket point locations are traversed in a preset direction, for example, when all the wall surfaces are traversed in a counterclockwise direction, and the wall surface shown in fig. 4 is traversed, the preset direction is the vector direction shown in fig. 4, and the socket point locations are sorted according to the sequence of the socket point locations traversed in the vector direction. As shown in fig. 4, the resulting sequence of jack sites is: point 1- > point 2- > point 3.

After the socket point locations of all the wall surfaces are traversed in the preset direction from the preset initial wall surface according to the process, the sequencing results of all the socket point locations of the house are obtained according to the traversal results of the socket point locations.

According to the socket point ordering method provided by the invention, the socket points of all the wall surfaces are traversed in the preset direction from the preset starting wall surface, and in the traversing process, according to whether the door opening is in the optimal path from the starting room to other rooms of the house, the door opening is selected to pass through or not to pass through, the traversing is finally completed, and the socket point ordering result is obtained, so that the automatic optimization ordering of the socket points is realized, the optimal path for wiring is favorably obtained, and the wiring efficiency is improved.

According to the socket point location sequencing method provided by the invention, the starting room is a room where a distribution box is located, the starting wall surface is a wall surface where the distribution box is located, the distribution box is regarded as one socket point location, and the starting point location is the distribution box.

The distribution box is a source of power supply in a room, and power of electric devices in the room is usually introduced from the distribution box. Therefore, the starting room can be set as the room where the distribution box is located, and the wall surface where the distribution box is located can be used as the starting wall surface. Because the distribution box also participates in networking, the distribution box is regarded as a socket point location, and the distribution box can be used as a starting point location, namely, the distribution box starts to traverse the socket point location on the wall surface along a preset direction, and finally the sequencing result of the socket point location is obtained.

According to the socket point location sequencing method provided by the invention, the starting room is the room where the distribution box is located, the starting wall surface is the wall surface where the distribution box is located, and the starting point location is the distribution box, so that the practicability and the convenience are improved.

According to the socket point location ordering method provided by the present invention, before traversing the socket point locations of all wall surfaces in a preset direction based on the optimal path starting from a preset starting wall surface, the method further includes: acquiring a point location list; the point location list comprises socket point locations and door opening point locations, and the socket point locations and the door opening point locations in the point location list are ordered according to the preset direction by taking a wall surface as a unit; starting from a preset initial wall surface, traversing the socket point positions of all wall surfaces in a preset direction based on the optimal path, and specifically comprising the following steps: traversing the point location lists of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; the judging whether the door opening is met specifically comprises the following steps: and judging whether the door opening is met according to whether the door opening point is traversed.

Before traversing all socket point locations of the wall surface in a preset direction based on the optimal path from a preset initial wall surface, a point location list needs to be obtained first. The point location list comprises socket point locations and door opening point locations, and the socket point locations and the door opening point locations in the point location list are ordered according to a preset direction by taking the wall surface as a unit. The socket point locations and the door opening point locations of each wall surface can be sorted and stored in a direction consistent with the preset direction of the passing time, and then the socket point locations and the door opening point locations of each wall surface jointly form a point location list. Socket point locations and door opening point locations on different wall surfaces need to be distinguished in the point location list, but the point location list does not require sequencing according to a preset direction. However, when the socket points of all the wall surfaces are traversed in the preset direction from the preset initial wall surface, the socket points and the door opening points of the corresponding wall surfaces can be found for traversal.

When the socket point locations of all the wall surfaces are traversed in the preset direction from the preset initial wall surface, the corresponding wall surfaces can be found according to the preset direction because the sequence of the wall surfaces is known, and the socket point locations and the door opening point locations in the point location list corresponding to the corresponding wall surfaces can also be found. The socket point locations and the door opening point locations of the wall surfaces are ordered according to the preset direction, so that the socket point locations of the corresponding wall surfaces can be traversed according to the preset direction by sequentially traversing according to the order of the socket point locations and the door opening point locations of the corresponding wall surfaces in the point location list.

Since the socket point locations of all the wall surfaces are traversed in the preset direction from the preset initial wall surface, whether the socket points meet the door opening needs to be judged, and then, when the socket points pass through the traversal point location list, whether the socket points meet the door opening is judged according to whether the socket points are traversed to the door opening point locations or not because the door opening point locations are stored in the point location list. And determining whether to traverse the next room through the door opening or continue traversing in the room according to whether the door opening is in the optimal path.

According to the socket point location sequencing method provided by the invention, the socket point locations of all wall surfaces are traversed in the preset direction and whether the socket points meet the door opening is judged by utilizing the point location list comprising the socket point locations and the door opening point locations, so that the traversal process is simplified, and the traversal efficiency is improved.

According to the socket point location ordering method provided by the invention, before the calculating of the optimal path from the starting room of the house to other rooms of the house, the method further comprises the following steps: acquiring original house type data, and acquiring a data mapping relation according to the original house type data; the data mapping relation at least comprises the mapping relation between a room and a door opening, the mapping relation between a wall surface and a socket point position and the mapping relation between the wall surface and the door opening; and the data mapping relation is used for acquiring the optimal path, the starting wall surface, the starting room and the point location list.

Before calculating the optimal path from the initial room of the house to other rooms of the house, the original house type data needs to be acquired, and the data mapping relation is acquired according to the original house type data. The data mapping relation at least comprises the mapping relation between a room and a door opening, the mapping relation between a wall surface and a socket point position and the mapping relation between the wall surface and the door opening. The mapping relationship between the rooms and the door opening, for example, for a certain door opening, it is clear which two rooms are connected, or whether the door opening is an entrance door. The mapping relationship between the wall surface and the socket point location, such as the position and the type of a socket on a certain wall surface (for example, the socket is a common socket or a distribution box). The mapping relationship between the wall surface and the door opening is the wall surface where the door opening is located. And obtaining the mapping relation between the room and the socket point positions according to the mapping relation between the wall surface and the socket point positions. After the mapping relation is obtained according to the original house type data, the mapping relation can be assembled into intermediate state data available for an algorithm to be stored.

And obtaining an optimal path, a starting wall surface, a starting room and a point location list according to the data mapping relation. The starting point location can be obtained from the original house type data. The starting wall surface can be the wall surface where the starting point location is located, after the starting point location is obtained, the starting wall surface can be obtained according to the mapping relation between the wall surface and the socket point location, and the starting room can be obtained according to the mapping relation between the room and the socket point location. The optimal path is the path with the least number of door openings which are penetrated from the starting room to other rooms, and the optimal path can be obtained according to the mapping relation between the starting room and the door openings. And obtaining a point location list according to the mapping relation between the wall surface and the socket point location and the mapping relation between the wall surface and the door opening.

According to the socket point position ordering method provided by the invention, the data mapping relation is obtained according to the original house type data by obtaining the original house type data; the data mapping relation at least comprises a room and a door opening, a wall surface and socket point locations and a mapping relation between the wall surface and the door opening, and an optimal path, a starting wall surface, a starting room and point location list are obtained according to the data mapping relation, so that a foundation is provided for socket point location sequencing.

Fig. 6 is a schematic flow chart of a socket wiring method provided by the present invention. The socket wiring method can be implemented based on the socket site location ordering method provided by any of the above embodiments. The method comprises the following steps:

and step S1, carrying out wiring processing on the socket points according to the sequencing result of the socket points of the house, and generating a wiring loop.

And after the sequencing results of all the socket point positions of the house are obtained, the socket point positions are sequentially connected according to the sequencing sequence of the socket point positions to generate a wiring loop, so that the structure of the socket point position circuit is realized.

According to the socket wiring method provided by the invention, the socket point positions are connected according to the sequencing result of all the socket point positions of the house to generate the wiring loop, so that the structure of the socket point position circuit is realized, and the wiring of an optimized path is facilitated.

According to the invention, the socket wiring method further comprises the following steps: adding the wiring loop into the original house type data to obtain processed house type data; and pushing the processed house type data to a terminal for rendering by the terminal to obtain a house type graph with the distributed socket lines.

And after the wiring loop is obtained, adding the wiring loop into the original house type data to obtain processed house type data, and pushing the processed house type data to a terminal for rendering by the terminal to obtain a house type graph with the distributed socket circuit. The terminal may be a client or a WebGL terminal, for example.

According to the socket wiring method provided by the invention, the wiring loop is added to the original house type data to obtain the processed house type data; and pushing the processed house type data to the terminal so as to render the terminal to obtain a house type diagram with the well-distributed socket lines, thereby realizing the display of automatic wiring in the house type diagram.

The following describes the wiring method of the socket provided by the present invention by way of an example. The socket wiring method provided by the invention comprises the following steps:

(1) and analyzing the original house type data.

In the step, the mapping relation between the room and the door, the room and the point location, the wall surface and the door and other data is calculated through geometric calculation and stored in Map (stored in a data format) for the subsequent steps, and the adopted calculation method is conventional geometric knowledge, such as: vector calculations, point-to-line distance calculations, coordinate calculations of point translations on a line, etc.

(2) The starting room and starting point location are located.

And (3) finding coordinate information of the distribution box from the house type information by using the starting point position, namely the distribution box, wherein the starting wall surface and the starting room can be inquired according to the mapping relation from the coming point to the surface and from the point to the room calculated in the step (1) because the distribution box is also a point position.

(3) All rooms are processed to find the optimal path from the starting room to each room.

First, all non-originating rooms are traversed, and for each room, the following is done: if there is a path from the starting room to the target room, a door on the starting room must be passed, and one door connects two rooms, so the problem becomes that the path calculation from the starting room to each adjacent room of the target room can be traced back by the same idea, in the adjacent room from the starting room to the target room, by passing through the path with the least number of rooms, until there is one room in the adjacent rooms as the starting room.

(4) And sequencing the wall surfaces and the point locations.

Firstly, determining the traversing direction of a point location, which can be clockwise or counterclockwise, then sequencing the point locations on the current wall surface according to the preset direction of the sequence, sequencing the door opening on the wall surface as a point location, traversing the point location list after sequencing is completed, judging whether two rooms connected with the door opening are on the optimal path of one room if the two rooms are met with the door opening point, if so, going out, walking to another room, traversing the wall surfaces of the rooms according to the sequence, performing the same sequencing traversing processing on the points on each wall surface, and if the two rooms connected with the door opening are not on the optimal path, ignoring the door opening, directly traversing to the next point location, not performing door operation, and finally obtaining the sequencing information of all the point locations.

(5) The wiring is performed on a sorted basis.

For the designer, the circuit wiring design is not required to be carried out, the room which is walked first is not required to be confirmed, for hydropower workers, the optimal room sequence of wiring in the house type can be directly obtained without depending on past experience, and the efficiency is greatly improved.

The socket wiring method provided by the invention can complete point position wiring in a design scheme, solves the problem of low efficiency of sequencing and rewiring by hydropower workers according to self experience, can also provide an optimal path, saves wiring materials, can finally realize automatic wiring, and improves the efficiency of designers and workers.

The socket wiring method provided by the invention can be completed by a server and a client. And the server is responsible for compiling the BIM software and managing the software. An updater may also be provided for updating the client.

First, BIM customer end

1. Designing a house type at a BIM client, and determining and storing a strong electricity socket point position of each room;

2. and pushing the saved original house type data to the automatic wiring service of the service end.

Second, the server

1. Analyzing and processing the original house type data to assemble intermediate state data available for an algorithm;

2. using a sorting algorithm to sort the point locations;

3. carrying out wiring processing on the sequenced point positions to generate a wiring loop;

4. writing the generated connection data back to the original house type data, and pushing the processed house type data to a client or a WebGL terminal;

5. and rendering at the client or the WebGL terminal to obtain the user-type diagram with the distributed socket circuit.

Fig. 7 is a second schematic flow chart of the socket wiring method provided by the present invention. As shown in fig. 7, the outlet wiring method provided by the present invention includes:

designing a house type at a BIM client, adding point locations in the house type, pushing house type data to an automatic wiring service (running in a server), analyzing and assembling the house type data by the server, acquiring a starting point location, a starting wall surface and a starting room (space), calculating an optimal path from the starting room to each other room, and traversing all the wall surfaces clockwise or anticlockwise from the starting wall surface. In the traversing process, points on each wall surface are traversed and sequenced according to a preset direction. And judging whether the door opening is met in the traversing process, if the door opening is met, searching the door opening and the two connected rooms in all the optimal paths, and judging whether the door opening and the two connected rooms are on the optimal paths. If so, the wall surface and the point of the next room are processed recursively through the door opening. If not, the user does not pass through the door opening, and other point positions on the current wall surface are traversed forwards continuously. And if the door opening is not met in the traversal process, searching for the adjacent wall surface, and continuously sequencing the point positions on the adjacent wall surface.

And after traversing is finished, connecting lines according to the well-ordered point positions to generate a loop. And updating the generated loop information into the house type data, and pushing the house type data to a BIM client or a WebGL front end to render and generate a house type graph with the distributed socket circuit.

The following describes the socket point sorting device provided by the present invention, and the socket point sorting device described below and the socket point sorting method described above may be referred to in correspondence with each other.

Fig. 8 is a schematic structural diagram of the socket site ordering device provided in the present invention. As shown in fig. 8, the socket point sorting apparatus 100 includes an optimal path calculating module 10 and a socket point sorting module 20, wherein: the optimal path calculation module 10 is configured to: calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms; the socket site ordering module 20 is configured to: traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations; .

According to the socket point ordering device provided by the invention, the optimal path from the initial room of the house to other rooms of the house is calculated, the socket points of all wall surfaces are traversed in the preset direction based on the optimal path from the preset initial wall surface, and finally, the traversal is completed and the socket point ordering result is obtained, so that the automatic optimization ordering of the socket points is realized, the optimal path for wiring is favorably obtained, and the wiring efficiency is improved.

According to the socket location sequencing device provided by the present invention, the socket location sequencing module 20 is further configured to: judging whether the traversal path meets a door opening or not in the process of traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path; if the two rooms are in the optimal path, judging whether the door opening and the two rooms connected with the door opening are in the optimal path, if so, penetrating through the door opening, and continuously traversing the socket point positions on the wall surfaces of the next rooms; if not, the socket does not pass through the door opening, and other socket points on the current wall surface are traversed forwards continuously.

According to the socket point ordering device provided by the invention, the socket points of all the wall surfaces are traversed in the preset direction from the preset starting wall surface, and in the traversing process, according to whether the door opening is in the optimal path from the starting room to other rooms of the house, the door opening is selected to pass through or not to pass through, the traversing is finally completed, and the socket point ordering result is obtained, so that the automatic optimization ordering of the socket points is realized, the optimal path for wiring is favorably obtained, and the wiring efficiency is improved.

According to the socket point location sequencing device provided by the invention, the starting room is a room where a distribution box is located, the starting wall surface is a wall surface where the distribution box is located, the distribution box is regarded as one socket point location, and the starting point location is the distribution box.

According to the socket point position sequencing device, the starting room is the room where the distribution box is located, the starting wall surface is the wall surface where the distribution box is located, and the starting point position is the distribution box, so that the practicability and the convenience are improved.

According to the socket point location sequencing device provided by the present invention, before traversing the socket point locations of all wall surfaces in a preset direction based on the optimal path from a preset starting wall surface, the socket point location sequencing module 20 is further configured to: acquiring a point location list; the point location list comprises socket point locations and door opening point locations, and the socket point locations and the door opening point locations in the point location list are ordered according to the preset direction by taking a wall surface as a unit; the socket point location sorting module 20 is specifically configured to, when starting from a preset starting wall surface and traversing the socket point locations of all wall surfaces in a preset direction based on the optimal path: traversing the point location lists of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; when the socket point location sorting module 20 is used for determining whether a door opening is encountered, it is specifically configured to: and judging whether the door opening is met according to whether the door opening point is traversed.

According to the socket point location sequencing device provided by the invention, the socket point locations of all wall surfaces are traversed in the preset direction and whether the socket points meet the door opening is judged by utilizing the point location list comprising the socket point locations and the door opening point locations, so that the traversal process is simplified, and the traversal efficiency is improved.

According to the socket point location sequencing device provided by the invention, the device further comprises a preprocessing module, wherein the preprocessing module is used for acquiring original house type data before an optimal path calculation module 10 calculates optimal paths from a starting room of a house to other rooms of the house, and acquiring a data mapping relation according to the original house type data; the data mapping relation at least comprises the mapping relation between a room and a door opening, the mapping relation between a wall surface and a socket point position and the mapping relation between the wall surface and the door opening; and the data mapping relation is used for acquiring the optimal path, the starting wall surface, the starting room and the point location list.

According to the socket point position sequencing device, the data mapping relation is obtained according to the original house type data by obtaining the original house type data; the data mapping relation at least comprises a room and a door opening, a wall surface and socket point locations and a mapping relation between the wall surface and the door opening, and an optimal path, a starting wall surface, a starting room and point location list are obtained according to the data mapping relation, so that a foundation is provided for socket point location sequencing.

Fig. 9 is a schematic structural diagram of the outlet wiring device provided by the present invention. As shown in fig. 9, the outlet wiring device 200 includes an automatic wiring module 30, the automatic wiring module 30 being configured to: and carrying out wiring processing on the socket point positions according to the sequencing result of the socket point positions of the house to generate a wiring loop.

According to the socket wiring device provided by the invention, the socket points are connected according to the sequencing result of all the socket points in the house to generate the wiring loop, so that the structure of the socket point circuit is realized, and the wiring of an optimized path is facilitated.

According to the invention, the device further comprises a post-processing and sending module, wherein the post-processing and sending module is used for: adding the wiring loop to the original house type data to obtain processed house type data; and pushing the processed house type data to a terminal for rendering by the terminal to obtain a house type graph with the distributed socket lines.

According to the socket wiring device provided by the invention, the wiring loop is added to the original house type data to obtain the processed house type data; and pushing the processed house type data to the terminal so as to render the terminal to obtain a house type diagram with the well-distributed socket lines, thereby realizing the display of automatic wiring in the house type diagram.

Fig. 10 is a schematic structural diagram of an electronic device provided in the present invention, and as shown in fig. 10, the electronic device may include: a processor (processor)1010, a communication Interface (Communications Interface)1020, a memory (memory)1030, and a communication bus 1040, wherein the processor 1010, the communication Interface 1020, and the memory 1030 communicate with each other via the communication bus 1040. Processor 1010 may invoke logic instructions in memory 1030 to perform a socket point location ordering method comprising: calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms; traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

Furthermore, the logic instructions in the memory 1030 can be implemented in software functional units and stored in a computer readable storage medium when the logic instructions are sold or used as independent products. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.

In another aspect, the present invention also provides a computer program product, which includes a computer program stored on a non-transitory computer-readable storage medium, the computer program including program instructions, when the program instructions are executed by a computer, the computer being capable of executing the socket point sorting method provided by the above methods, the method including: calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms; traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program, which when executed by a processor is implemented to perform the above-mentioned socket point ordering method, the method including: calculating an optimal path from a starting room of a house to other rooms of the house; the optimal path is the path with the least number of door openings which are crossed from the starting room to the other rooms; traversing the socket point positions of all the wall surfaces in a preset direction based on the optimal path from a preset initial wall surface; and after all the socket point locations of the house are traversed, obtaining a sequencing result of the socket point locations of the house according to the traversal result of the socket point locations.

The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.

Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in the embodiments or some parts of the embodiments.

Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present 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 solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

19页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:照明电路自动布线方法、电子设备、存储介质及装置

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类