Search

CN-120409896-B - Marine ship energy management method and system based on pyramid diversified attention

CN120409896BCN 120409896 BCN120409896 BCN 120409896BCN-120409896-B

Abstract

The invention discloses a marine vessel energy management method and system based on pyramid diversity attention, wherein the method comprises the steps of collecting vessel operation data, carrying out data fusion processing, executing extrusion and excitation initialization operation based on a convolution neural network, taking the fused data as input, and constructing a pyramid diversity attention network classification model which comprises a trunk CNN, a local CNN, a global CNN and an energy management mode classification layer, wherein CNN is an abbreviation of the convolution neural network, the local CNN comprises a pyramid attention module, a diversity learning module and a layering bilinear pooling module, and executing an electronic converter action to carry out power distribution through the power output mode of the marine vessel. Based on the power electronic technology, the switching of different power output modes is realized by controlling the operation mode of the electronic converter, so that the power reliability of a key load is improved, and the stable operation of a ship is ensured.

Inventors

  • Cai Cunli
  • QIAO SEN
  • HUA LIANG

Assignees

  • 南通大学

Dates

Publication Date
20260512
Application Date
20250407

Claims (8)

  1. 1. A method for managing energy of a marine vessel based on pyramid diversity attention, comprising the steps of: step1, acquiring ship operation data and carrying out data fusion processing; The method comprises the steps of obtaining ship operation data through sensors by a system, constructing a global array input model to conduct information fusion to obtain a global array, and fusing all sensor outputs into one array by the inter-sensor array , wherein, Represent the first The number of sensors to be used in the process of detecting the position of the object, G is the number of sensors, the sensors For output of (2) The representation is made of a combination of a first and a second color, , wherein, Is the number of outputs of the sensor and, Here, where Is the duration of each sensor output, Is the output of one sensor, thus the global input array thus gives: ; Wherein, the The final output result of the global array input model is used as input data of pyramid diversified attention network classification model; step 2, extrusion and excitation initialization operation based on a convolutional neural network is executed; step 3, taking the fused data in the step 1 as input, taking a power output mode of the marine vessel as output, and constructing a pyramid diversified attention network classification model which comprises a trunk CNN, a local CNN, a global CNN and an energy management mode classification layer, wherein CNN is an abbreviation of a convolutional neural network; In the step 3, the construction of the diversified learning module is specifically as follows, the diversified learning module provides a divergence loss For directing multiple local branches to learn different attention masks , ,..., Therefore, different sensors are positioned, robust identification is realized through diversified local learning, and the formula is defined as follows: ; where t is a hyper-parametric boundary, S represents the number of scales, B represents the number of local branches, And Representing the attention masks learned by local branches j and k in the i-th layer respectively, Representing the sum of the values of the sum, Diversity learning encourages each local branch to learn a different attention mask by increasing the distance between learned attention masks; and 4, executing the action of the electronic converter to distribute power through the power output mode of the marine ship.
  2. 2. The method for energy management of a marine vessel based on pyramid diversity attention according to claim 1, wherein step 2 specifically comprises the steps of: Step 2.1, squeezing the input features, for any given transformation Will input features Mapping to feature mapping Wherein Wherein R represents a three-dimensional space, , , The number of channels representing the height, width and feature matrix, respectively, for convolution, the squeeze and Stimulus (SE) blocks are constructed to perform feature recalibration, mapping First by extrusion In its spatial dimension Upper aggregate feature matrix to generate channel descriptors Generating an embedding of the global distribution of the channel-like characteristic responses, thereby allowing information from the global reception field of the network to be used by all layers thereof; Step 2.2, exciting the output result of step 2.1, wherein the aggregation is followed by exciting The excitation operation takes the form of a self-selected channel mechanism that will embed as input and generate a set of per-channel modulation weights that are multiplied by the channel Mapping elements Generating output of SE blocks The output is fed directly to the subsequent layers of the network.
  3. 3. The energy management method of a marine vessel according to claim 1, wherein in step 3, the pyramid attention module is constructed by Representing the input of the pyramid's attention, R represents three-dimensional space, , , The number of channels respectively representing height, width and feature matrix is divided into different scales for outputting Wherein Is the number of dimensions; Is the first Layer output, wherein Representing space size, finest layers and input Other layers divide the feature matrix into different sub-regions, pool the corresponding sub-regions, and then, for the first The individual scales, the goal being to output a diversified attention mask Wherein Is the number of partial branches, the first The first of the dimensions The output attention mask has a mask with input The same space size, i.e ; Constructing a spatial modeling feature matrix by using a local attention network (LANet), and regressing weights of different spatial positions by using two continuous convolution layers, wherein the first layer is provided with A feature matrix followed by a layer of linear rectifying units (ReLU) to increase nonlinearity, wherein The number of channels of the feature matrix, Is the channel reduction ratio, and the second layer generates a feature matrix by Sigmoid function, namely ; Upsampling different attention masks of multiple local branches in different scales to match them to an input using bilinear interpolation Having the same size, the first In the third dimension Refinement feature matrix of individual local branches By attention masking And input Is polymerized by Hadamard product: ; wherein ∘ denotes element level multiplication, finally, the th The output of each scale is achieved by first combining The partial branches are connected and then output through a1 x 1 convolutional layer And the feature matrixes with different scales are connected and used as the output of the pyramid attention module.
  4. 4. The method for energy management of a marine vessel based on pyramid diversity attention of claim 1, wherein in step 3, the hierarchical bilinear pooling module is constructed by Is the output of two different layers, wherein , , The channel numbers respectively represent the height, width and characteristic matrix Upper spatial position Is one of (2) -Dimensional features expressed as The c-dimension in Y is characterized by More comprehensive local features are captured using cross-layer interactions, defined as follows: ; Wherein, the Is the projection output of the device, Is a projection matrix, ∘ representing element-level multiplication; Representation pair matrix Is subjected to a transposition operation of (a), Is that the projection matrix is decomposed into two vectors with rank of 1, and in order to encode local information, the features should be extended to a high-dimensional space through linear mapping, defining a weight matrix To obtain d-dimensional features z: ; Wherein ∘ denotes an element-level multiplication, , Representation pair matrix Is subjected to a transposition operation of (a), Is the channel number of the feature matrix, d is the dimension of the projection feature, and captures more discriminative local features from more layers of aggregated features, and is provided Is an output from three different layers, and z is scalable to connect multiple cross-layer representations: ; wherein ∘ denotes element-level multiplication, matrix , Representation pair matrix Is subjected to a transposition operation of (a), Is the number of channels of the feature matrix and d is the dimension of the projected feature.
  5. 5. The method of energy management of a marine vessel based on pyramid diversity attention according to claim 1, characterized in that in step 3, the global CNN consists of a global averaging pool and fully connected layers, and the data features of the whole sensor are extracted by successive Global Averaging Pool (GAP) and Fully Connected (FC) layers with 512 cells.
  6. 6. The energy management method of a marine vessel based on pyramid diversity attention according to claim 1, wherein in step 3, the energy management pattern classification layer combines the outputs of local CNN and global CNN to obtain 1024 output units, and adds a full connection layer for energy management pattern recognition.
  7. 7. A pyramid-based diversified attention energy management system for a marine vessel for implementing the method of claim 1, comprising a multi-element sensor, a controller and a power electronic converter; The multi-element sensor collects ship operation data and transmits the data to the controller for processing; The controller is internally provided with a pyramid diversified attention network classification model, and comprises a trunk CNN, a local CNN, a global CNN and an energy management mode classification layer, wherein the local CNN comprises a pyramid attention module, a diversified learning module and a hierarchical bilinear pooling module; after determining the operation modes, the operation modes of the power electronic converters of each group correspond to one power output mode of the ship power system.
  8. 8. A computer device comprising a memory, a processor and a computer program stored on the memory, characterized in that the processor executes the computer program to carry out the steps of the method of claim 1.

