Roof area calculation method and device based on reverse pixel rearrangement

By designing a deep convolutional network structure based on inverse pixel rearrangement, the problems of low roof extraction accuracy and complex model are solved, and high-precision roof extraction and area calculation are achieved, which is suitable for resource-constrained environments.

CN120689394APending Publication Date: 2025-09-23STATE GRID JIANGSU ELECTRIC POWER CO LTD RESEARCH INSTITUTE +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510898433.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-01
Publication Date
2025-09-23

AI Technical Summary

Technical Problem

The existing technology has low roof extraction accuracy and complex models, making it difficult to deploy quickly in resource-constrained environments. Traditional methods are unable to cope with the diverse shapes of buildings and occlusion problems, resulting in unsatisfactory roof extraction accuracy and efficiency.

Method used

A roof area calculation method based on reverse pixel rearrangement is adopted, and a specific deep convolutional network structure is designed, including a reverse pixel rearrangement module, a downsampling module, an upsampling module, a splicing module and a multi-layer perceptron module. The reverse pixel rearrangement technology fully utilizes the spatial detail information, reduces the number of parameters, and improves the accuracy and efficiency of roof extraction.

Benefits of technology

It achieves high-precision extraction and area calculation of roofs, reduces the number of model parameters, improves the accuracy and efficiency of roof extraction, and is suitable for resource-constrained environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120689394A_ABST
    Figure CN120689394A_ABST
Patent Text Reader

Abstract

The invention discloses a roof area calculation method and device based on reverse pixel rearrangement, and belongs to the technical field of roof extraction and area calculation, and the method comprises the steps: obtaining a remote sensing image of a target region, and carrying out the preprocessing of the remote sensing image; inputting the preprocessed remote sensing image into the trained image segmentation model to obtain a roof segmentation mask graph; calculating a roof area based on the roof segmentation mask graph; in the image segmentation model, a reverse pixel rearrangement module rearranges a pixel block with a preset size in the preprocessed remote sensing image into a pixel, increases the number of channels corresponding to the pixel to a preset number of channels, and polls all the pixels until all the pixels are rearranged. According to the method, image down-sampling is carried out while sight space information is effectively reserved by utilizing a reverse pixel rearrangement technology, the parameter quantity of a conventional semantic segmentation deep learning model is greatly reduced, space detail information can be fully utilized, the accuracy and efficiency of roof extraction are improved, and high-precision extraction and area calculation of a roof are realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a method and device for calculating roof area based on reverse pixel rearrangement, and belongs to the technical field of roof extraction and area calculation. Background Art

[0002] Accurately counting building rooftop areas is crucial for estimating photovoltaic potential and planning new energy sources. High-resolution remote sensing imagery is rich in information, and computer vision can be used to extract rooftop information and calculate effective rooftop area. This approach offers advantages such as low cost, wide scope, and automation. However, traditional methods often rely on handcrafted features or simple algorithms, making them difficult to handle with diverse building shapes and occlusions, resulting in suboptimal extraction accuracy and efficiency.

[0003] Current semantic segmentation methods based on convolutional neural networks can be trained end-to-end on remote sensing imagery to extract building rooftop outlines. However, traditional downsampling (such as max pooling) and upsampling (such as deconvolution) operations can lead to loss of spatial information in feature maps, affecting detail recovery and resulting in low rooftop extraction accuracy. Furthermore, existing deep network architectures often have complex parameters and high computational complexity, making them difficult to deploy quickly in resource-constrained environments. Summary of the Invention

[0004] The purpose of the present invention is to provide a method and device for calculating roof area based on reverse pixel rearrangement, so as to solve the problems of low roof extraction accuracy and complex model in the prior art.

