CN116112831A - Optical network path determination method, optical network path determination device, and storage medium - Google Patents

Optical network path determination method, optical network path determination device, and storage medium Download PDF

Info

Publication number
CN116112831A
CN116112831A CN202111328151.6A CN202111328151A CN116112831A CN 116112831 A CN116112831 A CN 116112831A CN 202111328151 A CN202111328151 A CN 202111328151A CN 116112831 A CN116112831 A CN 116112831A
Authority
CN
China
Prior art keywords
target
path
node
determining
point
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202111328151.6A
Other languages
Chinese (zh)
Inventor
姜世涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Individual
Original Assignee
Individual
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 Individual filed Critical Individual
Priority to CN202111328151.6A priority Critical patent/CN116112831A/en
Publication of CN116112831A publication Critical patent/CN116112831A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04QSELECTING
    • H04Q11/00Selecting arrangements for multiplex systems
    • H04Q11/0001Selecting arrangements for multiplex systems using optical switching
    • H04Q11/0005Switch and router aspects

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The disclosure relates to an optical network path determining method, an optical network path determining device and a storage medium. The optical network path determining method comprises the following steps: acquiring a starting point and a target point in an optical network node; based on an A star algorithm, a first path direction and a second path direction are respectively determined, wherein the first path direction is a searching direction from a starting point to a target point, and the second path direction is a searching direction from the target point to the starting point; in response to the first node having the same first path direction as the second path direction, determining the first node, and determining an optical network path passing through the start point, the first node, and the target point as a target path. According to the embodiment of the disclosure, when the optical path scheduling route search is performed, the starting point and the target point are searched in a two-way manner, so that the search efficiency is improved, the production efficiency is improved, and the cost is saved.

Description

光网络路径确定方法、光网络路径确定装置及存储介质Optical network path determination method, optical network path determination device and storage medium

技术领域technical field

本公开涉及通信资源管理技术领域,尤其涉及光网络路径确定方法、光网络路径确定装置及存储介质。The present disclosure relates to the technical field of communication resource management, and in particular to a method for determining an optical network path, a device for determining an optical network path, and a storage medium.

背景技术Background technique

随着科技的飞速发展,用户对网络速度和安全性的要求越来越高,光网络覆盖程度的提高、光网络复杂程度增加,其中的网络节点众多,随之而来的光路跳数越来越大。With the rapid development of science and technology, users have higher and higher requirements for network speed and security. The coverage of optical networks has increased, and the complexity of optical networks has increased. There are many network nodes, and the number of optical path hops is increasing. bigger.

在通信领域传输专业中,光路调度是一项重要的工作内容,光路调度过程中,需要对调度路由进行搜索,大跳数的光路使得光路调度中对调度路由的搜索深度加大,搜索耗时大幅增加,光路调度效率问题表现越来越突出,对于业务开通等应用场景均有不同程度的影响。如何提高路由搜索效率显得尤为重要。In the field of communication transmission, optical path scheduling is an important work content. In the process of optical path scheduling, it is necessary to search for scheduling routes. The optical path with a large number of hops increases the search depth of scheduling routes in optical path scheduling, and the search is time-consuming. With a substantial increase, the problem of optical path scheduling efficiency has become more and more prominent, which has varying degrees of impact on application scenarios such as service provisioning. How to improve the routing search efficiency is particularly important.

发明内容Contents of the invention

为克服相关技术中存在的问题,本公开提供光网络路径确定方法、光网络路径确定装置及存储介质。In order to overcome the problems existing in related technologies, the present disclosure provides a method for determining an optical network path, an apparatus for determining an optical network path, and a storage medium.

根据本公开实施例的第一方面,提供一种光网络路径确定方法,所述光网络路径确定方法包括:获取光网络节点中的起始点以及目标点;基于A星算法,分别确定第一路径方向以及第二路径方向,所述第一路径方向为从起始点至目标点进行搜索的搜索方向,所述第二路径方向为从目标点至起始点进行搜索的搜索方向;响应于所述第一路径方向与所述第二路径方向中存在相同的第一节点,确定所述第一节点,并将经过所述起始点、所述第一节点以及所述目标点的光网络路径确定为目标路径。According to the first aspect of an embodiment of the present disclosure, a method for determining an optical network path is provided, the method for determining an optical network path includes: obtaining a starting point and a target point in an optical network node; and determining the first path respectively based on the A star algorithm direction and a second path direction, the first path direction is a search direction for searching from a starting point to a target point, and the second path direction is a search direction for searching from a target point to a starting point; in response to the first There is the same first node in a path direction and the second path direction, determine the first node, and determine the optical network path passing through the starting point, the first node and the target point as the target path.

在一些实施例中,确定所述第一路径方向与所述第二路径方向中存在相同的第一节点,包括:分别基于所述第一路径方向以及所述第二路径方向进行同步搜索,确定所述同步搜索进行的搜索步数,并确定对应于当前搜索步数的所述第一路径方向的第一目标节点集合以及所述第二路径方向的第二目标节点集合;若所述第一目标节点集合与所述第二目标节点集合中存在坐标值相同的目标节点,将所述目标节点确定为第一节点。In some embodiments, determining that the same first node exists in the first path direction and the second path direction includes: performing a synchronous search based on the first path direction and the second path direction respectively, and determining The number of search steps performed by the synchronous search, and determining the first target node set in the first path direction and the second target node set in the second path direction corresponding to the current search step number; if the first A target node with the same coordinate value exists in the target node set and the second target node set, and the target node is determined as the first node.

在一些实施例中,确定对应于当前搜索步数的所述第一路径方向的第一目标节点集合以及所述第二路径方向的第二目标节点集合,包括:确定所述光网络节点的中间点,所述中间点为所述起始点与所述目标点之间几何连线的中点;确定对应于当前搜索步数的所述第一路径方向的第一起始点以及第三目标节点,并确定所述第二路径方向的第二起始点以及第四目标节点;将满足预设条件的所述第三目标节点添加至第一目标节点集合,并将满足预设条件的所述第四目标节点添加至第二目标节点集合,所述预设条件包括:起始点与目标节点之间的距离小于所述起始点与所述中间点之间的距离,且所述起始点、所述目标节点之间的连线与所述起始点、所述中间点之间的连线之间的夹角小于角度阈值。In some embodiments, determining the first set of target nodes corresponding to the current search step in the first path direction and the second set of target nodes in the second path direction includes: determining the middle of the optical network node point, the middle point is the middle point of the geometric connection between the starting point and the target point; determine the first starting point and the third target node corresponding to the first path direction of the current search step number, and Determining the second starting point and the fourth target node of the second path direction; adding the third target node satisfying the preset condition to the first target node set, and adding the fourth target node satisfying the preset condition The node is added to the second target node set, and the preset conditions include: the distance between the starting point and the target node is smaller than the distance between the starting point and the intermediate point, and the starting point, the target node The included angle between the connecting line between the starting point and the intermediate point is smaller than an angle threshold.

在一些实施例中,确定所述第一路径方向与所述第二路径方向中存在相同的第一节点,包括:响应于所述搜索步数小于或等于第一路由深度,所述第一目标节点集合与所述第二目标节点中坐标值相同的目标节点确定为第一节点,所述第一路由深度的数值为所述光网络路由深度数值的一半。In some embodiments, determining that the same first node exists in the first path direction and the second path direction includes: in response to the number of search steps being less than or equal to the first routing depth, the first target The target node whose coordinate value is the same as that of the second target node in the node set is determined as the first node, and the value of the first routing depth is half of the value of the routing depth of the optical network.

