Abstract:
The invention relates to a method for compiling a source code to a program code, the method comprising: providing a pattern graph based on the source code, the pattern graph corresponding to an intermediate representation of the source code according to a set of rules in a first programming language, wherein the set of rules comprises a specific replacement rule directing a pattern graph to be replaced by a corresponding replacement graph assigned to the pattern graph, replacing the pattern graph by the replacement graph assigned to the pattern graph, and generating the program code based on the replacement graph.
Abstract:
Embodiments of the present invention disclose a method, an apparatus and a system for joint optimization. The method for joint optimization includes: decomposing the joint optimization of an entire network into the joint optimization performed in each sub-network, regarding a bandwidth requirement for a server off the sub-network as a bandwidth requirement for a virtual server on a port, iteratively performing the joint optimization in each sub-network, and applying results of the joint optimization in the network. In the embodiments of the present invention, the bandwidth requirement for the server off the sub-network is regarded as the bandwidth requirement for the virtual server on the port, the joint optimization is iteratively performed in each sub-network, and the results of the joint optimization are applied in the network, so that the joint optimization of the entire network is performed in parallel.
Abstract:
Embodiments of the present invention relate to the field of computer technologies, and provide a search method and apparatus to resolve a problem that a reference text, of a text in a professional field, that is determined by using the prior art has relatively low accuracy. The method includes: obtaining n named entities in a current to-be-analyzed target case (S300); determining a first characteristic and a second characteristic (S301); generating, based on the first characteristic and the second characteristic and according to a preset vector generation rule, a target characteristic vector corresponding to the target case (S302); obtaining each historical case in a database and a characteristic vector corresponding to each historical case (S303); and separately calculating a similarity between the target characteristic vector and the characteristic vector corresponding to each historical case, and selecting a historical case whose similarity result meets a preset condition as a reference case (S304).
Abstract:
A method for garbage collection of a volume in a log-structured file system is disclosed. The volume comprises a plurality of segments. Each of the segments comprises a plurality of blocks. An invalid block count of each of the segments is determined. The invalid block count is used as an index for ordering the segments in a garbage collection queue. A plurality of range areas are determined for the index. A migration rate of each range area is determined, and the migration rate of a given range area reflects an intensity of segment migration into/out of the given range area. A negative migration rate reflects a segment migration into the given range area. Garbage collection is performed based upon the migration rate.
Abstract:
Examples of data processing methods and apparatus are described. One example method includes determining first pose information of a vehicle at a second moment based on pose information of the vehicle at a first moment and a first model, where the first model is a pose estimation model from the first moment to the second moment. Data collected by one or more sensors is obtained. Second pose information of the vehicle at the second moment is determined based on the first pose information and the data.
Abstract:
This application provides example terminal device localization methods and related devices. One example method includes obtaining, from a vector map, a first map point matching a first feature point in a current image frame shot by a terminal device. A second map point matching a second feature point in another image frame before the current image frame is obtained from the vector map. A pose in which the terminal device shoots the current image frame is adjusted based on a target function to obtain, as a localization result of the terminal device, a pose in which the terminal device shoots the current image frame and that is obtained after current adjustment. The target function includes a first matching error between the first feature point and the first map point and a second matching error between the second feature point and the second map point.
Abstract:
The invention relates to a method (500) for assigning a computational block of a software program to cores of a multi-processor system, the method (500) comprising: evaluating (501) a first number of available cores of a first type of the multi-processor system and a second number of available cores of a second type of the multi-processor system; determining (502) a first number of loops of the computational block for binding with the cores of the first type and a second number of loops of the computational block for binding with the cores of the second type; binding (503) the first number of loops with the cores of the first type and binding the second number of loops with the cores of the second type; and executing (504) the loops of the computational block according to the binding (503).