Description

Marine ship energy management method and system based on pyramid diversified attention Technical Field The invention belongs to the technical field of ship energy management, and particularly relates to a method and a system for managing energy of a marine ship based on pyramid diversified attention. Background Conventional ship power distribution systems face many challenges such as infrastructure aging, distributed power distribution system integration, natural disaster frequency, and the like. The existing ship energy management method is mainly faced with the problems of redundant response of a signal area, low energy distribution accuracy and the like, and particularly cannot realize efficient and stable energy management under different working conditions. In addition, in the existing ship energy management system, power optimization is usually carried out on a ship generator set, so that high requirements are made on power adjustment accuracy of a generator, meanwhile, the stability and reliability of a ship power system are threatened, and the ship energy management system cannot be suitable for general ship conditions. Disclosure of Invention The invention aims to provide a marine ship energy management method and system based on pyramid diversified attention. The method comprises the steps of classifying and summarizing various typical working conditions possibly encountered by a ship during offshore operation, and determining an optimal energy distribution method for the ship under corresponding working conditions. The technical scheme is that the energy management method of the marine ship based on pyramid diversified attention comprises the following steps: step1, acquiring ship operation data and carrying out data fusion processing; step 2, extrusion and excitation initialization operation based on a convolutional neural network is executed; step 3, taking the fused data in the step 1 as input, taking a power output mode of the marine vessel as output, and constructing a pyramid diversified attention network classification model which comprises a trunk CNN, a local CNN, a global CNN and an energy management mode classification layer, wherein the local CNN comprises a pyramid attention module, a diversified learning module and a layering bilinear pooling module; and 4, executing the action of the electronic converter to distribute power through the power output mode of the marine ship. Further, step 1 is specifically that the system obtains ship operation data through the sensors, builds a global array input model to perform information fusion to obtain a global array, the inter-sensor array fuses all sensor outputs into one array a (m, N), wherein S g represents the G-th sensor, g=0, 1., (G-1), G is the number of sensors, the output of sensor S g is represented by S gm, m=0, 1., (m G -1), wherein m G is the number of sensor outputs, n=0, 1., (N-1), where N is the duration of each sensor output, and each row of a (m, N) is the output of one sensor, and thus the global input array thus gives: Wherein, the The final output result of the global array input model is used as input data of pyramid diversified attention network classification model. Further, the step2 specifically includes the following steps: Step 2.1, performing a squeeze operation on the input features, mapping the input X to a feature map U for any given transformation F tr, where U ε R H×W×C, for convolution, constructing a squeeze and Stimulus (SE) block to perform feature recalibration, feature U first generating a channel descriptor W by aggregating feature matrices over its spatial dimension H by a squeeze operation F sq (.); Step 2.2, performing an excitation operation on the output result of step 2.1, followed by an excitation operation F ex (, W), the excitation operation taking the form of a self-selected channel mechanism that will embed as input and produce a set of per-channel modulation weights that map U with the elements by a channel product F scale (, W) to generate an output of the SE block The output is fed directly to the subsequent layers of the network. Further, in the step 3, the pyramid attention module is constructed specifically by setting X ε R h×w×c to represent pyramid attention input, R to represent three-dimensional space, h, w, c to respectively represent height, width and channel number of feature matrix; is the output of the ith layer, wherein h i×wi represents the space size, c is the channel number of the feature matrix, the finest layer is the same as the input feature X in size, other layers divide the feature matrix into different subareas and pool the corresponding subareas, and secondly, for the ith scale, the goal is to output diversified attention masks Where B is the number of partial branches and the j-th output attention mask in the i-th scale has the same spatial size as input X i, i.e Constructing a spatial modeling feature matrix by using a local attention network (LANet), and regre