在一些实施例中,将经过所述起始点、所述第一节点以及所述目标点的光网络路径确定为目标路径,包括:将满足以下预设条件的经过所述起始点、所述第一节点以及所述目标点的光网络路径确定为目标路径,所述预设条件包括:所述目标路径的距离最短和/或所述目标路径中包括的中间节点最少。In some embodiments, determining the optical network path that passes through the starting point, the first node, and the target point as the target path includes: determining the path that passes through the starting point, the first node, and the first node that satisfies the following preset conditions A node and the optical network path of the target point are determined as the target path, and the preset conditions include: the target path has the shortest distance and/or the target path includes the least intermediate nodes.

根据本公开实施例的第二方面,提供一种光网络路径确定装置,其特征在于,所述光网络路径确定装置包括:获取单元,用于获取光网络节点中的起始点以及目标点;确定单元,用于基于A星算法,分别确定第一路径方向以及第二路径方向,所述第一路径方向为从起始点至目标点进行搜索的搜索方向,所述第二路径方向为从目标点至起始点进行搜索的搜索方向;以及,响应于所述第一路径方向与所述第二路径方向中存在相同的第一节点,确定所述第一节点,并将经过所述起始点、所述第一节点以及所述目标点的光网络路径确定为目标路径。According to the second aspect of the embodiments of the present disclosure, there is provided an optical network path determination device, characterized in that the optical network path determination device includes: an acquisition unit, configured to acquire a starting point and a target point in an optical network node; determine The unit is used to determine the first path direction and the second path direction respectively based on the A-star algorithm, the first path direction is the search direction from the starting point to the target point, and the second path direction is the search direction from the target point A search direction to the starting point for searching; and, in response to the same first node exists in the first path direction and the second path direction, determine the first node, and pass through the starting point, the The optical network path of the first node and the target point is determined as the target path.

在一些实施例中,所述确定单元采用如下方式确定所述第一路径方向与所述第二路径方向中存在相同的第一节点:分别基于所述第一路径方向以及所述第二路径方向进行同步搜索,确定所述同步搜索进行的搜索步数,并确定对应于当前搜索步数的所述第一路径方向的第一目标节点集合以及所述第二路径方向的第二目标节点集合;若所述第一目标节点集合与所述第二目标节点集合中存在坐标值相同的目标节点,将所述目标节点确定为第一节点。In some embodiments, the determination unit determines that the same first node exists in the first path direction and the second path direction in the following manner: based on the first path direction and the second path direction respectively performing a synchronous search, determining the number of search steps performed by the synchronous search, and determining a first target node set in the first path direction and a second target node set in the second path direction corresponding to the current search step; If there is a target node with the same coordinate value in the first target node set and the second target node set, determine the target node as the first node.

在一些实施例中,所述确定单元采用如下方式确定所述第一路径方向与所述第二路径方向中存在相同的第一节点:分别基于所述第一路径方向以及所述第二路径方向进行同步搜索,确定所述同步搜索进行的搜索步数,并确定对应于当前搜索步数的所述第一路径方向的第一目标节点集合以及所述第二路径方向的第二目标节点集合;若所述第一目标节点集合与所述第二目标节点集合中存在坐标值相同的目标节点,将所述目标节点确定为第一节点。In some embodiments, the determination unit determines that the same first node exists in the first path direction and the second path direction in the following manner: based on the first path direction and the second path direction respectively performing a synchronous search, determining the number of search steps performed by the synchronous search, and determining a first target node set in the first path direction and a second target node set in the second path direction corresponding to the current search step; If there is a target node with the same coordinate value in the first target node set and the second target node set, determine the target node as the first node.

在一些实施例中,所述确定单元采用如下方式确定所述第一路径方向与所述第二路径方向中存在相同的第一节点:响应于所述搜索步数小于或等于第一路由深度,所述第一目标节点集合与所述第二目标节点中坐标值相同的目标节点确定为第一节点,所述第一路由深度的数值为所述光网络路由深度数值的一半。In some embodiments, the determining unit determines that the same first node exists in the first path direction and the second path direction in the following manner: in response to the search step number being less than or equal to the first routing depth, A target node with the same coordinate value in the first target node set and the second target node is determined as the first node, and the value of the first routing depth is half of the value of the routing depth of the optical network.

在一些实施例中,所述确定单元采用如下方式将经过所述起始点、所述第一节点以及所述目标点的光网络路径确定为目标路径:将满足以下预设条件的经过所述起始点、所述第一节点以及所述目标点的光网络路径确定为目标路径,所述预设条件包括:所述目标路径的距离最短和/或所述目标路径中包括的中间节点最少。In some embodiments, the determination unit determines the optical network path that passes through the starting point, the first node, and the target point as the target path in the following manner: the path that passes through the starting point and satisfies the following preset conditions The optical network path of the starting point, the first node, and the target point is determined as the target path, and the preset conditions include: the target path has the shortest distance and/or the target path includes the least intermediate nodes.

根据本公开实施例的第三方面,提供一种光网络路径确定装置,包括:处理器;用于存储处理器可执行指令的存储器;其中,处理器被配置为:执行前述任意一项所述的光网络路径确定方法。According to a third aspect of an embodiment of the present disclosure, there is provided an optical network path determining device, including: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to: execute any one of the foregoing Optical network path determination method.

根据本公开实施例的第四方面,提供一种非临时性计算机可读存储介质,当存储介质中的指令由移动终端的处理器执行时,使得移动终端能够执行前述任意一项所述的光网络路径确定方法。According to the fourth aspect of the embodiments of the present disclosure, there is provided a non-transitory computer-readable storage medium. When the instructions in the storage medium are executed by the processor of the mobile terminal, the mobile terminal can execute the optical Network path determination method.

本公开的实施例提供的技术方案可以包括以下有益效果:在进行光路调度路由搜索时,获取光网络节点中的起始点以及目标点,并对起始点和目标点分别基于A星算法进行双向搜索,提高搜索效率,提高生产效率,节约成本。The technical solution provided by the embodiments of the present disclosure may include the following beneficial effects: when performing optical path scheduling routing search, obtain the starting point and target point in the optical network node, and perform two-way search on the starting point and target point based on the A-star algorithm respectively , Improve search efficiency, improve production efficiency, and save costs.

应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,并不能限制本公开。It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure.

附图说明Description of drawings

此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本公开的实施例,并与说明书一起用于解释本公开的原理。The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description serve to explain the principles of the disclosure.

图1是根据本公开一示例性实施例示出的一种光网络路径确定方法的流程图。Fig. 1 is a flowchart showing a method for determining an optical network path according to an exemplary embodiment of the present disclosure.

图2是根据本公开一示例性实施例示出的一种确定第一路径方向与第二路径方向中存在相同的第一节点方法的流程图。Fig. 2 is a flow chart showing a method for determining that the same first node exists in the first path direction and the second path direction according to an exemplary embodiment of the present disclosure.

