A cross-logistics transfer field resource collaborative allocation method based on federated learning
By constructing multi-source heterogeneous datasets and extracting features within logistics transit centers using federated learning technology, and employing multilayer perceptron models for local training and parameter aggregation, the issues of data privacy and resource scheduling efficiency in logistics transit centers are resolved, enabling collaborative allocation and optimization of resources across transit centers.
Patent Information
- Application Number
- CN202510490455.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-18
- Publication Date
- 2025-10-21
- Estimated Expiration
- 2045-04-18
AI Technical Summary
Traditional centralized resource scheduling methods in logistics transit hubs suffer from problems such as data privacy leakage risks, low system processing efficiency, poor compatibility, and insufficient generalization ability.
Federated learning technology is used for distributed training and secure aggregation to construct multi-source heterogeneous datasets and generate feature vectors. Local training is performed using a multilayer perceptron model, and parameter aggregation is performed in conjunction with a central server. The problem of collaborative allocation optimization of cross-transfer site resources is constructed and solved.
It has improved resource utilization efficiency and collaborative scheduling capabilities while protecting data privacy, thus solving the problems of data silos and privacy protection.
Smart Images

Figure CN120013211B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of logistics sorting, and in particular to a method for collaborative allocation of resources across logistics transfer sites based on federated learning. Background Art
[0002] With the rapid development of the logistics industry, effectively coordinating the allocation of resources across different logistics transfer sites has become crucial for improving logistics efficiency. Traditional centralized resource scheduling methods require uploading heterogeneous data from different logistics transfer sites, such as vehicle dispatch data, personnel operation data, and equipment operation data, to a central server. This not only exposes each logistics transfer site to the risk of data privacy leakage, but also leads to inefficient system processing, poor compatibility, and insufficient generalization due to data heterogeneity. Summary of the Invention
[0003] The purpose of the present invention is to overcome the shortcomings of the existing technology and provide a method for collaborative allocation of resources across logistics transfer sites based on federated learning. Through distributed training and security aggregation technology, the collaborative scheduling of resources in different logistics transfer sites is realized, while protecting the privacy of each logistics transfer site and improving resource utilization efficiency.
[0004] The object of the present invention is achieved through the following technical solutions: constructing a collection of multi-source heterogeneous data in each logistics transfer site, and performing feature extraction to obtain a feature vector of each logistics transfer site;
[0005] Generate local data sets for each logistics transfer station;
[0006] Build a federated learning model, with each logistics transfer station and the central server working together to train;
[0007] Based on the federated learning model, a time span of T The collaborative allocation optimization problem of cross-transfer station resources is solved, and the collaborative allocation strategy is obtained by solving the optimization problem.
[0008] The beneficial effects of the present invention are: the present invention realizes the coordinated scheduling of resources in different logistics transfer stations through distributed training and security aggregation technology, while protecting the privacy of each logistics transfer station and improving resource utilization efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] Figure 1 Flow chart of the method of the present invention. DETAILED DESCRIPTION
[0010] The technical solution of the present invention will be further described in detail below with reference to the accompanying drawings, but the protection scope of the present invention is not limited to the following.
[0011] Federated learning, as a distributed machine learning framework, can collaboratively train models while protecting logistics hubs from sharing raw data. This effectively addresses data silos and privacy issues. Therefore, this paper applies federated learning technology to collaborative resource allocation across logistics hubs. This approach optimizes the global model and improves the efficiency of collaborative resource scheduling while ensuring data security across each hub.
[0012] like Figure 1 As shown in FIG, a method for collaborative resource allocation across logistics transfer stations based on federated learning includes the following steps:
[0013] By deploying sensors, RFID, video surveillance, and other equipment within logistics transfer sites and leveraging logistics management systems to collect key data such as vehicle scheduling, personnel operations, equipment operation, and cargo flow, we construct a multi-source heterogeneous dataset within each logistics transfer site, as shown below:
[0014] (1) Vehicle dispatching dataset: Collect vehicle ID, real-time location, average vehicle load rate, average driving speed, and route complexity (number of turns) in each logistics transfer station and construct the first The vehicle scheduling dataset of logistics transfer stations is denoted as ,in Indicates the The first logistics transfer station The collected data of each vehicle, Indicates the The number of vehicles in a logistics transfer station.
[0015] (2) Personnel work data set: collect information such as personnel ID, average working hours, task completion efficiency, historical performance scores, etc. in each logistics transfer station, and construct the first The personnel operation data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station The data collected by individuals, Indicates the The number of people in a logistics transfer station.
[0016] (3) Equipment operation data set: collect information such as equipment ID, equipment operation time, real-time operation status, cumulative failure time, and remaining days of maintenance cycle in each logistics transfer station, and construct the first The equipment operation data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station The data collected by each device, Indicates the The number of equipment in a logistics transfer station.
[0017] (4) Cargo flow data set: collect information such as cargo ID, category, weight, in and out timestamp, destination transfer station ID, etc. in each logistics transfer station, and construct the first The cargo flow data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station The collection data of each cargo, Indicates the The quantity of goods in a logistics transfer station.
[0018] In the embodiments of the present application, raw data is collected from various data sources (such as IoT sensors, field control systems, enterprise management systems, logistics monitoring platforms, etc.). This data may have different formats and come from diverse sources, containing various types of information, such as numerical, textual, and time-based information. Data preprocessing and cleaning: The collected raw data is formatted, missing values are filled, and outlier detection is performed to improve data quality. During this process, data from different data sources must be uniformly defined to ensure that the meaning of each field is consistent during subsequent processing. Format unification and data fusion: Due to the heterogeneity of data sources, the data from each data source must be mapped into a predefined unified data structure. Using data fusion technology, key information from each source data (such as operational indicators, equipment status, environmental information, etc. of a logistics transfer station) is integrated into a feature vector. The generated feature vector can accurately reflect the specific attributes and operating status of each logistics transfer station. Constructing a local dataset: By processing the data from the above steps, a local dataset is divided according to the specific business logic of each logistics transfer station. This dataset generally contains multiple feature vectors (each vector represents a sample or the state at a moment) and corresponding category data information (such as resource allocation strategy, module type, etc.), providing raw data support for the subsequent construction of a local training set.
[0019] To facilitate the subsequent local model training and parameter upload and download, the numerical data in the dataset constructed in each transfer station is standardized, the categorical data is one-hot encoded, and the timestamp is converted into a time feature.
[0020] The multi-source heterogeneous data such as vehicle dispatch, personnel operation, equipment operation, and cargo flow are standardized, their core features are extracted, and uniformly represented as feature vectors. ,in Indicates the The first logistics transfer station feature sample vectors, The total number of feature samples obtained by sampling the transfer field ( =4), each Specifically, it is composed of vehicle, personnel, equipment, and cargo datasets extracted and combined through feature engineering, which can be expressed as:
[0021]
[0022] in, This is a custom feature engineering module consisting of feature extraction, normalization, and principal component analysis (PCA). PCA is a commonly used linear dimensionality reduction technique. Its main purpose is to project high-dimensional data into a low-dimensional space while preserving as much variation as possible in the original data. It is a classic method.
[0023] is the statistical interval parameter. For the feature extraction part, the specific operations are as follows:
[0024] For the Logistics transfer stations, respectively, from their corresponding vehicle scheduling datasets , Personnel Job Dataset , equipment operation data set , cargo flow dataset Extract the following features: Normalize the average vehicle load rate, average driving speed, and route complexity index (number of turns) in the vehicle scheduling dataset and form subvectors ; Normalize the three indicators of average working hours, task completion efficiency, and historical performance score in the personnel operation data set and form a sub-vector ; Normalize the equipment operation time, average maintenance cycle of a single device, and real-time status ratio (operation / standby / fault) in the equipment operation data set and form a sub-vector ; For the cargo flow data set, the average residence time of goods (calculated by the in-and-out timestamp), the category proportion distribution (calculated by the number of recorded categories and the overall number), and the frequency of in-and-out per unit time (calculated by the in-and-out timestamp) are normalized and formed into subvectors ; Then splice into a complete feature vector ;Right now ;
[0025] Among them, the normalization part is mainly the standardization of numerical data: Min-Max normalization: maps the value to a fixed interval according to the minimum and maximum values. The formula is
[0026] x' = (x - min) / (max - min);
[0027] In an embodiment of the present application, categorical data can be one-hot encoded: For categorical data, one-hot encoding is used to avoid the size order problem caused by directly assigning numerical codes. The specific steps are as follows: Determine the category: For each categorical variable, first determine the set of all possible categories. Code generation: Generate a binary feature for each category in the set. If the category to which a sample belongs matches the current feature, the feature is assigned a value of 1, otherwise it is assigned a value of 0. This encoding method converts categorical data into a numerical vector, allowing machine learning models to process discrete variable information.
[0028] In the embodiments of the present application, timestamps can also be converted into time features: time information often implies obvious periodicity and trends. To better capture the impact of time, the original timestamp is usually converted into multiple time features in the preprocessing stage, including: time decomposition: extracting basic components such as year, month, day, hour, minute, and second; periodic features: for periodic scenarios, such as fluctuations within a day, information such as hours is converted into periodic features using sine and cosine functions; classification features such as weekdays / weekends: judging whether it is a weekday, weekend, holiday, etc. based on the timestamp, so as to capture business characteristics in different time periods;
[0029] Generate the The local data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station feature vectors, Indicates the The number of data categories in the logistics transfer station, and the local training set is constructed based on the local data set ,in Indicates the A set of resource allocation strategies for logistics transfer stations, where Indicates the A logistics transfer station for the A real resource allocation strategy.
[0030] Specifically, the platform makes a set of specific allocation plans for key dispatchable resources including vehicles, manpower, equipment and goods according to the current status and task requirements of the logistics transfer station, including the binding relationship between transport vehicles and routes; the sorting areas where sorting personnel are located; the use and rotation of sorting equipment; the sorting system for the specific allocation of sorted goods, etc., as supervision signals for the training of the federated learning model. This invention uses the real resource allocation results corresponding to each sample Standardized encoding is performed, specifically: 1) For scenarios with a limited set of policies and a unique policy number for each scheduling, one-hot vector encoding is used, suitable for classification model training; 2) For policies composed of a combination of multi-dimensional resource dimensions, a multi-dimensional discrete vector representation is used, with each resource type's scheduling result output as an independent prediction target; 3) If a resource type has multiple valid options within the same policy (such as multi-person collaboration or parallel device operation), a multi-hot encoding structure is used. This structured encoding approach effectively supports the deep model training and inference process of the present invention, improving the learning accuracy and system adaptability of resource scheduling policies.
[0031] Next, a multi-layer perceptron model is used to perform local model training at each logistics transfer station. The loss function is expressed as:
[0032] (1)
[0033] in, For the multi-layer perception model The first logistics transfer station k A resource allocation strategy, For the The parameter vector in the logistics transfer station is used. B The parameters are updated using the mini-batch stochastic gradient descent method. The update process can be expressed as:
[0034] (2)
[0035] in, is the learning rate, is the gradient of a single batch; 、 Respectively represent Logistics transfer station t The moment and t +1 time instant local model parameters;
[0036] Then, the central server uses the probability from Randomly select from logistics transfer stations The training and parameter aggregation are performed at each logistics transfer station. The parameter update process is as follows:
[0037] Since each transfer node collects the feature vector Divided into small batches, each batch size is B , used for the gradient descent update process during local model training; for each logistics transfer station, combined with the updated rounds, calculate the iterative update parameters of the selected s-th logistics transfer station ;
[0038] (3)
[0039] in, Indicates the selected s-th logistics transfer station The parameters after the round of iteration, Represents global parameters; Z represents the round of current iteration;
[0040] The central server updates the global parameters. The update process is as follows:
[0041] (4)
[0042] in, To consider the data weight of each logistics transfer station The global update amount is calculated as follows:
[0043] (5)
[0044] It represents the number of characteristic samples of the sth logistics transfer station among the S selected logistics transfer stations;
[0045] Let t=t+1, the central server uses the updated global model parameters as the new , sent to each logistics transfer station for the next round of training until the set number of rounds is reached and the training results are obtained. The global model parameters at this time are recorded as , and distributed to each logistics transit node.
[0046] Finally, based on the federated learning model, a time span of T Optimization problem of cross-transfer station resource collaborative allocation:
[0047] (6)
[0048] in, Indicates the Transfer stations during the period Call The number of class resources, Indicates the Transfer stations during the period Call The cost of class resources, To call The priority weight of the class resource; the first constraint is the resource capacity constraint, Indicates the Class resources in time period The available capacity, the second constraint is the task demand constraint, Indicates the Logistics transfer stations during the period The third constraint is the soft constraint of the federated learning model, which ensures that the amount of resource allocation is consistent with the recommended trend of the federated learning model. is the allowable probability deviation range. By solving this problem through integer programming algorithms such as branch and bound method, the optimal resource allocation solution can be obtained. .
[0049] The foregoing description is a preferred embodiment of the present invention. It should be understood that the present invention is not limited to the form disclosed herein and should not be construed as excluding other embodiments. Instead, the present invention can be used in other combinations, modifications, and environments and can be modified within the scope of the concept described herein through the above teachings or techniques or knowledge in the relevant field. Modifications and variations made by those skilled in the art that do not depart from the spirit and scope of the present invention are intended to be protected by the appended claims.
Claims
1. A method for collaborative resource allocation across logistics transfer stations based on federated learning, characterized by: The following steps are involved: Construct a collection of multi-source heterogeneous data in each logistics transfer station, and perform feature extraction to obtain the feature vector of each logistics transfer station; Generate local data sets for each logistics transfer station. The local data set of the i-th logistics transfer station is recorded as ,in Indicates the The first logistics transfer station feature sample vectors, Indicates the The total number of feature samples of the logistics transfer station, and the local training set is constructed based on the local data set ,in Indicates the A set of resource allocation strategies for logistics transfer stations, where Indicates the The first logistics transfer station A real resource allocation strategy; Build a federated learning model, which is trained collaboratively by various logistics transfer stations and the central server, including; A1. Each logistics transfer station is used as a node in federated learning. The central server sends the current global model parameters to each logistics transfer station. The global model adopts a multi-layer perceptron model, and the global model parameters are the parameters of the multi-layer perceptron model; where t represents the t-th time period, and in the initial state t=1, at this time That is , are the initialized model parameters; A2. Each logistics transfer station performs several rounds of small-batch training based on local data to update local model parameters. The training process is based on each transit station i The set of feature sample vectors As model input, a set of resource allocation strategies obtained from real historical records as a supervisory label; The training goal is to learn a prediction function that maps feature vectors to optimal resource allocation strategies. ,This function achieves model fitting by minimizing the cross entropy loss function, and its local training objective function is: in, represents the policy probability distribution predicted by the model; The overall loss function is (1) in, For the multi-layer perception model The first logistics transfer station k The probability distribution of strategies, For the The parameter vector in the logistics transfer station is used; and the batch size is B The parameters are updated using the mini-batch stochastic gradient descent method. The update process of the local model parameters is expressed as: (2) in, is the learning rate, is the gradient of a single batch; 、 Respectively represent Logistics transfer station t The moment and t +1 time instant local model parameters; A3. Each logistics transfer station uploads the updated local model parameters to the central server; A4. The central server calculates the new global model parameters based on the weighted average of the data size of each node. , and distribute it to each node; The central server uses probability from Randomly select from logistics transfer stations The training and parameter aggregation are performed on each logistics transfer station, and the global parameters are updated. The update process is as follows: Since each transfer node collects the feature sample vector set Divided into small batches, each batch size is B , used for the gradient descent update process during local model training; for each logistics transfer station, combined with the updated rounds, calculate the selected s Iterative update parameters of logistics transfer stations ; (3) in, Indicates the selected s Logistics transfer station The parameters after the round of iteration, Represents global parameters; Z represents the round of current iteration; (4) in, To consider the data weight of each logistics transfer station The global update amount is calculated as follows: (5) It represents the number of characteristic samples of the sth logistics transfer station among the S selected logistics transfer stations; A5. Let t = t + 1, and the central server will use the updated global model parameters as the new , sent to each logistics transfer station for the next round of training until the set number of rounds is reached and the training results are obtained. The global model parameters at this time are recorded as , and distribute it to each logistics transfer node; Based on the federated learning model, a time span of T The collaborative allocation optimization problem of cross-transfer station resources is solved, and the collaborative allocation strategy is obtained by solving the optimization problem.
2. The method for collaborative resource allocation across logistics transfer sites based on federated learning according to claim 1, characterized in that: The said construction of a collection of multi-source heterogeneous data in each logistics transfer station includes: Construct a vehicle scheduling dataset: Collect vehicle ID, real-time location, average vehicle load rate, average driving speed, and route complexity in each logistics transfer station; build the The vehicle scheduling dataset of logistics transfer stations is denoted as ,in Indicates the The first logistics transfer station The collected data of each vehicle, Indicates the The number of vehicles in a logistics transfer station; Build the personnel job dataset: Collect personnel ID, average working hours, task completion efficiency, and historical performance scores in each logistics transfer station; build the The personnel operation data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station The data collected by individuals, Indicates the The number of personnel in each logistics transfer station; Build the device operation dataset: Collect the equipment ID, equipment operation time, real-time operation status, cumulative failure time, and remaining days of maintenance cycle in each logistics transfer station; build the The equipment operation data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station The data collected by each device, Indicates the The number of equipment in each logistics transfer site; Construct cargo flow data set: collect cargo ID, category, weight, in and out timestamp, destination transfer station ID in each logistics transfer station, and construct the first The cargo flow data set of a logistics transfer station is recorded as ,in Indicates the The first logistics transfer station The collection data of each cargo, Indicates the The quantity of goods in a logistics transfer station.
3. The method for collaborative resource allocation across logistics transfer stations based on federated learning according to claim 1, characterized in that: The feature extraction to obtain the feature vector of each logistics transfer station includes: For the i-th logistics transfer station: Feature vectors are obtained by extracting features from vehicle scheduling datasets, personnel operation datasets, equipment operation datasets, and cargo flow datasets. ; in Indicates the The first logistics transfer station feature sample vectors, The total number of feature samples obtained for the transfer site; Custom feature engineering modules, including feature extraction, normalization, or principal component analysis algorithms; is the statistical interval parameter.
4. The method for collaborative resource allocation across logistics transfer sites based on federated learning according to claim 1, characterized in that: Based on the federated learning model, a time span of T Optimization problem of cross-transfer station resource collaborative allocation: (6) in, Indicates the Transfer stations during the period Call The number of class resources, Indicates the Transfer stations during the period Call The cost of class resources, To call The priority weight of the class resource; the first constraint is the resource capacity constraint, Indicates the Class resources in time period The available capacity, the second constraint is the task demand constraint, Indicates the Logistics transfer stations during the period The third constraint is the soft constraint of the federated learning model, which ensures that the amount of resource allocation is consistent with the recommended trend of the federated learning model. Indicates that the parameter at time t is The federated learning model on the local dataset The recommended amount of resource allocation is is the allowable probability deviation range; The problem is solved by the branch-and-bound integer programming algorithm to obtain the optimal resource allocation solution. .