[0005] To achieve the above objectives, the present invention is implemented by adopting the following technical solutions: In a first aspect, the present invention provides a method for calculating roof area based on inverse pixel rearrangement, comprising: Acquire remote sensing images of the target area and perform preprocessing; Input the preprocessed remote sensing image into the trained image segmentation model to obtain the roof segmentation mask map; Calculating the roof area based on the roof segmentation mask image; Among them, the image segmentation model includes a reverse pixel rearrangement module, a downsampling module, three upsampling modules based on bilinear interpolation, a splicing module, a multi-layer perceptron module and a pixel rearrangement module. The reverse pixel rearrangement module rearranges the preset size pixel block in the preprocessed remote sensing image into one pixel, and at the same time increases the number of channels corresponding to the pixel to the preset number of channels, polls all pixels until all pixels are rearranged, and the reverse pixel rearrangement module is connected to the downsampling module. The downsampling module includes three layers of sub-modules connected in sequence, each layer of sub-modules performs downsampling once, and one layer of sub-module generates a feature map and outputs it to an upsampling module based on bilinear interpolation. The splicing module splices the feature maps output by the three upsampling modules based on bilinear interpolation to obtain a spliced ​​feature map and outputs it to the multi-layer perceptron module. The multi-layer perceptron module is connected to the pixel rearrangement module. The multi-layer perceptron module performs nonlinear transformation and category prediction on the spliced ​​feature map to obtain a roof type prediction map. The pixel rearrangement module performs pixel rearrangement and mapping on the roof type prediction map to obtain a roof segmentation mask map.

[0006] Furthermore, the preprocessing includes noise removal, color correction and image segmentation, and the image segmentation includes dividing the remote sensing image into image blocks of preset pixel size.

[0007] Furthermore, the preset pixel block size is a 2×2 pixel block, and the preset number of channels is four times the original number of channels.

[0008] Furthermore, the first layer submodule in the downsampling module includes a 3×3 convolutional layer and three three-layer residual blocks. In the first layer submodule, the stride of the convolutional layer is 1, the number of channels is 64, and the convolutional layer is followed by three three-layer residual blocks. The second sub-module in the downsampling module includes a 3×3 convolutional layer and five three-layer residual blocks. In the second sub-module, the stride of the convolutional layer is 2, the number of channels is 256, and the convolutional layer is followed by five three-layer residual blocks. The third-layer submodule in the downsampling module includes a 3×3 convolutional layer and 8 three-layer residual blocks. In the third-layer submodule, the stride of the convolutional layer is 2, the number of channels is 512, and the 8 three-layer residual blocks are connected in sequence after the convolutional layer.

[0009] Furthermore, the three-layer residual block includes three sub-layers connected in sequence, the first sub-layer is a 1×1 convolution for dimensionality reduction, the second sub-layer is a 3×3 convolution for feature extraction, and the third sub-layer is a 1×1 convolution for dimensionality increase; Batch normalization layers and Leaky ReLU activation layers are set between sub-layers, and the output and input are added through jump connections to form a residual structure.

[0010] Furthermore, the upsampling module includes a 1×1 convolutional layer, a batch normalization layer, a leaky ReLU activation layer, a bilinear interpolation layer and a 3×3 convolutional layer connected in sequence.

[0011] Furthermore, the multi-layer perceptron module includes a 1×1 convolutional layer, a batch normalization layer, a LeakyReLU activation layer, a 3×3 convolutional layer, a batch normalization layer, a Leaky ReLU activation layer and a 3×3 convolutional layer connected in sequence.

[0012] Furthermore, the pixel rearrangement module includes a 3×3 convolutional layer, a batch normalization layer, a LeakyReLU activation layer, a pixel rearrangement layer and a 3×3 convolutional layer connected in sequence.

[0013] Furthermore, the calculating the roof area based on the roof segmentation mask image includes: The pixel values ​​in the roof segmentation mask image represent the probability that the corresponding position is a roof. Based on a preset probability threshold, the roof segmentation mask image is binarized to obtain a roof segmentation image; The area of ​​the feature represented by each pixel is obtained based on the spatial resolution of the remote sensing image. The number of pixels determined to be roofs in the roof segmentation map is multiplied by the area of ​​the feature represented by each pixel to obtain the roof area.