图3是根据本公开一示例性实施例示出的一种确定对应于当前搜索步数的第一路径方向的第一目标节点集合以及第二路径方向的第二目标节点集合方法的流程图。Fig. 3 is a flowchart showing a method for determining a first target node set in a first path direction corresponding to a current search step and a second target node set in a second path direction according to an exemplary embodiment of the present disclosure.

图4是根据本公开一示例性实施例示出的一种光网络路径确定装置框图。Fig. 4 is a block diagram of an apparatus for determining an optical network path according to an exemplary embodiment of the present disclosure.

图5根据本公开一示例性实施例示出的一种用于光网络路径确定的装置的框图。Fig. 5 shows a block diagram of an apparatus for determining an optical network path according to an exemplary embodiment of the present disclosure.

具体实施方式Detailed ways

这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本公开相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本公开的一些方面相一致的装置和方法的例子。Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numerals in different drawings refer to the same or similar elements unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatuses and methods consistent with aspects of the present disclosure as recited in the appended claims.

伴随着家庭宽带业务的发展,迎来了新一波的网络基础资源建设高峰,光网络的复杂程度越来越高。随着网络复杂程度的增加,在一些业务场景下,光网络的光路跳数越来越大。With the development of home broadband services, a new wave of network infrastructure resource construction peaks are ushered in, and the complexity of optical networks is getting higher and higher. As the complexity of the network increases, in some service scenarios, the number of optical path hops in the optical network becomes larger and larger.

在通信领域传输专业中,光路调度是一项重要的工作内容,光路调度过程中,需要对调度路由进行搜索,对于大跳数的光路,光路调度路由搜索深度的加大,耗时大幅增加,光路调度效率问题表现越来越突出。光路调度效率低对于业务开通等应用场景具有相当程度的影响,如何提高路由搜索效率显得尤为重要。In the field of communication transmission, optical path scheduling is an important work content. In the process of optical path scheduling, it is necessary to search for scheduling routes. For optical paths with a large number of hops, the search depth of optical path scheduling routes is increased, and the time-consuming is greatly increased. The problem of optical path scheduling efficiency is becoming more and more prominent. The low efficiency of optical path scheduling has a considerable impact on application scenarios such as service provisioning. How to improve the efficiency of route search is particularly important.

路由搜索中,应用较多有Dijkstra算法、A星算法等,Dijkstra算法应用贪心算法模式,是较为常用求解最短路径的方法,用于确定有向图中单个节点到其它节点的最短路径问题,每次迭代时选择出的目标节点是当前节点外距离起始节点最近的节点。dijkstra算法计算从起始节点到其他所有节点的最短路径,算法效率较低。In routing search, there are many applications such as Dijkstra's algorithm and A-star algorithm. Dijkstra's algorithm uses the greedy algorithm mode, which is a relatively common method for solving the shortest path. It is used to determine the shortest path from a single node to other nodes in a directed graph. The target node selected in the first iteration is the node closest to the starting node outside the current node. The Dijkstra algorithm calculates the shortest path from the starting node to all other nodes, and the algorithm efficiency is low.

A星算法是静态路由路线规划的有效方法,遍历周围节点信息来找寻最短路径的,具有很好的稳定性。在Dijkstra基础上引入启发式函数h(n),h(n)表示当前节点到目标节点的成本。保证找到最短路径(最优解的)条件,关键在于(n)的选取,保证了最优性的同时,加入了目标节点的信息,提升搜索效率。The A-star algorithm is an effective method for static routing route planning. It traverses the surrounding node information to find the shortest path, and has good stability. The heuristic function h(n) is introduced on the basis of Dijkstra, and h(n) represents the cost from the current node to the target node. The key to ensure the condition of finding the shortest path (optimal solution) lies in the selection of (n), which ensures the optimality and at the same time adds the information of the target node to improve the search efficiency.

引入DijKstra算法后,对光路调度的时间效率有所提升,但随着光路调度需求的进一步,受业务开通等工作时效性要求,光路调度的效率需要进一步提高。对于大跳接数的光路调度,搜索时长的增加,造成调度工作的效率低下。After the introduction of the DijKstra algorithm, the time efficiency of optical path scheduling has been improved. However, with the further improvement of optical path scheduling requirements, the efficiency of optical path scheduling needs to be further improved due to the timeliness requirements such as service provisioning. For optical path scheduling with a large number of hops, the search time increases, resulting in low scheduling efficiency.

由此,本公开提供一种光网络路径确定方法,在进行光路调度路由搜索时,获取光网络节点中的起始点以及目标点,并对起始点和目标点分别基于A星算法进行双向搜索,提高搜索效率,提高生产效率,节约成本。Therefore, the present disclosure provides a method for determining an optical network path. When performing an optical path scheduling route search, the starting point and the target point in the optical network node are obtained, and the starting point and the target point are respectively searched in two directions based on the A-star algorithm. Improve search efficiency, improve production efficiency, and save costs.

图1是根据本公开一示例性实施例示出的一种光网络路径确定方法的流程图,如图1所示,光网络路径确定方法包括以下步骤。Fig. 1 is a flowchart showing a method for determining an optical network path according to an exemplary embodiment of the present disclosure. As shown in Fig. 1 , the method for determining an optical network path includes the following steps.

在步骤S101中,获取光网络节点中的起始点以及目标点。In step S101, a starting point and a target point in an optical network node are acquired.

在步骤S102中,基于A星算法,分别确定第一路径方向以及第二路径方向,第一路径方向为从起始点至目标点进行搜索的搜索方向,第二路径方向为从目标点至起始点进行搜索的搜索方向。In step S102, based on the A star algorithm, the first path direction and the second path direction are respectively determined, the first path direction is the search direction from the starting point to the target point, and the second path direction is from the target point to the starting point The search direction in which to search.

在步骤S103中,响应于第一路径方向与第二路径方向中存在相同的第一节点,确定第一节点,并将经过起始点、第一节点以及目标点的光网络路径确定为目标路径。In step S103, in response to the same first node exists in the first path direction and the second path direction, the first node is determined, and the optical network path passing through the starting point, the first node and the target point is determined as the target path.

在本公开实施例中,在进行光路调度路由搜索时,获取光网络节点中的起始点以及目标点,即路由搜索从起始点以及目标点同步向中间进行搜索。基于A星算法,分别确定第一路径方向以及第二路径方向,其中,第一路径方向为从起始点至目标点进行搜索的搜索方向,第二路径方向为从目标点至起始点进行搜索的搜索方向。基于第一路径方向以及第二路径方向进行路由的逐步搜索。在沿第一路径方向进行逐步搜索的过程中可以基于每步搜索得到当前步对应的目标节点的集合,同理,沿第二路径方向进行逐步搜索的过程中,也可以得到当前步对应的目标节点的集合。In the embodiment of the present disclosure, when performing optical path scheduling route search, the start point and target point in the optical network node are obtained, that is, the route search is searched from the start point and target point to the middle synchronously. Based on the A star algorithm, the first path direction and the second path direction are respectively determined, wherein the first path direction is the search direction from the starting point to the target point, and the second path direction is the search direction from the target point to the starting point Search direction. A step-by-step search for routes is performed based on the first path direction and the second path direction. In the process of step-by-step search along the first path direction, the set of target nodes corresponding to the current step can be obtained based on each step of search. Similarly, in the process of step-by-step search along the second path direction, the target node corresponding to the current step can also be obtained. A collection of nodes.

