The invention discloses a house type-based electric box tidy wiring method and
system and a storage medium, and the method comprises the steps: generating a 2D grid for a room, extracting a plurality of points for path selection in the room, abstracting the room into the 2D grid, throwing away the environment influence of different house types of rooms, improving the abstraction degree, enabling the performance to be stable, enabling the
system to be easy to understand, and improving the efficiency. Personalized modification can be carried out according to specific business. An entrance and a plurality of exits are specified in a 2D grid, so that a plurality of feasible basic paths in a room are simulated, a foundation is laid for free wiring,
reusability is good, extension is easy, room space is utilized to a great extent, the wiring effect can be effectively improved, on the basis, a plurality of paths are continuously combined to obtain a prefix tree under a house type, and the construction efficiency is improved. According to the method, a plurality of paths are orderly arranged, so that the accuracy rate during path merging is ensured, each
branch path is extracted through conversion from a prefix tree to a
ternary tree, and final wiring is obtained based on offset of the
branch paths.