[0014] In a second aspect, the present invention provides a roof area calculation device based on reverse pixel rearrangement, comprising: The remote sensing image acquisition module is configured to: acquire remote sensing images of the target area and perform preprocessing; The roof segmentation module is configured to: input the pre-processed remote sensing image into the trained image segmentation model to obtain a roof segmentation mask map; a roof area calculation module, configured to: calculate the roof area based on the roof segmentation mask image; Among them, the image segmentation model includes a reverse pixel rearrangement module, a downsampling module, three upsampling modules based on bilinear interpolation, a splicing module, a multi-layer perceptron module and a pixel rearrangement module. The reverse pixel rearrangement module rearranges the preset size pixel block in the preprocessed remote sensing image into one pixel, and at the same time increases the number of channels corresponding to the pixel to the preset number of channels, polls all pixels until all pixels are rearranged, and the reverse pixel rearrangement module is connected to the downsampling module. The downsampling module includes three layers of sub-modules connected in sequence, each layer of sub-modules performs downsampling once, and one layer of sub-module generates a feature map and outputs it to an upsampling module based on bilinear interpolation. The splicing module splices the feature maps output by the three upsampling modules based on bilinear interpolation to obtain a spliced ​​feature map and outputs it to the multi-layer perceptron module. The multi-layer perceptron module is connected to the pixel rearrangement module. The multi-layer perceptron module performs nonlinear transformation and category prediction on the spliced ​​feature map to obtain a roof type prediction map. The pixel rearrangement module performs pixel rearrangement and mapping on the roof type prediction map to obtain a roof segmentation mask map.

[0015] Compared with the prior art, the beneficial effects achieved by the present invention are: The present invention provides a method and device for calculating roof area based on reverse pixel rearrangement. By designing an image segmentation model, that is, by designing a specific deep convolutional network structure, the number of parameters of a conventional semantic segmentation deep learning model is greatly reduced. The reverse pixel rearrangement technology can fully utilize spatial detail information, perform image downsampling while effectively retaining spatial information, improve the accuracy and efficiency of roof extraction, and achieve high-precision extraction and area calculation of the roof. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 is a flow chart of a roof area calculation method based on reverse pixel rearrangement corresponding to Example 1; Figure 2 is a flow chart of a roof area calculation method based on reverse pixel rearrangement corresponding to Example 2; Figure 3 is a schematic diagram of operations performed by the reverse pixel rearrangement module provided in Example 2; Figure 4 2 is a schematic diagram of the structure of the three-layer residual block provided in Example 2; Figure 5 This is a schematic diagram of the network architecture used in the feature extraction and fusion process provided in Example 2. DETAILED DESCRIPTION

[0017] The present invention will be further described below in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solutions of the present invention and are not intended to limit the scope of protection of the present invention.

[0018] Example 1

[0019] like Figure 1 As shown, this embodiment provides a roof area calculation method based on reverse pixel rearrangement, including: Acquire remote sensing images of the target area and perform preprocessing; Input the preprocessed remote sensing image into the trained image segmentation model to obtain the roof segmentation mask map; Calculate the roof area based on the roof segmentation mask map; Among them, the image segmentation model includes a reverse pixel rearrangement module, a downsampling module, three upsampling modules based on bilinear interpolation, a splicing module, a multi-layer perceptron module and a pixel rearrangement module. The reverse pixel rearrangement module rearranges the preset size pixel block in the preprocessed remote sensing image into one pixel, and at the same time increases the number of channels corresponding to the pixel to the preset number of channels, polls all pixels until all pixels are rearranged, and the reverse pixel rearrangement module is connected to the downsampling module. The downsampling module includes three layers of sub-modules connected in sequence, each layer of sub-modules performs downsampling once, and one layer of sub-module generates a feature map and outputs it to an upsampling module based on bilinear interpolation. The splicing module splices the feature maps output by the three upsampling modules based on bilinear interpolation to obtain a spliced ​​feature map and outputs it to the multi-layer perceptron module. The multi-layer perceptron module is connected to the pixel rearrangement module. The multi-layer perceptron module performs nonlinear transformation and category prediction on the spliced ​​feature map to obtain a roof type prediction map. The pixel rearrangement module performs pixel rearrangement and mapping on the roof type prediction map to obtain a roof segmentation mask map.

[0020] The present invention designs an image segmentation model, that is, by designing a specific deep convolutional network structure, which greatly reduces the number of parameters of the conventional semantic segmentation deep learning model. By using the reverse pixel rearrangement technology, it can fully utilize the spatial detail information, perform image downsampling while effectively retaining the spatial information, improve the accuracy and efficiency of roof extraction, and realize high-precision extraction and area calculation of the roof.

[0021] Example 2

[0022] like Figure 2 As shown, this embodiment provides a method for calculating roof area based on reverse pixel rearrangement, and its specific implementation includes the following steps: Step S1: Acquire remote sensing images and perform preprocessing: Select a high-resolution remote sensing image of the target area as input data. The image resolution can be customized as needed. Perform necessary preprocessing on the acquired remote sensing image, such as noise removal and color correction, to improve subsequent processing. Divide the preprocessed remote sensing image into 256×256 pixel blocks as input for the subsequent model.