A星算法在DijKstra算法的基础上引入了启发式函数h(n),h(n)表示了当前节点到目标节点的成本,A星算法保证路由搜索最优性的同时,加入了目标节点的信息,提升了搜索效率。在本公开实施例中,可以是以列表、数组等方式存放第一路径方向以及第二路径方向分别对应得到的目标节点。如果第一路径方向与第二路径方向中存在相同的第一节点,确定第一节点,并将经过起始点、第一节点以及目标点的光网络路径确定为目标路径。The A-star algorithm introduces a heuristic function h(n) on the basis of the DijKstra algorithm. h(n) represents the cost from the current node to the target node. information, improving search efficiency. In the embodiment of the present disclosure, the target nodes respectively corresponding to the first path direction and the second path direction may be stored in a list, an array, or the like. If there is the same first node in the first path direction and the second path direction, determine the first node, and determine the optical network path passing through the starting point, the first node and the target point as the target path.

根据本公开实施例,在进行光路调度路由搜索时,获取光网络节点中的起始点以及目标点,并对起始点和目标点分别基于A星算法进行双向搜索,提高搜索效率,提高生产效率,节约成本。According to the embodiment of the present disclosure, when performing optical path scheduling routing search, the starting point and target point in the optical network node are obtained, and the starting point and target point are respectively searched in two directions based on the A-star algorithm to improve search efficiency and production efficiency. save costs.

图2是根据本公开一示例性实施例示出的一种确定第一路径方向与第二路径方向中存在相同的第一节点方法的流程图,如图2所示,该方法包括以下步骤。Fig. 2 is a flowchart showing a method for determining that the same first node exists in a first path direction and a second path direction according to an exemplary embodiment of the present disclosure. As shown in Fig. 2 , the method includes the following steps.

在步骤S201中,分别基于第一路径方向以及第二路径方向进行同步搜索,确定同步搜索进行的搜索步数,并确定对应于当前搜索步数的第一路径方向的第一目标节点集合以及第二路径方向的第二目标节点集合。In step S201, a synchronous search is performed based on the first path direction and the second path direction respectively, the number of search steps for the synchronous search is determined, and the first target node set and the first target node set corresponding to the current search step direction in the first path direction are determined. The second target node set for the two path directions.

在步骤S202中,若第一目标节点集合与第二目标节点集合中存在坐标值相同的目标节点,将目标节点确定为第一节点。In step S202, if there is a target node with the same coordinate value in the first target node set and the second target node set, the target node is determined as the first node.

在本公开实施例中,在进行光路调度路由搜索时,对起始点和目标点分别进行同步搜索。基于A星算法,分别确定从起始点至目标点进行搜索的第一路径方向,以及从目标点至起始点进行搜索的第二路径方向,基于第一路径方向以及第二路径方向进行路由的逐步搜索。在沿第一路径方向进行逐步搜索的过程中,确定当前方向进行搜索的步数,并确定当前搜索步数对应得到的目标节点的集合,同理,在沿第一路径方向进行逐步搜索的过程中,确定当前方向进行搜索的步数,并确定当前搜索步数对应得到的目标节点的集合。每次逐步搜索后,对应于相同的搜索步数,在第一路径方向对应的目标节点的集合以及第二路径方向对应的目标节点中,判断上述两个集合是否存在坐标值相同的节点,即,若坐标值相同时,则存在于第一路径方向对应的目标节点的集合以及存在于第一路径方向对应的目标节点的集合为相同节点,即第一节点。可以理解地,第一节点即为路由搜索的目标节点,经过目标节点的路径,即路由搜索得到的目标路径。若每次逐步搜索后,对应于相同的搜索步数,在第一路径方向对应的目标节点的集合以及第二路径方向对应的目标节点中不存在相同节点,则表明未找到目标路径。In the embodiment of the present disclosure, when performing optical path scheduling route search, synchronous search is performed on the starting point and the target point respectively. Based on the A star algorithm, respectively determine the first path direction for searching from the starting point to the target point, and the second path direction for searching from the target point to the starting point, and perform routing step by step based on the first path direction and the second path direction search. In the process of step by step search along the first path direction, determine the number of search steps in the current direction, and determine the set of target nodes corresponding to the current search step number, similarly, in the process of step by step search along the first path direction In , determine the number of steps to search in the current direction, and determine the set of target nodes corresponding to the current search steps. After each step-by-step search, corresponding to the same number of search steps, in the set of target nodes corresponding to the first path direction and the target node corresponding to the second path direction, it is judged whether there are nodes with the same coordinate value in the above two sets, namely , if the coordinate values are the same, the set of target nodes corresponding to the first path direction and the set of target nodes corresponding to the first path direction are the same node, that is, the first node. Understandably, the first node is the target node of the route search, and the path passing through the target node is the target path obtained by the route search. If after each stepwise search, corresponding to the same number of search steps, the same node does not exist in the set of target nodes corresponding to the first path direction and the target node corresponding to the second path direction, it indicates that the target path is not found.

根据本公开实施例,在进行光路调度路由搜索时,获取光网络节点中的起始点以及目标点,并对起始点和目标点分别基于A星算法进行双向搜索,提高搜索效率,提高生产效率,节约成本。According to the embodiment of the present disclosure, when performing optical path scheduling routing search, the starting point and target point in the optical network node are obtained, and the starting point and target point are respectively searched in two directions based on the A-star algorithm to improve search efficiency and production efficiency. save costs.

图3是根据本公开一示例性实施例示出的一种确定对应于当前搜索步数的第一路径方向的第一目标节点集合以及第二路径方向的第二目标节点集合方法的流程图,如图3所示,该方法包括以下步骤。Fig. 3 is a flow chart showing a method for determining a first target node set corresponding to a first path direction of a current search step and a second target node set of a second path direction according to an exemplary embodiment of the present disclosure, as shown in FIG. As shown in Fig. 3, the method includes the following steps.

在步骤S301中,确定光网络节点的中间点,中间点为起始点与目标点之间几何连线的中点。In step S301, the middle point of the optical network node is determined, and the middle point is the middle point of the geometric connection line between the starting point and the target point.

在步骤S302中,确定对应于当前搜索步数的第一路径方向的第一起始点以及第三目标节点,并确定第二路径方向的第二起始点以及第四目标节点。In step S302, the first starting point and the third target node of the first path direction corresponding to the current search steps are determined, and the second starting point and the fourth target node of the second path direction are determined.

在步骤S303中,将满足预设条件的第三目标节点添加至第一目标节点集合,并将满足预设条件的第四目标节点添加至第二目标节点集合。In step S303, the third target node meeting the preset condition is added to the first target node set, and the fourth target node meeting the preset condition is added to the second target node set.

在本公开实施例中,预设条件为起始点与目标节点之间的距离小于起始点与中间点之间的距离,且起始点、目标节点之间的连线与起始点、中间点之间的连线之间的夹角小于角度阈值。In the embodiment of the present disclosure, the preset condition is that the distance between the starting point and the target node is smaller than the distance between the starting point and the intermediate point, and the connection line between the starting point and the target node and the distance between the starting point and the intermediate point The angle between the lines of is less than the angle threshold.

