The invention provides a ship path
planning method and device for a near-
shore environment and
electronic equipment, and belongs to the technical field of
artificial intelligence, and the method comprises the steps: carrying out the rasterization of a near-
shore environment image, and obtaining a navigation
space model; setting initial parameters of the improved
potential field-
ant colony
algorithm and initializing a path taboo table, further determining
pheromone distribution and synthetic
potential field acting force of each path point, calculating a
transfer probability of transferring ants to other nodes to determine a next node, and updating the taboo table; after it is judged that one
ant traverses all nodes to reach a target point,
pheromone distribution is updated, and a traversal path is recorded; iteration is carried out until all ants
traverse all nodes, traversal paths of all ants are obtained, and an optimal path is determined. According to the method, the
potential field-
ant colony
algorithm is improved, potential field information is introduced, and a
heuristic information function is dynamically adjusted; selecting a probability optimization
algorithm structure by adjusting a path; by considering the sailing characteristics of the ship, the requirement of autonomous sailing of the ship is met.