[0023] Perform pixel-level annotation of rooftop areas on remote sensing images during the training phase to generate a rooftop mask corresponding to the remote sensing image. Use existing annotation tools to manually or semi-automatically label each building rooftop area, providing labeled data for subsequent network training.

[0024] Step S2: Reverse pixel rearrangement and downsampling: The pre-processed remote sensing image is input into the reverse pixel rearrangement module. The operations performed by the reverse pixel rearrangement module include: rearranging each 2x2 pixel block in the original image into a pixel of the output feature map, and increasing the number of channels corresponding to the pixel to 4 times. The operations performed by the reverse pixel rearrangement module are as follows: Figure 3 shown.

[0025] The feature map output by the reverse pixel rearrangement module is calculated in the following three stages.

[0026] Stage 1: A 3×3 convolutional layer outputs 64 channels, followed by three three-layer residual blocks. The stride of the convolutional layer in stage 1 is 1. Stage 2: First, a 3×3 convolution (stride = 2) is used to downsample the feature map, keeping the number of channels at 256, followed by five three-layer residual blocks; Stage 3: First, downsample again using a 3×3 convolution (stride = 2), keeping the number of channels at 512, followed by 8 three-layer residual blocks.

[0027] like Figure 4 As shown, the structure of the three-layer residual block is as follows: 1×1 convolution for dimensionality reduction (halved), 3×3 convolution for feature extraction, and 1×1 convolution for dimensionality increase (doubled). Batch normalization and Leaky ReLU (Leaky Rectified Linear Unit) activation functions are used between these sub-layers, and the output and input are added via skip connections to form the residual structure. The feature maps of different resolutions generated in stages 1, 2, and 3 are called T1, T2, and T3, respectively.

[0028] Step S3: Feature extraction and fusion: like Figure 5 As shown in Figure 2, the feature maps T1, T2, and T3 are input into three upsampling modules based on bilinear interpolation. The upsampling modules specifically include: 1×1 convolution layer, batch normalization layer, Leaky ReLU activation layer (in Figure 5), bilinear interpolation and 3×3 convolutional layers, thus adjusting the resolution to 128×128. Figure 5 As shown in the figure, the number of input channels of the upsampling module of the input feature map T1 is 1024, and the number of output channels is 256; the number of input channels and the number of output channels of the upsampling module of the input feature map T2 are both 256; the number of input channels and the number of output channels of the upsampling module of the input feature map T3 are both 256.

[0029] The three upsampled feature maps are concatenated according to the channel to obtain a concatenated feature map, which is input into a multi-layer perceptron module. The multi-layer perceptron module specifically includes: 1×1 convolution layer, batch normalization layer, Leaky ReLU activation layer, 3×3 convolution layer, batch normalization layer, Leaky ReLU activation layer and 3×3 convolution layer. Figure 5 In the figure, C represents channel-wise concatenation, with an output channel count of 768. MLP is a multi-layer perceptron module, where the 1×1 convolutional layer has 768 input channels and 256 output channels; the first 3×3 convolutional layer has 256 input channels and 256 output channels; and the second 3×3 convolutional layer has 256 input channels and 64 output channels. The multi-layer perceptron module performs nonlinear transformation and category prediction on the concatenated feature map to obtain a roof type prediction map.

[0030] The results from the previous step are then fed into a pixel reordering module, which consists of a 3×3 convolutional layer, a batch normalization layer, a leaky ReLU activation layer, a pixel reordering layer, and a 3×3 convolutional layer. This yields a feature map with the same resolution as the original image (256×256). Finally, a 1×1 convolution is performed to map this feature map into a binary segmentation prediction map (i.e., the roof segmentation mask). Each pixel in the roof segmentation mask represents the probability that the corresponding location is a roof.

[0031] like Figure 5 As shown in Figure 2, in the pixel rearrangement module, the number of input channels of the first 3×3 convolutional layer is 64, and the number of output channels is 256; the number of input channels of the second 3×3 convolutional layer is 64, and the number of output channels is 1.