在本公开实施例中,在光路路由的搜索中,基于A星算法进行双向搜索,相对于每半程搜索采用Dijkstra搜索算法,能够有效提高搜索效率。光路的路由在空间上通常是由一端向另一端延伸,其中,即使部分物理路由方向不同,但总体方向的趋势相同。可以是利用管线系统的地理信息系统(Geographic Information System,GIS)信息,为A星算法提供支持。光路路由的搜索中,由起始点出发进行搜索时,对搜索中的过程节点基于GIS信息进行判断,以确定A星算法中的启发式函数h(n)。In the embodiment of the present disclosure, in the search of the optical path routing, the two-way search is performed based on the A-star algorithm, and the Dijkstra search algorithm is used for each half-way search, which can effectively improve the search efficiency. The routing of the optical path usually extends from one end to the other in space, wherein, even if some physical routing directions are different, the trend of the overall direction is the same. It may be to use the geographic information system (Geographic Information System, GIS) information of the pipeline system to provide support for the A-star algorithm. In the search of optical path routing, when searching from the starting point, the process nodes in the search are judged based on GIS information to determine the heuristic function h(n) in the A-star algorithm.

在本公开实施例中,确定光网络节点的中间点,中间点为起始点与目标点之间几何连线的中点,基于A星算法,在进行光路调度路由搜索时,对起始点和目标点分别进行同步搜索。从起始点至目标点进行搜索的第一路径方向中,确定对应于当前搜索步数第一起始点以及第三目标节点,第一起始点与第三目标节点之间的相对距离以及角度,需满足预设条件,即确定第一起始点与第三目标节点之间的距离,并确定第一起始点与中间点之间的距离,判断第一起始点与第三目标节点之间的距离是否小于第一起始点与中间点之间的距离。并且,连接第一起始点与第三目标节点得到第一线段,并连接第一起始点与中间点得到第二线段,确定第一线段与第二线段之间的夹角角度。当第一起始点与第三目标节点之间的距离小于第一起始点与中间点之间的距离,且第一线段与第二线段之间的夹角角度小于预设角度时,认为该第三目标节点为更加靠近中间点的节点,此时该第三目标节点为对应于该搜索步骤的相对优解,对应于A星算法中的启发式函数h(n)的取值,赋予较大权重值,将满足预设条件的第三目标节点添加至第一目标节点集合。可以理解地,对于从目标点至起始点进行搜索的第二路径方向中,第二目标节点集合的确定方法与上述步骤相同,在此不再赘述。In the embodiment of the present disclosure, the intermediate point of the optical network node is determined. The intermediate point is the midpoint of the geometric connection between the starting point and the target point. Click to search for synchronization separately. In the first path direction of the search from the starting point to the target point, determine the first starting point and the third target node corresponding to the current search steps, the relative distance and angle between the first starting point and the third target node, which need to meet the predetermined Set the condition, that is, determine the distance between the first starting point and the third target node, and determine the distance between the first starting point and the intermediate point, and judge whether the distance between the first starting point and the third target node is smaller than the first starting point and the The distance between the intermediate points. And, connect the first starting point and the third target node to obtain a first line segment, and connect the first starting point and the middle point to obtain a second line segment, and determine the included angle between the first line segment and the second line segment. When the distance between the first starting point and the third target node is smaller than the distance between the first starting point and the intermediate point, and the angle between the first line segment and the second line segment is smaller than the preset angle, it is considered that the third The target node is a node closer to the middle point. At this time, the third target node is a relatively optimal solution corresponding to the search step, corresponding to the value of the heuristic function h(n) in the A star algorithm, and given a larger weight value, adding the third target node meeting the preset condition to the first target node set. It can be understood that, for the second path direction searched from the target point to the starting point, the method for determining the second target node set is the same as the above steps, and will not be repeated here.

根据本公开实施例,在进行光路调度路由搜索时,获取光网络节点中的起始点以及目标点,并对起始点和目标点分别基于A星算法进行双向搜索,提高搜索效率,提高生产效率,节约成本。According to the embodiment of the present disclosure, when performing optical path scheduling routing search, the starting point and target point in the optical network node are obtained, and the starting point and target point are respectively searched in two directions based on the A-star algorithm to improve search efficiency and production efficiency. save costs.

在一些实施例中,响应于搜索步数小于或等于第一路由深度,将第一目标节点集合与第二目标节点中坐标值相同的目标节点确定为第一节点。In some embodiments, in response to the number of search steps being less than or equal to the first routing depth, a target node with the same coordinate value in the first target node set and the second target node is determined as the first node.

在本公开实施例中,在进行光路调度路由搜索时,对起始点和目标点分别进行同步搜索,搜索深度可以是预设的路由深度,可以理解地,对起始点和目标点分别进行的双向搜索的路由深度为从单一方向进行搜索时的光网络路由深度数值的一半。每次逐步搜索后,对应于相同的搜索步数,在第一路径方向对应的目标节点的集合以及第二路径方向对应的目标节点中,判断上述两个节点集合是否存在坐标值相同的节点,且当前的搜索步数不超过第一路由深度。例如,光网络路由深度数值为6,在对起始点和目标点分别进行双向搜索时,深度数值为6的一半,也即3。在第一步、第二步与第三步搜索后,判断第一路径方向搜索得到的目标节点的集合以及第二路径方向搜索得到的目标节点中,是否存在相同的节目标点,若存在,将该目标节点确定为第一节点,即路由搜索的目标节点。若在第三步搜索后,仍不存在相同的节目标点,搜索失败。In the embodiment of the present disclosure, when performing optical path scheduling routing search, the starting point and the target point are respectively searched synchronously, and the search depth can be a preset routing depth. Understandably, the two-way search for the starting point and the target point The routing depth of the search is half of the value of the optical network routing depth when searching from a single direction. After each step-by-step search, corresponding to the same number of search steps, in the set of target nodes corresponding to the first path direction and the target node corresponding to the second path direction, it is judged whether there are nodes with the same coordinate values in the above two node sets, And the current number of search steps does not exceed the first routing depth. For example, the optical network routing depth value is 6, and the depth value is half of 6, that is, 3, when the two-way search is performed on the starting point and the target point respectively. After searching in the first step, the second step and the third step, judge whether there is the same node in the set of target nodes searched in the first path direction and in the target nodes searched in the second path direction, and if so, set The target node is determined as the first node, that is, the target node of the routing search. If the same program point still does not exist after the third step of searching, the search fails.

在一些实施例中,在确定目标路径时,可以是选取经过起始点、第一节点以及目标点的光网络路径中距离最短的路径为目标路径,减少光网络中由起始点至目标点之间的传播距离。In some embodiments, when determining the target path, the path with the shortest distance among the optical network paths passing through the starting point, the first node and the target point may be selected as the target path, so as to reduce the distance between the starting point and the target point in the optical network. the propagation distance.

在一些实施例中,在确定目标路径时,还可以是选取经过起始点、第一节点以及目标点的光网络路径中包括的中间节点最少的路径为目标路径,减少光网络中由起始点至目标点之间的节点数量,以减少经过节点造成的时间浪费。In some embodiments, when determining the target path, it is also possible to select the path that includes the least intermediate nodes in the optical network path passing through the starting point, the first node and the target point as the target path, reducing the number of nodes from the starting point to the target point in the optical network. The number of nodes between the target points to reduce the time waste caused by passing nodes.

基于相同的构思,本公开实施例还提供一种光网络路径确定装置。Based on the same idea, an embodiment of the present disclosure further provides an optical network path determination device.

可以理解的是,本公开实施例提供的装置为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。结合本公开实施例中所公开的各示例的单元及算法步骤,本公开实施例能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。本领域技术人员可以对每个特定的应用来使用不同的方法来实现所描述的功能,但是这种实现不应认为超出本公开实施例的技术方案的范围。It can be understood that, in order to realize the above-mentioned functions, the apparatus provided by the embodiments of the present disclosure includes corresponding hardware structures and/or software modules for performing various functions. Combining the units and algorithm steps of each example disclosed in the embodiments of the present disclosure, the embodiments of the present disclosure can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software drives hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the technical solutions of the embodiments of the present disclosure.

图4是根据本公开一示例性实施例示出的一种光网络路径确定装置框图。参照图4,光网络路径确定装置100包括:获取单元101和确定单元102。Fig. 4 is a block diagram of an apparatus for determining an optical network path according to an exemplary embodiment of the present disclosure. Referring to FIG. 4 , the apparatus 100 for determining an optical network path includes: an acquiring unit 101 and a determining unit 102 .

获取单元101,用于获取光网络节点中的起始点以及目标点。The obtaining unit 101 is configured to obtain a starting point and a target point in an optical network node.

确定单元102,用于基于A星算法,分别确定第一路径方向以及第二路径方向,第一路径方向为从起始点至目标点进行搜索的搜索方向,第二路径方向为从目标点至起始点进行搜索的搜索方向;以及,响应于第一路径方向与第二路径方向中存在相同的第一节点,确定第一节点,并将经过起始点、第一节点以及目标点的光网络路径确定为目标路径。The determining unit 102 is configured to determine a first path direction and a second path direction based on the A star algorithm, the first path direction is a search direction from the starting point to the target point, and the second path direction is from the target point to the starting point. and, in response to the presence of the same first node in the first path direction and the second path direction, determine the first node, and determine the optical network path passing through the starting point, the first node, and the target point is the target path.

在一些实施例中,确定单元102采用如下方式确定第一路径方向与第二路径方向中存在相同的第一节点:In some embodiments, the determining unit 102 determines that the same first node exists in the first path direction and the second path direction in the following manner:

分别基于第一路径方向以及第二路径方向进行同步搜索,确定同步搜索进行的搜索步数,并确定对应于当前搜索步数的第一路径方向的第一目标节点集合以及第二路径方向的第二目标节点集合;Perform synchronous search based on the first path direction and the second path direction respectively, determine the number of search steps for the synchronous search, and determine the first target node set in the first path direction corresponding to the current search steps and the first target node set in the second path direction Two target node sets;

若第一目标节点集合与第二目标节点集合中存在坐标值相同的目标节点,将目标节点确定为第一节点。If there is a target node with the same coordinate value in the first target node set and the second target node set, the target node is determined as the first node.

在一些实施例中,确定单元102采用如下方式确定第一路径方向与第二路径方向中存在相同的第一节点:In some embodiments, the determining unit 102 determines that the same first node exists in the first path direction and the second path direction in the following manner:

分别基于第一路径方向以及第二路径方向进行同步搜索,确定同步搜索进行的搜索步数,并确定对应于当前搜索步数的第一路径方向的第一目标节点集合以及第二路径方向的第二目标节点集合;Perform synchronous search based on the first path direction and the second path direction respectively, determine the number of search steps for the synchronous search, and determine the first target node set in the first path direction corresponding to the current search steps and the first target node set in the second path direction Two target node sets;

若第一目标节点集合与第二目标节点集合中存在坐标值相同的目标节点,将目标节点确定为第一节点。If there is a target node with the same coordinate value in the first target node set and the second target node set, the target node is determined as the first node.

在一些实施例中,确定单元102采用如下方式确定第一路径方向与第二路径方向中存在相同的第一节点:In some embodiments, the determining unit 102 determines that the same first node exists in the first path direction and the second path direction in the following manner:

响应于搜索步数小于或等于第一路由深度,第一目标节点集合与第二目标节点中坐标值相同的目标节点确定为第一节点,第一路由深度的数值为从单一方向进行搜索时的光网络路由深度数值的一半。In response to the number of search steps being less than or equal to the first routing depth, the target node with the same coordinate value in the first target node set and the second target node is determined as the first node, and the value of the first routing depth is when searching from a single direction Half of the optical network routing depth value.

在一些实施例中,确定单元102采用如下方式将经过起始点、第一节点以及目标点的光网络路径确定为目标路径:In some embodiments, the determining unit 102 determines the optical network path passing through the starting point, the first node, and the target point as the target path in the following manner:

将满足以下预设条件的经过起始点、第一节点以及目标点的光网络路径确定为目标路径,预设条件包括:The optical network path passing through the starting point, the first node, and the target point that satisfies the following preset conditions is determined as the target path, and the preset conditions include:

目标路径的距离最短和/或目标路径中包括的中间节点最少。The target path has the shortest distance and/or includes the fewest intermediate nodes in the target path.

关于上述实施例中的装置,其中各个模块执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。Regarding the apparatus in the foregoing embodiments, the specific manner in which each module executes operations has been described in detail in the embodiments related to the method, and will not be described in detail here.

图5是根据本公开一示例性实施例示出的一种用于光网络路径确定的装置200的框图。例如,装置200可以是移动电话,计算机,数字广播终端,消息收发设备,游戏控制台,平板设备,医疗设备,健身设备,个人数字助理等。Fig. 5 is a block diagram of an apparatus 200 for determining an optical network path according to an exemplary embodiment of the present disclosure. For example, the apparatus 200 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, and the like.

参照图5,装置200可以包括以下一个或多个组件:处理组件202,存储器204,电力组件206,多媒体组件208,音频组件210,输入/输出(I/O)的接口212,传感器组件214,以及通信组件216。Referring to FIG. 5, the device 200 may include one or more of the following components: a processing component 202, a memory 204, a power component 206, a multimedia component 208, an audio component 210, an input/output (I/O) interface 212, a sensor component 214, and communication component 216 .

处理组件202通常控制装置200的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件202可以包括一个或多个处理器220来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件202可以包括一个或多个模块,便于处理组件202和其他组件之间的交互。例如,处理组件202可以包括多媒体模块,以方便多媒体组件208和处理组件202之间的交互。The processing component 202 generally controls the overall operations of the device 200, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 202 may include one or more processors 220 to execute instructions to complete all or part of the steps of the above method. Additionally, processing component 202 may include one or more modules that facilitate interaction between processing component 202 and other components. For example, processing component 202 may include a multimedia module to facilitate interaction between multimedia component 208 and processing component 202 .

存储器204被配置为存储各种类型的数据以支持在装置200的操作。这些数据的示例包括用于在装置200上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器204可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。The memory 204 is configured to store various types of data to support operations at the device 200 . Examples of such data include instructions for any application or method operating on device 200, contact data, phonebook data, messages, pictures, videos, and the like. The memory 204 can be implemented by any type of volatile or non-volatile storage device or their combination, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, Flash Memory, Magnetic or Optical Disk.

电力组件206为装置200的各种组件提供电力。电力组件206可以包括电源管理系统,一个或多个电源,及其他与为装置200生成、管理和分配电力相关联的组件。The power component 206 provides power to various components of the device 200 . Power components 206 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for device 200 .