[0032] Step S4: Model training: After constructing the above image segmentation model, supervised training is performed during the training phase using labeled remote sensing images and their roof masks. During training, labeled image samples (remote sensing images) are fed into the image segmentation model, and a loss function (such as binary cross-entropy loss) is used to calculate the error between the predicted output and the true label. A gradient descent optimization algorithm is then used to continuously update parameters such as the convolution kernel weights and biases in the image segmentation model through backpropagation. Training is iterated until the loss function converges or the preset number of training rounds is reached. The trained image segmentation model parameters are saved, resulting in the final trained image segmentation model.

[0033] Step S5: Model reasoning and roof extraction: During the inference phase, new, unlabeled remote sensing images are fed into the trained image segmentation model for forward computation. The image segmentation model applies layer-by-layer computation based on learned feature extraction and fusion rules, ultimately outputting a roof segmentation mask. The pixel values ​​in the roof segmentation mask represent the probability that the corresponding location is a roof. A threshold of 0.5 is set, and the roof segmentation map is binarized to obtain the roof segmentation map. Based on the spatial resolution of the remote sensing image, the number of pixels identified as roofs is multiplied by the area represented by each pixel. This completes the automatic extraction and area calculation process for building roofs in the remote sensing image. The resulting roof extraction results can be further used for applications such as photovoltaic potential calculation and planning, and 3D reconstruction.

[0034] Example 3

[0035] Based on the same technical concept as Example 1, this embodiment provides a roof area calculation device based on reverse pixel rearrangement, including: The remote sensing image acquisition module is configured to: acquire remote sensing images of the target area and perform preprocessing; The roof segmentation module is configured to: input the pre-processed remote sensing image into the trained image segmentation model to obtain a roof segmentation mask map; The roof area calculation module is configured to: calculate the roof area based on the roof segmentation mask image; Among them, the image segmentation model includes a reverse pixel rearrangement module, a downsampling module, three upsampling modules based on bilinear interpolation, a splicing module, a multi-layer perceptron module and a pixel rearrangement module. The reverse pixel rearrangement module rearranges the preset size pixel block in the preprocessed remote sensing image into one pixel, and at the same time increases the number of channels corresponding to the pixel to the preset number of channels, polls all pixels until all pixels are rearranged, and the reverse pixel rearrangement module is connected to the downsampling module. The downsampling module includes three layers of sub-modules connected in sequence, each layer of sub-modules performs downsampling once, and one layer of sub-module generates a feature map and outputs it to an upsampling module based on bilinear interpolation. The splicing module splices the feature maps output by the three upsampling modules based on bilinear interpolation to obtain a spliced ​​feature map and outputs it to the multi-layer perceptron module. The multi-layer perceptron module is connected to the pixel rearrangement module. The multi-layer perceptron module performs nonlinear transformation and category prediction on the spliced ​​feature map to obtain a roof type prediction map. The pixel rearrangement module performs pixel rearrangement and mapping on the roof type prediction map to obtain a roof segmentation mask map.

[0036] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, the present application may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0037] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0038] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1The function specified in one or more boxes.

[0039] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 The steps for the function specified in one or more boxes.

[0040] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A roof area calculation method based on reverse pixel rearrangement, characterized in that: include: Acquire remote sensing images of the target area and perform preprocessing; Input the preprocessed remote sensing image into the trained image segmentation model to obtain the roof segmentation mask map; Calculating the roof area based on the roof segmentation mask image; Among them, the image segmentation model includes a reverse pixel rearrangement module, a downsampling module, three upsampling modules based on bilinear interpolation, a splicing module, a multi-layer perceptron module and a pixel rearrangement module. The reverse pixel rearrangement module rearranges the preset size pixel block in the preprocessed remote sensing image into one pixel, and at the same time increases the number of channels corresponding to the pixel to the preset number of channels, polls all pixels until all pixels are rearranged, and the reverse pixel rearrangement module is connected to the downsampling module. The downsampling module includes three layers of sub-modules connected in sequence, each layer of sub-modules performs downsampling once, and one layer of sub-module generates a feature map and outputs it to an upsampling module based on bilinear interpolation. The splicing module splices the feature maps output by the three upsampling modules based on bilinear interpolation to obtain a spliced ​​feature map and outputs it to the multi-layer perceptron module. The multi-layer perceptron module is connected to the pixel rearrangement module. The multi-layer perceptron module performs nonlinear transformation and category prediction on the spliced ​​feature map to obtain a roof type prediction map. The pixel rearrangement module performs pixel rearrangement and mapping on the roof type prediction map to obtain a roof segmentation mask map.

2. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The preprocessing includes noise removal, color correction and image segmentation, and the image segmentation includes dividing the remote sensing image into image blocks of preset pixel sizes.

3. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The preset size pixel block is a 2×2 pixel block, and the preset number of channels is four times the original number of channels.

4. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The first sub-module in the downsampling module includes a 3×3 convolutional layer and three three-layer residual blocks. In the first sub-module, the stride of the convolutional layer is 1, the number of channels is 64, and the convolutional layer is followed by three three-layer residual blocks. The second sub-module in the downsampling module includes a 3×3 convolutional layer and five three-layer residual blocks. In the second sub-module, the stride of the convolutional layer is 2, the number of channels is 256, and the convolutional layer is followed by five three-layer residual blocks. The third-layer submodule in the downsampling module includes a 3×3 convolutional layer and 8 three-layer residual blocks. In the third-layer submodule, the stride of the convolutional layer is 2, the number of channels is 512, and the 8 three-layer residual blocks are connected in sequence after the convolutional layer.

5. The roof area calculation method based on reverse pixel rearrangement according to claim 4, characterized in that: The three-layer residual block includes three sub-layers connected in sequence, the first sub-layer is a 1×1 convolution for dimensionality reduction, the second sub-layer is a 3×3 convolution for feature extraction, and the third sub-layer is a 1×1 convolution for dimensionality increase; Batch normalization layers and Leaky ReLU activation layers are set between sub-layers, and the output and input are added through jump connections to form a residual structure.

6. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The upsampling module includes a 1×1 convolutional layer, a batch normalization layer, a leaky ReLU activation layer, a bilinear interpolation layer, and a 3×3 convolutional layer connected in sequence.

7. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The multi-layer perceptron module includes a 1×1 convolutional layer, a batch normalization layer, a leaky ReLU activation layer, a 3×3 convolutional layer, a batch normalization layer, a leaky ReLU activation layer and a 3×3 convolutional layer connected in sequence.

8. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The pixel rearrangement module includes a 3×3 convolutional layer, a batch normalization layer, a Leaky ReLU activation layer, a pixel rearrangement layer and a 3×3 convolutional layer connected in sequence.

9. The roof area calculation method based on reverse pixel rearrangement according to claim 1, characterized in that: The calculating the roof area based on the roof segmentation mask image includes: The pixel values ​​in the roof segmentation mask image represent the probability that the corresponding position is a roof. Based on a preset probability threshold, the roof segmentation mask image is binarized to obtain a roof segmentation image; The area of ​​the feature represented by each pixel is obtained based on the spatial resolution of the remote sensing image. The number of pixels determined to be roofs in the roof segmentation map is multiplied by the area of ​​the feature represented by each pixel to obtain the roof area.

10. A roof area calculation device based on reverse pixel rearrangement, characterized in that: include: The remote sensing image acquisition module is configured to: acquire remote sensing images of the target area and perform preprocessing; The roof segmentation module is configured to: input the pre-processed remote sensing image into the trained image segmentation model to obtain a roof segmentation mask map; a roof area calculation module, configured to: calculate the roof area based on the roof segmentation mask image; Among them, the image segmentation model includes a reverse pixel rearrangement module, a downsampling module, three upsampling modules based on bilinear interpolation, a splicing module, a multi-layer perceptron module and a pixel rearrangement module. The reverse pixel rearrangement module rearranges the preset size pixel block in the preprocessed remote sensing image into one pixel, and at the same time increases the number of channels corresponding to the pixel to the preset number of channels, polls all pixels until all pixels are rearranged, and the reverse pixel rearrangement module is connected to the downsampling module. The downsampling module includes three layers of sub-modules connected in sequence, each layer of sub-modules performs downsampling once, and one layer of sub-module generates a feature map and outputs it to an upsampling module based on bilinear interpolation. The splicing module splices the feature maps output by the three upsampling modules based on bilinear interpolation to obtain a spliced ​​feature map and outputs it to the multi-layer perceptron module. The multi-layer perceptron module is connected to the pixel rearrangement module. The multi-layer perceptron module performs nonlinear transformation and category prediction on the spliced ​​feature map to obtain a roof type prediction map. The pixel rearrangement module performs pixel rearrangement and mapping on the roof type prediction map to obtain a roof segmentation mask map.