多媒体组件208包括在所述装置200和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件208包括一个前置摄像头和/或后置摄像头。当装置200处于操作模式,如拍摄模式或视频模式时,前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜系统或具有焦距和光学变焦能力。The multimedia component 208 includes a screen that provides an output interface between the device 200 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may not only sense a boundary of a touch or swipe action, but also detect duration and pressure associated with the touch or swipe action. In some embodiments, the multimedia component 208 includes a front camera and/or a rear camera. When the device 200 is in an operation mode, such as a shooting mode or a video mode, the front camera and/or the rear camera can receive external multimedia data. Each front camera and rear camera can be a fixed optical lens system or have focal length and optical zoom capability.

音频组件210被配置为输出和/或输入音频信号。例如,音频组件210包括一个麦克风(MIC),当装置200处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器204或经由通信组件216发送。在一些实施例中,音频组件210还包括一个扬声器,用于输出音频信号。The audio component 210 is configured to output and/or input audio signals. For example, the audio component 210 includes a microphone (MIC), which is configured to receive external audio signals when the device 200 is in operation modes, such as call mode, recording mode and voice recognition mode. Received audio signals may be further stored in memory 204 or sent via communication component 216 . In some embodiments, the audio component 210 also includes a speaker for outputting audio signals.

I/O接口212为处理组件202和外围接口模块之间提供接口,上述外围接口模块可以是键盘,点击轮,按钮等。这些按钮可包括但不限于:主页按钮、音量按钮、启动按钮和锁定按钮。The I/O interface 212 provides an interface between the processing component 202 and a peripheral interface module, which may be a keyboard, a click wheel, a button, and the like. These buttons may include, but are not limited to: a home button, volume buttons, start button, and lock button.

传感器组件214包括一个或多个传感器,用于为装置200提供各个方面的状态评估。例如,传感器组件214可以检测到装置200的打开/关闭状态,组件的相对定位,例如所述组件为装置200的显示器和小键盘,传感器组件214还可以检测装置200或装置200一个组件的位置改变,用户与装置200接触的存在或不存在,装置200方位或加速/减速和装置200的温度变化。传感器组件214可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件214还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件214还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。Sensor assembly 214 includes one or more sensors for providing various aspects of status assessment for device 200 . For example, the sensor component 214 can detect the open/closed state of the device 200, the relative positioning of components, such as the display and keypad of the device 200, and the sensor component 214 can also detect a change in the position of the device 200 or a component of the device 200 , the presence or absence of user contact with the device 200 , the device 200 orientation or acceleration/deceleration and the temperature change of the device 200 . The sensor assembly 214 may include a proximity sensor configured to detect the presence of nearby objects in the absence of any physical contact. Sensor assembly 214 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor component 214 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor or a temperature sensor.

通信组件216被配置为便于装置200和其他设备之间有线或无线方式的通信。装置200可以接入基于通信标准的无线网络,如WiFi,2G或3G,或它们的组合。在一个示例性实施例中,通信组件216经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件216还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。The communication component 216 is configured to facilitate wired or wireless communication between the apparatus 200 and other devices. The device 200 can access wireless networks based on communication standards, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 216 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 216 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

在示例性实施例中,装置200可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述方法。In an exemplary embodiment, apparatus 200 may be programmed by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable A gate array (FPGA), controller, microcontroller, microprocessor or other electronic component implementation for performing the methods described above.

在示例性实施例中,还提供了一种包括指令的非临时性计算机可读存储介质,例如包括指令的存储器204,上述指令可由装置200的处理器220执行以完成上述方法。例如,所述非临时性计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。In an exemplary embodiment, there is also provided a non-transitory computer-readable storage medium including instructions, such as the memory 204 including instructions, which can be executed by the processor 220 of the device 200 to implement the above method. For example, the non-transitory computer readable storage medium may be ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, and the like.

可以理解的是,本公开中“多个”是指两个或两个以上,其它量词与之类似。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。字符“/”一般表示前后关联对象是一种“或”的关系。单数形式的“一种”、“所述”和“该”也旨在包括多数形式,除非上下文清楚地表示其他含义。It can be understood that "plurality" in the present disclosure refers to two or more, and other quantifiers are similar. "And/or" describes the association relationship of associated objects, indicating that there may be three types of relationships, for example, A and/or B may indicate: A exists alone, A and B exist simultaneously, and B exists independently. The character "/" generally indicates that the contextual objects are an "or" relationship. The singular forms "a", "said" and "the" are also intended to include the plural unless the context clearly dictates otherwise.

进一步可以理解的是,术语“第一”、“第二”等用于描述各种信息,但这些信息不应限于这些术语。这些术语仅用来将同一类型的信息彼此区分开,并不表示特定的顺序或者重要程度。实际上,“第一”、“第二”等表述完全可以互换使用。例如,在不脱离本公开范围的情况下,第一信息也可以被称为第二信息,类似地,第二信息也可以被称为第一信息。It can be further understood that the terms "first", "second", etc. are used to describe various information, but the information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another, and do not imply a specific order or degree of importance. In fact, expressions such as "first" and "second" can be used interchangeably. For example, without departing from the scope of the present disclosure, first information may also be called second information, and similarly, second information may also be called first information.

进一步可以理解的是,除非有特殊说明,“连接”包括两者之间不存在其他构件的直接连接,也包括两者之间存在其他元件的间接连接。It can be further understood that, unless otherwise specified, "connection" includes a direct connection without other components between the two, and also includes an indirect connection between the two with other elements.

进一步可以理解的是,本公开实施例中尽管在附图中以特定的顺序描述操作,但是不应将其理解为要求按照所示的特定顺序或是串行顺序来执行这些操作,或是要求执行全部所示的操作以得到期望的结果。在特定环境中,多任务和并行处理可能是有利的。It can be further understood that although operations are described in a specific order in the drawings in the embodiments of the present disclosure, it should not be understood as requiring that these operations be performed in the specific order shown or in a serial order, or that Do all of the operations shown to get the desired result. In certain circumstances, multitasking and parallel processing may be advantageous.

本领域技术人员在考虑说明书及实践这里公开的公开后,将容易想到本公开的其它实施方案。本申请旨在涵盖本公开的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本公开的一般性原理并包括本公开未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本公开的真正范围和精神由下面的权利范围指出。Other embodiments of the disclosure will be readily apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any modification, use or adaptation of the present disclosure, and these modifications, uses or adaptations follow the general principles of the present disclosure and include common knowledge or conventional technical means in the technical field not disclosed in the present disclosure . The specification and examples are to be considered as illustrative only, with the true scope and spirit of the disclosure indicated by the following claims.

应当理解的是,本公开并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本公开的范围仅由所附的权利范围来限制。It should be understood that the present disclosure is not limited to the precise constructions which have been described above and shown in the drawings, and various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the scope of the appended claims.

Claims (12)

1. A method for determining an optical network path, the method comprising:
acquiring a starting point and a target point in an optical network node;
based on an A star algorithm, a first path direction and a second path direction are respectively determined, wherein the first path direction is a searching direction from a starting point to a target point, and the second path direction is a searching direction from the target point to the starting point;
in response to the first node having the same first path direction as the second path direction, determining the first node, and determining an optical network path passing through the start point, the first node, and the target point as a target path.
2. The method of determining an optical network path according to claim 1, wherein determining that the first node exists in the first path direction and the second path direction, comprises:
performing synchronous search based on the first path direction and the second path direction respectively, determining the search step number of the synchronous search, and determining a first target node set corresponding to the first path direction and a second target node set corresponding to the second path direction of the current search step number;
and if the first target node set and the second target node set have the target nodes with the same coordinate values, determining the target nodes as first nodes.
3. The optical network path determination method according to claim 2, wherein determining a first set of target nodes for the first path direction and a second set of target nodes for the second path direction corresponding to a current number of search steps comprises:
determining an intermediate point of the optical network node, wherein the intermediate point is a midpoint of a geometric connection line between the starting point and the target point;
determining a first starting point and a third target node of the first path direction corresponding to the current search step number, and determining a second starting point and a fourth target node of the second path direction;
adding the third target node meeting preset conditions to a first target node set, and adding the fourth target node meeting preset conditions to a second target node set, wherein the preset conditions comprise:
the distance between the starting point and the target node is smaller than the distance between the starting point and the middle point, and the included angle between the connecting line between the starting point and the target node and the connecting line between the starting point and the middle point is smaller than an angle threshold.
4. The method of determining an optical network path according to claim 2, wherein determining that the first node exists in the first path direction and the second path direction, comprises:
and determining the target node with the same coordinate value in the first target node set and the second target node as a first node in response to the search step number being smaller than or equal to a first routing depth, wherein the value of the first routing depth is half of that of the optical network routing depth.
5. The optical network path determining method according to claim 2, wherein determining an optical network path passing through the start point, the first node, and the target point as a target path includes:
determining an optical network path passing through the starting point, the first node and the target point satisfying the following preset conditions as a target path, wherein the preset conditions comprise:
the distance of the target path is the shortest and/or the intermediate nodes comprised in the target path are the smallest.
6. An optical network path determining apparatus, the apparatus comprising:
an obtaining unit, configured to obtain a start point and a target point in an optical network node;
the determining unit is used for respectively determining a first path direction and a second path direction based on an A star algorithm, wherein the first path direction is a searching direction from a starting point to a target point, and the second path direction is a searching direction from the target point to the starting point; and determining the first node in response to the first node having the same first path direction as the second path direction, and determining an optical network path passing through the start point, the first node, and the target point as a target path.
7. The optical network path determining apparatus according to claim 6, wherein the determining unit determines that the first node exists in the first path direction and the second path direction in the following manner:
performing synchronous search based on the first path direction and the second path direction respectively, determining the search step number of the synchronous search, and determining a first target node set corresponding to the first path direction and a second target node set corresponding to the second path direction of the current search step number;
and if the first target node set and the second target node set have the target nodes with the same coordinate values, determining the target nodes as first nodes.
8. The optical network path determining apparatus according to claim 7, wherein the determining unit determines the first set of target nodes in the first path direction and the second set of target nodes in the second path direction corresponding to the current number of search steps by:
determining an intermediate point of the optical network node, wherein the intermediate point is a midpoint of a geometric connection line between the starting point and the target point;
determining a first starting point and a third target node of the first path direction corresponding to the current search step number, and determining a second starting point and a fourth target node of the second path direction;
adding the third target node meeting preset conditions to a first target node set, and adding the fourth target node meeting preset conditions to a second target node set, wherein the preset conditions comprise:
the distance between the starting point and the target node is smaller than the distance between the starting point and the middle point, and the included angle between the connecting line between the starting point and the target node and the connecting line between the starting point and the middle point is smaller than an angle threshold.
9. The optical network path determining apparatus according to claim 7, wherein the determining unit determines that the first node exists in the first path direction and the second path direction in the following manner:
and in response to the search step number being smaller than or equal to a first routing depth, determining the first node as the target node, wherein the coordinate value of the target node in the first target node set and the coordinate value in the second target node are the same, and the value of the first routing depth is half of that of the optical network routing depth.
10. The optical network path determining apparatus according to claim 7, wherein the determining unit determines the optical network path passing through the start point, the first node, and the target point as a target path by:
determining an optical network path passing through the starting point, the first node and the target point satisfying the following preset conditions as a target path, wherein the preset conditions comprise:
the distance of the target path is the shortest and/or the intermediate nodes comprised in the target path are the smallest.
11. An optical network path determining apparatus, comprising:
a processor;
a memory for storing processor-executable instructions;
wherein the processor is configured to: an optical network path determining method according to any one of claims 1 to 5.
12. A storage medium having instructions stored therein which, when executed by a processor of a terminal, enable the terminal to perform the optical network path determination method of any one of claims 1 to 5.
CN202111328151.6A 2021-11-10 2021-11-10 Optical network path determination method, optical network path determination device, and storage medium Pending CN116112831A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111328151.6A CN116112831A (en) 2021-11-10 2021-11-10 Optical network path determination method, optical network path determination device, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111328151.6A CN116112831A (en) 2021-11-10 2021-11-10 Optical network path determination method, optical network path determination device, and storage medium

Publications (1)

Publication Number Publication Date
CN116112831A true CN116112831A (en) 2023-05-12

Family

ID=86264275

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111328151.6A Pending CN116112831A (en) 2021-11-10 2021-11-10 Optical network path determination method, optical network path determination device, and storage medium

Country Status (1)

Country Link
CN (1) CN116112831A (en)

Similar Documents

Publication Publication Date Title
WO2021248371A1 (en) Access method, access apparatus, and storage medium
KR101678038B1 (en) Method, apparatus, program, and recording medium for automatically connecting wireless network
CN108401526A (en) Information configuring methods and device, the determination method and device of time-frequency location and base station
WO2019084879A1 (en) Method and device for searching for common resource set of remaining mission-critical system information
CN106454998B (en) Wireless local area network access method, device and terminal
CN106376057A (en) Wireless network access method and device
CN113439472B (en) Physical downlink control channel monitoring method, device and storage medium
CN106231559A (en) Network access method, device and terminal
JP2023532565A (en) Cell determination method and cell determination device
CN105407160B (en) Interface display method and device
KR101638726B1 (en) Method, apparatus, program and recording medium for determining position
CN114745736A (en) Meta-universe service processing method and device, electronic equipment and storage medium
WO2018214169A1 (en) Mobility measurement method and device, and computer readable storage medium
KR102436552B1 (en) Cell type indication method, apparatus and computer readable storage medium
CN114402666B (en) Processing capability request, processing capability sending and processing capability receiving methods and devices
WO2019174046A1 (en) Method and apparatus for indicating and searching for position of synchronous broadcast block of defined cell, and base station
KR102568810B1 (en) How to build a super network, how to use it, device and storage medium
WO2020258263A1 (en) Cell reselection method and device, and storage medium
CN115843430A (en) Relay communication method, device and storage medium
CN104881342A (en) Terminal testing method and device
CN113395745B (en) Method, device, terminal and storage medium for accessing Mesh network
CN116112831A (en) Optical network path determination method, optical network path determination device, and storage medium
WO2021035894A1 (en) Sub-network sampling method, and method and device for constructing super-network topological structure
CN106850556A (en) service access method, device and equipment
EP3239856B1 (en) Information acquisition method, device and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20230512