CN103093413B - A kind of remote sensing image data write and the method and apparatus read - Google Patents

A kind of remote sensing image data write and the method and apparatus read Download PDF

Info

Publication number
CN103093413B
CN103093413B CN201310013116.4A CN201310013116A CN103093413B CN 103093413 B CN103093413 B CN 103093413B CN 201310013116 A CN201310013116 A CN 201310013116A CN 103093413 B CN103093413 B CN 103093413B
Authority
CN
China
Prior art keywords
fixed block
image data
remote sensing
sensing image
pixel unit
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.)
Active
Application number
CN201310013116.4A
Other languages
Chinese (zh)
Other versions
CN103093413A (en
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.)
Beijing Datum Science & Technology Development Co Ltd
Original Assignee
Beijing Datum Science & Technology Development Co Ltd
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 Beijing Datum Science & Technology Development Co Ltd filed Critical Beijing Datum Science & Technology Development Co Ltd
Priority to CN201310013116.4A priority Critical patent/CN103093413B/en
Publication of CN103093413A publication Critical patent/CN103093413A/en
Application granted granted Critical
Publication of CN103093413B publication Critical patent/CN103093413B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The method and apparatus that the invention provides the write of a kind of remote sensing image data and read, wherein, the method for said write comprises: obtain original remote sensing image data; By presetting size to described original remote sensing image Data Placement fixed block; Obtain the value of the color component of pixel unit in described fixed block; Adopt 1 value recording the color component of pixel unit in described fixed block, and distribute the first mark for described fixed block; Adopt 2 values recording the color component of pixel unit in described fixed block, and distribute the second mark for described fixed block; Adopt 4 values recording the color component of pixel unit in described fixed block, and distribute the 3rd mark for described fixed block; Adopt 8 values recording the color component of pixel unit in described fixed block, and distribute the 4th mark for described fixed block; The present invention can reduce remote sensing image data use cost, saves the storage space of raster data, improves transmission and the treatment effeciency of raster data.

Description

A kind of remote sensing image data write and the method and apparatus read
Technical field
The present invention relates to field of space technology, the method and apparatus particularly relating to the write of a kind of remote sensing image data and read.
Background technology
Remote sensing image be a kind of there is high power capacity, information carrier that high reliability, acquisition facilitate the feature such as timely, all play irreplaceable effect at traffic administration, the reallocation of land, military affairs, resource, environment and a lot of field such as to take precautions against natural calamities.The development of the continuous expansion in remote sensing application field and satellite technology, sensor technology, people can obtain rapidly the high-resolution remote sensing image of captured in real-time, make the information of acquisition more in time, accurately, one of consequent spinoff is that the data volume of remote sensing image is very large and increase with geometric ways, often reaches TB magnitude even PB magnitude in the application.As time goes on, the data volume of remote sensing image also will increase continuously and healthily.
Therefore, one of problem that those skilled in the art are in the urgent need to address is, a kind of method and apparatus is proposed, can effectively store and use the remote sensing image data of magnanimity, reduce remote sensing image data use cost, when carrying out raster data backup, information that can be same with less Resource Storage, take full advantage of storage space, improve transmission and the treatment effeciency of raster data.
Summary of the invention
The method and apparatus that technical matters to be solved by this invention is to provide the write of a kind of remote sensing image data and reads, can effectively store and use the remote sensing image data of magnanimity, reduce remote sensing image data use cost, save the storage space of raster data, improve transmission and the treatment effeciency of raster data.
In order to solve the problem, the invention discloses the method for a kind of remote sensing image data write, described original remote sensing image data comprise M*N pixel unit, and described M is row, and N is row; Wherein, described pixel unit comprises K color component, and described K is greater than 1, and described method comprises:
Step 101, obtains original remote sensing image data;
Step 102, by presetting size to described original remote sensing image Data Placement fixed block;
Step 103, obtains the value of the color component of pixel unit in described fixed block;
Step 104, whether what judge the value of described color component is all less than the first predetermined threshold value; If then perform step 105, if not, then step 106 is performed;
Step 105, adopts 1 value recording the color component of pixel unit in described fixed block, and distributes the first mark for described fixed block;
Step 106, whether what judge the value of described color component is all less than the second predetermined threshold value; If then perform step 107, if not, then step 108 is performed; Wherein, described second predetermined threshold value is greater than described first predetermined threshold value;
Step 107, adopts 2 values recording the color component of pixel unit in described fixed block, and distributes the second mark for described fixed block;
Step 108, whether what judge the value of described color component is all less than the 3rd predetermined threshold value; If then perform step 109, if not, then step 110 is performed; Wherein, described 3rd predetermined threshold value is greater than described second predetermined threshold value;
Step 109, adopts 4 values recording the color component of pixel unit in described fixed block, and distributes the 3rd mark for described fixed block;
Step 110, adopts 8 values recording the color component of pixel unit in described fixed block, and distributes the 4th mark for described fixed block;
Step 111, judges whether to have traveled through described original remote sensing image data, if so, then performs step 112, if not, then returns step 103;
Step 112, by described first mark, the second mark, the 3rd mark and the 4th mark are organized as memory length information according to the order of sequence;
The value of the color component of pixel unit in described fixed block and memory length Information Organization are target remote sensing image data by step 113.
Preferably, the size of described fixed block is a*b pixel unit, and described a is row, and b is row; Described step 102 comprises:
As the aliquant a of M, then the line number of supplementing corresponding pixel unit makes M aliquot a;
As the aliquant b of N, then the columns supplementing corresponding pixel unit makes N aliquot b.
Preferably, the color component of described pixel unit comprises R, G, B tri-color components.
Preferably, described method also comprises:
Write the essential information of described remote sensing image data, the essential information of described remote sensing image data comprises the size of fixed block.
The embodiment of the invention also discloses a kind of method that remote sensing image data reads, described remote sensing image data file comprises essential information, the value of the color component of pixel unit in memory length information and fixed block; Wherein, described essential information comprises the size of fixed block, and described memory length information comprises the first mark, the second mark, the 3rd mark and the 4th mark; Described method comprises:
Step 201, reads target remote sensing image data;
Step 202, obtains the size of described memory length information and described fixed block;
Step 203, reads described memory length information successively, judges that described memory length information is the first mark, the second mark, the 3rd mark or the 4th mark; If the first mark, then perform step 204; If the second mark, then perform step 205; If the 3rd mark, then perform step 206; If the 4th mark, then perform step 207;
Step 204, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 1 record in described fixed block successively from target remote sensing image data;
Step 205, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 2 records in described fixed block successively from target remote sensing image data;
Step 206, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 4 records in described fixed block successively from target remote sensing image data;
Step 207, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 8 records in described fixed block successively from target remote sensing image data;
Step 208, judges whether to have traveled through described target remote sensing image data, if so, then performs step 209, if not, then returns step 202;
Step 209, is organized as original remote sensing image data according to the order of sequence by the value of the color component of pixel unit in described fixed block.
The embodiment of the invention also discloses the device of a kind of remote sensing image data write, described original remote sensing image data comprise M*N pixel unit, and described M is row, and N is row; Wherein, described pixel unit comprises K color component, and described K is greater than 1, and described device comprises:
Remote sensing image data acquisition module, for obtaining original remote sensing image data;
Remote sensing image data divides module, presets size to described original remote sensing image Data Placement fixed block for pressing;
Numerical value acquisition module, for obtaining the value of the color component of pixel unit in described fixed block;
Whether the first judge module, be all less than the first predetermined threshold value for what judge the value of described color component; If then call the first logging modle, if not, then the second judge module is called;
First logging modle, for adopting 1 value recording the color component of pixel unit in described fixed block, and distributes the first mark for described fixed block;
Whether the second judge module, be all less than the second predetermined threshold value for what judge the value of described color component; If then call the second logging modle, if not, then the 3rd judge module is called; Wherein, described second predetermined threshold value is greater than described first predetermined threshold value;
Second logging modle, for adopting 2 values recording the color component of pixel unit in described fixed block, and distributes the second mark for described fixed block;
Whether the 3rd judge module, be all less than the 3rd predetermined threshold value for what judge the value of described color component; If then call the 3rd logging modle, if not, then the 4th logging modle is called; Wherein, described 3rd predetermined threshold value is greater than described second predetermined threshold value;
3rd logging modle, for adopting 4 values recording the color component of pixel unit in described fixed block, and distributes the 3rd mark for described fixed block;
4th logging modle, for adopting 8 values recording the color component of pixel unit in described fixed block, and distributes the 4th mark for described fixed block;
Ergodic judgement module, having traveled through described original remote sensing image data for judging whether, if so, then having called length information memory module, if not, then called numerical value acquisition module;
Length information memory module, for identifying described first, the second mark, the 3rd mark and the 4th mark are organized as memory length information according to the order of sequence;
Molded tissue block, for being target remote sensing image data by the value of the color component of pixel unit in described fixed block and memory length Information Organization.
Preferably, the size of described fixed block is a*b pixel unit, and described a is row, and b is row; Described remote sensing image data divides module and comprises:
First supplements submodule, and for as the aliquant a of M, then the line number of supplementary corresponding pixel unit makes M aliquot a;
Second supplements submodule, and for as the aliquant b of N, then the columns of supplementary corresponding pixel unit makes N aliquot b.
Preferably, the color component of described pixel unit comprises R, G, B tri-color components.
Preferably, described device also comprises:
Essential information writing module, for writing the essential information of described remote sensing image data, the essential information of described remote sensing image data comprises the size of fixed block.
The embodiment of the invention also discloses the device that a kind of remote sensing image data reads, described remote sensing image data file comprises essential information, the value of the color component of pixel unit in memory length information and fixed block; Wherein, described essential information comprises the size of fixed block, and described memory length information comprises the first mark, the second mark, the 3rd mark and the 4th mark; Described device comprises:
Remote sensing image data read module, for reading target remote sensing image data;
Data obtaining module, for obtaining the size of described memory length information and described fixed block;
Length information judge module, for reading described memory length information successively, judges that described memory length information is the first mark, the second mark, the 3rd mark or the 4th mark; If the first mark, then call the first extraction module; If the second mark, then call the second extraction module; If the 3rd mark, then call the 3rd extraction module; If the 4th mark, then call the 4th extraction module;
First extraction module, extracts the value of the color component of the pixel unit adopting 1 record in described fixed block successively from target remote sensing image data for the size according to described fixed block;
Second extraction module, extracts the value of the color component of the pixel unit adopting 2 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
3rd extraction module, extracts the value of the color component of the pixel unit adopting 4 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
4th extraction module, extracts the value of the color component of the pixel unit adopting 8 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
Ergodic judgement module, having traveled through described target remote sensing image data for judging whether, if so, then having called molded tissue block, if not, then returned recalls information acquisition module;
Molded tissue block, for being organized as original remote sensing image data according to the order of sequence by the value of the color component of pixel unit in described fixed block.
Compared with prior art, the present invention includes following advantage:
Do not take to fix 8 modes to the value of the color component in pixel unit in remote sensing image data in the present invention, and the pixel block of several fixed sizes threshold range according to its color component is stored by 8-4-2-1 position variable-length respectively, and record the memory length information that fixed block uses, can effectively store and use the remote sensing image data of magnanimity, reduce remote sensing image data use cost, when carrying out raster data backup, information that can be same with less Resource Storage, take full advantage of storage space, improve transmission and the treatment effeciency of raster data.
Accompanying drawing explanation
Fig. 1 is the embodiment flow chart of steps of the method for a kind of remote sensing image data write of the present invention;
Fig. 2 is that a kind of remote sensing image data fixed block of the present invention divides schematic diagram;
Fig. 3 is the embodiment flow chart of steps of the method that a kind of remote sensing image data of the present invention reads;
Fig. 4 is the schematic diagram of the part remote sensing image data in a kind of a certain area of the present invention;
Fig. 5 is the example structure block diagram of the device of a kind of remote sensing image data write of the present invention;
Fig. 6 is the example structure block diagram of the device that a kind of remote sensing image data of the present invention reads.
Embodiment
For enabling above-mentioned purpose of the present invention, feature and advantage become apparent more, and below in conjunction with the drawings and specific embodiments, the present invention is further detailed explanation.
One of core idea of the embodiment of the present invention is, do not take to fix 8 modes to pixel unit color component data in remote sensing image data, and the fixed block of several fixed sizes threshold range according to its color component is stored by 8-4-2-1 position variable-length respectively, and record the memory length information that fixed block uses, can effectively store and use the remote sensing image data of magnanimity, reduce remote sensing image data use cost, save the storage space of raster data, improve transmission and the treatment effeciency of raster data.
With reference to Fig. 1, show the embodiment flow chart of steps of the method for a kind of remote sensing image data write of the present invention, described original remote sensing image data can comprise M*N pixel unit, and described M is row, and N is row; Wherein, described pixel unit comprises K color component, and described K is greater than 1, and described method specifically can comprise the steps:
Step 101, obtains original remote sensing image data;
Wherein, remote sensing image data mainly refers to airphoto and satellite photograph, the wave band quantity that different remote sensing image data products comprises is different, in embodiments of the present invention with prevailing 3 wave band R, G, the remote sensing image data of B colour is that example carries out principle explanation, and other multiwave disposal route principles are the same to the handling principle of this 3 wave band data with the embodiment of the present invention, can use the method for same process.
Step 102, by presetting size to described original remote sensing image Data Placement fixed block;
In one preferred embodiment of the invention, the size of described fixed block can be a*b pixel unit, and described a is row, and b is row; Described step 102 can comprise following sub-step:
Sub-step S11, as the aliquant a of M, then the line number of supplementing corresponding pixel unit makes M aliquot a;
Sub-step S12, as the aliquant b of N, then the columns supplementing corresponding pixel unit makes N aliquot b.
With reference to Fig. 2, be depicted as a kind of remote sensing image data fixed block of the present invention and divide schematic diagram, suppose that original remote sensing image data are made up of M*N pixel unit, choosing fixed block size is a*b pixel unit, remote sensing image data is divided into [M/a] * [N/b] individual fixed block.Wherein, if M/a is not integer, then supplement row pixel unit and make M divide exactly a, the value (r, g, b) of supplementary each pixel unit color component is (0,0,0); If N/b is not integer, then supplements row pixel unit and make N divide exactly b, the value (r of supplementary each pixel unit color component, g, b) be (0,0,0), after the complete fixed block of original remote sensing image Data Placement, s*t fixed block can be obtained.
Step 103, obtains the value of the color component of pixel unit in described fixed block;
In one preferred embodiment of the invention, the color component of described pixel unit can comprise R, G, B tri-color components.
In embodiments of the present invention, take wave band as RGB remote sensing image data be example, its every pixel unit comprises 3 wave bands, be respectively R wave band, G-band, B wave band, each wave band can with one between 0 to 255 a round values represent, namely also each pixel unit needs to express its colouring information with 3 round values r, g and b.At present, in computer systems, which, traditional way stores by 81 bytes respectively color component r, g and b of each pixel unit.
Step 104, whether what judge the value of described color component is all less than the first predetermined threshold value; If then perform step 105, if not, then step 106 is performed;
Step 105, adopts 1 value recording the color component of pixel unit in described fixed block, and distributes the first mark for described fixed block;
If the value of the color component of pixel unit is all less than the first predetermined threshold value in fixed block, then to value 1 record of the color component of pixel unit in this fixed block, and distribute the first mark and show the method that this fixed block stores.
Step 106, whether what judge the value of described color component is all less than the second predetermined threshold value; If then perform step 107, if not, then step 108 is performed; Wherein, described second predetermined threshold value is greater than described first predetermined threshold value;
Step 107, adopts 2 values recording the color component of pixel unit in described fixed block, and distributes the second mark for described fixed block;
If the value of the color component of pixel unit is all less than the second predetermined threshold value in fixed block, then to value 2 records of the color component of pixel unit in this fixed block, and distribute the second mark and show the method that this fixed block stores.
Step 108, whether what judge the value of described color component is all less than the 3rd predetermined threshold value; If then perform step 109, if not, then step 110 is performed; Wherein, described 3rd predetermined threshold value is greater than described second predetermined threshold value;
Step 109, adopts 4 values recording the color component of pixel unit in described fixed block, and distributes the 3rd mark for described fixed block;
If the value of the color component of pixel unit is all less than the 3rd predetermined threshold value in fixed block, then to value 4 records of the color component of pixel unit in this fixed block, and distribute the 3rd mark and show the method that this fixed block stores.
Step 110, adopts 8 values recording the color component of pixel unit in described fixed block, and distributes the 4th mark for described fixed block;
If the value of the color component of pixel unit is all less than the 4th predetermined threshold value in fixed block, then to value 8 records of the color component of pixel unit in this fixed block, and distribute the 4th mark and show the method that this fixed block stores.
The application embodiment of the present invention, for any one fixed block i (1 <=i <=s*t) dividing s*t the fixed block obtained according to fixed block size, it includes a*b pixel unit.Read out this a*b pixel unit correspondence and carry out inventory analysis:
1) if the color component value r of pixel unit correspondence all in fixed block (a*b), g, b is 0 or 1, the value of each color component that each pixel unit then in this fixed block is corresponding can store with 1, every pixel unit needs the storage space of 3, and this fixed block then needs a*b*3 position to store; Specific implementation is that (or other storage mediums) distribute a*b*3 position storage space hereof, and the value of pixel unit color component in fixed block is write this space.
2) if do not meet 1) condition, then see the color component value r of pixel units (a*b) all in fixed block, g, whether b is less than 4, if, the value of each color component of each pixel unit then in this fixed block can store with 2, and every pixel unit needs the storage space of 6, and this fixed block needs a*b*6 position to store; If the value of the color component of pixel unit is not less than 4, then by 3) process.Specific implementation is that (or other storage mediums) carry out distribution a*b*6 position storage space hereof, and the value of pixel unit color component in fixed block is write this space.
3) if the value r of the color component of pixel unit all in fixed block (a*b), g, whether b is less than 16, the value of each color component of each pixel unit then in this fixed block stores with 4, every pixel unit needs 12 storage spaces, and this fixed block needs a*b*12 position to store; If the value of the color component of pixel unit is not less than 16, then by 4) process.Specific implementation is that (or other storage mediums) carry out distributing the storage space of a*b*12 position hereof, and the value of pixel unit color component in fixed block is write this space.
4) 16 are not less than for the value of the color component of pixel unit in fixed block, then the value of each color component of each pixel unit in this fixed block is stored with 8, every pixel unit needs 24 storage spaces, and this fixed block needs a*b*24 position to store; Specific implementation is that (or other storage mediums) carry out distributing the storage space of a*b*24 position hereof, and the value of pixel unit color component in fixed block is write this space.
Pass through previous step, after in order s*t fixed block being processed, just have recorded the value of color component in whole pixel units of remote sensing image in continuous one section of storage space in file (or other media), the master data of remote sensing image can be referred to as.
Step 111, judges whether to have traveled through described original remote sensing image data, if so, then performs step 112, if not, then returns step 103;
Step 112, by described first mark, the second mark, the 3rd mark and the 4th mark are organized as memory length information according to the order of sequence;
In specific implementation, record the satisfied conditional information of this fixed block to also needing via the fixed block i of memory allocated mode in said method.Recording method is as follows:
1, if this fixed block i meets above-mentioned 1) condition, namely to value 1 record of the color component of pixel unit in this fixed block, then can with 2 00 as the first mark, the value representing pixel unit in this fixed block adopts 1 to store;
2, if this fixed block i meets above-mentioned 2) condition, namely to value 2 records of the color component of pixel unit in this fixed block, then can with 2 01 as the second mark, the value representing pixel unit in this fixed block adopts 2 to store;
3, if this fixed block i meets above-mentioned 3) condition, namely to value 4 records of the color component of pixel unit in this fixed block, then can carry out the 3rd mark with 2 10, the value representing pixel unit in this fixed block adopts 4 to store;
4, if this fixed block i meets above-mentioned 4) condition, namely to value 8 records of the color component of pixel unit in this fixed block, then can record the 4th mark with 2 11, the value representing pixel unit in this fixed block adopts 8 to store.
After s*t " fixed block " being processed by above-mentioned method, be assigned with the storage space of s*t*2 position altogether, then in order the memory length information of this s*t fixed block stored.
The value of the color component of pixel unit in described fixed block and memory length Information Organization are target remote sensing image data by step 113.
In one preferred embodiment of the invention, described method can also comprise the steps:
Write the essential information of described remote sensing image data, the essential information of described remote sensing image data comprises the size of fixed block.
In addition, the essential information of remote sensing image data can also be stored, specifically can comprise the line number M of the pixel unit of remote sensing image data, columns N, the size a*b of fixed block, and other supplementarys.Essential information is generally preserve in write data file, can certainly be other storage mediums.
The application embodiment of the present invention, when the study area of remote sensing image comprises a large amount of water bodys, and water body represents through conventional black picture element unit.Numerical value (r so just containing a large amount of integrated distribution in remote sensing image data, g, b) be (0,0,0) pixel unit, if adopt traditional every pixel unit to need the 3*8 position i.e. storage space of 3 bytes, then take huge storage resources, adopt the 8-4-2-1 position dynamical fashion that the embodiment of the present invention proposes, then every pixel unit only needs the storage space of 3, has greatly saved storage space.For the pixel unit being not exclusively (0,0,0), but the value of pixel unit closely time, can store by the mode of 2 or 4, expand the conditioned disjunction occasion that can use less storage space like this.Only have and (0,0, the 0) pixel unit that error is larger, just store by traditional 8 modes.Meanwhile, the embodiment of the present invention is not limited to the remote sensing image data to 3 wave bands, can process equally the remote sensing image data of any wave band.
Preferably, can determine according to the remote sensing image data amount size of reality choosing of fixed block size a*b.For the remote sensing image data of magnanimity, recommendation is the fixed block of 256*256 or 512*512 size.The remote sensing image data backup of the embodiment of the present invention to magnanimity has great use value, adopts the method in the embodiment of the present invention, greatly can save storage space, decrease data management maintenance cost simultaneously.
With reference to Fig. 3, show the flow chart of steps of the embodiment of the method that a kind of remote sensing image data of the present invention reads, described remote sensing image data file comprises essential information, the value of the color component of pixel unit in memory length information and fixed block; Wherein, described essential information comprises the size of fixed block, and described memory length information comprises the first mark, the second mark, the 3rd mark and the 4th mark; Described method specifically can comprise the steps:
Step 201, reads target remote sensing image data;
Step 202, obtains the size of described memory length information and described fixed block;
In specific implementation, first read the essential information of the remote sensing image data of storage, comprise pixel unit line number M, pixel unit columns N, fixed block size a*b, can calculate the quantity s*t of the fixed block of division.
Step 203, reads described memory length information successively, judges that described memory length information is the first mark, the second mark, the 3rd mark or the 4th mark; If the first mark, then perform step 204; If the second mark, then perform step 205; If the 3rd mark, then perform step 206; If the 4th mark, then perform step 207;
Step 204, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 1 record in described fixed block successively from target remote sensing image data;
From the 1st fixed block, if its memory length information is 00, representing that the color component of pixel unit in this fixed block takies storage space is 3*a*b position, then read the front 3*a*b position of the master data of remote sensing image, be the value of the color component of all pixel units of this fixed block.
Step 205, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 2 records in described fixed block successively from target remote sensing image data;
If its memory length information of fixed block is 01, representing that the color component of pixel unit in this fixed block takies storage space is 6*a*b position, then read the front 6*a*b position of the master data of remote sensing image, be the value of the color component of all pixel units of this fixed block.
Step 206, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 4 records in described fixed block successively from target remote sensing image data;
If the memory length information of fixed block is 10, representing that the color component of pixel unit in this fixed block takies storage space is 12*a*b position, then read the front 12*a*b position of the master data of remote sensing image, be the value of the color component of all pixel units of this fixed block.
Step 207, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 8 records in described fixed block successively from target remote sensing image data;
If fixed block memory length information is 11, represent that these fixed block data take up room as 24*a*b position, then read the front 24*a*b position of the master data of remote sensing image, be the value of the color component of all pixel units of this fixed block.
Step 208, judges whether to have traveled through described target remote sensing image data, if so, then performs step 209, if not, then returns step 202;
After first fixed block reads, then read the memory length information of the 2nd fixed block, then from the master data of remote sensing image, take out the value of color component of corresponding pixel unit.In this approach, until obtain the value of color component in the pixel unit of all fixed blocks.
Step 209, is organized as original remote sensing image data according to the order of sequence by the value of the color component of pixel unit in described fixed block.
In order to make those skilled in the art understand the embodiment of the present invention further, illustrate below by a concrete example.
With reference to Fig. 4, be depicted as the schematic diagram of the part remote sensing image data in a kind of 1998 of the present invention a certain areas, this remote sensing image data resolution is 30 meters, and the size of pixel unit is 134724*161360.If adopt the value of the color component of traditional every pixel unit to distribute the mode of 8 storage spaces, remote sensing image data for RGB tri-wave band needs about 61GB altogether, adopt the embodiment of the present invention, use the fixed block that fixed block size is 256*256, namely s*t=527*631 fixed block is obtained. use file Base.rd to preserve the essential information of remote sensing image data, comprise the pixel unit line number M=134724 of remote sensing image data, columns N=161360, the size a=b=256 of fixed block.This remote sensing image data is divided by the carrying out that fixed block size is a=b=256, s*t=527*631 fixed block can be obtained.To each fixed block, read the value of the color component of its 256*256 pixel unit, then judge this fixed block the memory length condition that meets, and 2 bit data write Base.rd files of the memory length condition that representative is met, simultaneously, corresponding storage space is distributed (if 2 of this fixed block is 00 in the master data file Data.rd of remote sensing image, then distribute 3*256*256 position, if 2 of this fixed block is 10, then distribute 6*256*256 position ...), and each use of value 3 (or 6 or 12 or 24) of 256*256 pixel unit in this fixed block is written in Data.rd file (how the 3*256*256 bit data of concrete each fixed block stores, mode freely, the embodiment of the present invention is not done this and is not limited, such as, can be unit by 81 bytes by 3*256*256 position, from the beginning to the end, divide into groups, if last group is less than 8, then mend 0 and gather together enough into 81 bytes, then often group 81 bytes after this being divided into groups store.Also can be one group by 32, divide into groups to the 3*256*256 position of fixed block, last group mends 0 less than 32, and then often group stores etc. with the integer number of 4 bytes.)
After processing all fixed blocks, in Base.rd file, press fixed block sequential storage 2*s*t bit data.The value of the color component of the actual pixels unit of s*t=527*631 fixed block is then stored in master data file Data.rd file.Certainly, the storage space of each piece of this s*t=527*631 fixed block is now dynamic change, is not just the same size.After according to said method being stored by remote sensing image data, total storage space of Base.rd file and Data.rd file is about 38Gb, for originally storing 63% of requisite space.Such data carry out Internet Transmission, data backup, especially back up in multipoint data repetition situation, have greatly saved transmission volume or disk space, greatly saved hardware investment, have higher actual application value.
It should be noted that, for embodiment of the method, in order to simple description, therefore it is all expressed as a series of combination of actions, but those skilled in the art should know, the application is not by the restriction of described sequence of movement, because according to the application, some step can adopt other orders or carry out simultaneously.Secondly, those skilled in the art also should know, the embodiment described in instructions all belongs to preferred embodiment, and involved action might not be that the application is necessary.
With reference to Fig. 5, be depicted as the device example structure block diagram of a kind of remote sensing image data write of the present invention, described original remote sensing image data comprise M*N pixel unit, and described M is row, and N is row; Wherein, described pixel unit comprises K color component, and described K is greater than 1, and described device comprises:
Remote sensing image data acquisition module 301, for obtaining original remote sensing image data;
Remote sensing image data divides module 302, presets size to described original remote sensing image Data Placement fixed block for pressing;
In one preferred embodiment of the invention, the size of described fixed block can be a*b pixel unit, and described a is row, and b is row; Described remote sensing image data divides module 302 can comprise following submodule:
First supplements submodule, and for as the aliquant a of M, then the line number of supplementary corresponding pixel unit makes M aliquot a;
Second supplements submodule, and for as the aliquant b of N, then the columns of supplementary corresponding pixel unit makes N aliquot b.
Numerical value acquisition module 303, for obtaining the value of the color component of pixel unit in described fixed block;
In one preferred embodiment of the invention, the color component of described pixel unit can comprise R, G, B tri-color components.
Whether the first judge module 304, be all less than the first predetermined threshold value for what judge the value of described color component; If then call the first logging modle, if not, then the second judge module is called;
First logging modle 305, for adopting 1 value recording the color component of pixel unit in described fixed block, and distributes the first mark for described fixed block;
Whether the second judge module 306, be all less than the second predetermined threshold value for what judge the value of described color component; If then call the second logging modle, if not, then the 3rd judge module is called; Wherein, described second predetermined threshold value is greater than described first predetermined threshold value;
Second logging modle 307, for adopting 2 values recording the color component of pixel unit in described fixed block, and distributes the second mark for described fixed block;
Whether the 3rd judge module 308, be all less than the 3rd predetermined threshold value for what judge the value of described color component; If then call the 3rd logging modle, if not, then the 4th logging modle is called; Wherein, described 3rd predetermined threshold value is greater than described second predetermined threshold value;
3rd logging modle 309, for adopting 4 values recording the color component of pixel unit in described fixed block, and distributes the 3rd mark for described fixed block;
4th logging modle 310, for adopting 8 values recording the color component of pixel unit in described fixed block, and distributes the 4th mark for described fixed block;
Ergodic judgement module 311, having traveled through described original remote sensing image data for judging whether, if so, then having called length information memory module, if not, then called numerical value acquisition module;
Length information memory module 312, for identifying described first, the second mark, the 3rd mark and the 4th mark are organized as memory length information according to the order of sequence;
Molded tissue block 313, for being target remote sensing image data by the value of the color component of pixel unit in described fixed block and memory length Information Organization.
In one preferred embodiment of the invention, described device can also comprise as lower module:
Essential information writing module, for writing the essential information of described remote sensing image data, the essential information of described remote sensing image data comprises the size of fixed block.
For the device embodiment shown in Fig. 5, due to the embodiment of the method basic simlarity shown in itself and Fig. 1, so description is fairly simple, relevant part illustrates see the part of embodiment of the method.
With reference to Fig. 6, be depicted as the device example structure block diagram that a kind of remote sensing image data of the present invention reads, described remote sensing image data file comprises essential information, the value of the color component of pixel unit in memory length information and fixed block; Wherein, described essential information comprises the size of fixed block, and described memory length information comprises the first mark, the second mark, the 3rd mark and the 4th mark; Described device specifically can comprise as lower module:
Remote sensing image data read module 401, for reading target remote sensing image data;
Data obtaining module 402, for obtaining the size of described memory length information and described fixed block;
Length information judge module 403, for reading described memory length information successively, judges that described memory length information is the first mark, the second mark, the 3rd mark or the 4th mark; If the first mark, then call the first extraction module; If the second mark, then call the second extraction module; If the 3rd mark, then call the 3rd extraction module; If the 4th mark, then call the 4th extraction module;
First extraction module 404, extracts the value of the color component of the pixel unit adopting 1 record in described fixed block successively from target remote sensing image data for the size according to described fixed block;
Second extraction module 405, extracts the value of the color component of the pixel unit adopting 2 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
3rd extraction module 406, extracts the value of the color component of the pixel unit adopting 4 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
4th extraction module 407, extracts the value of the color component of the pixel unit adopting 8 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
Ergodic judgement module 408, having traveled through described target remote sensing image data for judging whether, if so, then having called molded tissue block, if not, then returned recalls information acquisition module;
Molded tissue block 409, for being organized as original remote sensing image data according to the order of sequence by the value of the color component of pixel unit in described fixed block.
For the device embodiment shown in Fig. 6, due to the embodiment of the method basic simlarity that itself and Fig. 3 show, so description is fairly simple, relevant part illustrates see the part of embodiment of the method.
Each embodiment in this instructions all adopts the mode of going forward one by one to describe, and what each embodiment stressed is the difference with other embodiments, between each embodiment identical similar part mutually see.
Those skilled in the art should understand, the embodiment of the application can be provided as method, device or computer program.Therefore, the application can adopt the form of complete hardware embodiment, completely software implementation or the embodiment in conjunction with software and hardware aspect.And the application can adopt in one or more form wherein including the upper computer program implemented of computer-usable storage medium (including but not limited to magnetic disk memory, CD-ROM, optical memory etc.) of computer usable program code.
The application describes with reference to according to the process flow diagram of the method for the embodiment of the present application, equipment (system) and computer program and/or block scheme.Should understand can by the combination of the flow process in each flow process in computer program instructions realization flow figure and/or block scheme and/or square frame and process flow diagram and/or block scheme and/or square frame.These computer program instructions can being provided to the processor of multi-purpose computer, special purpose computer, Embedded Processor or other programmable data processing device to produce a machine, making the instruction performed by the processor of computing machine or other programmable data processing device produce device for realizing the function of specifying in process flow diagram flow process or multiple flow process and/or block scheme square frame or multiple square frame.
These computer program instructions also can be stored in can in the computer-readable memory that works in a specific way of vectoring computer or other programmable data processing device, the instruction making to be stored in this computer-readable memory produces the manufacture comprising command device, and this command device realizes the function of specifying in process flow diagram flow process or multiple flow process and/or block scheme square frame or multiple square frame.
These computer program instructions also can be loaded in computing machine or other programmable data processing device, make on computing machine or other programmable devices, to perform sequence of operations step to produce computer implemented process, thus the instruction performed on computing machine or other programmable devices is provided for the step realizing the function of specifying in process flow diagram flow process or multiple flow process and/or block scheme square frame or multiple square frame.
Although described the preferred embodiment of the application, those skilled in the art once obtain the basic creative concept of cicada, then can make other change and amendment to these embodiments.So claims are intended to be interpreted as comprising preferred embodiment and falling into all changes and the amendment of the application's scope.
Finally, also it should be noted that, in this article, the such as relational terms of first and second grades and so on is only used for an entity or operation to separate with another entity or operational zone, and not necessarily requires or imply the relation that there is any this reality between these entities or operation or sequentially.And, term " comprises ", " comprising " or its any other variant are intended to contain comprising of nonexcludability, thus make to comprise the process of a series of key element, method, article or equipment and not only comprise those key elements, but also comprise other key elements clearly do not listed, or also comprise by the intrinsic key element of this process, method, article or equipment.When not more restrictions, the key element limited by statement " comprising ... ", and be not precluded within process, method, article or the equipment comprising described key element and also there is other identical element.
Above to the method and apparatus that a kind of remote sensing image data provided by the present invention writes and reads, be described in detail, apply specific case herein to set forth principle of the present invention and embodiment, the explanation of above embodiment just understands method of the present invention and core concept thereof for helping; Meanwhile, for one of ordinary skill in the art, according to thought of the present invention, all will change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.

Claims (10)

1. a method for remote sensing image data write, it is characterized in that, original remote sensing image data comprise M*N pixel unit, and described M is row, and N is row; Wherein, described pixel unit comprises K color component, and described K is greater than 1, and described method comprises:
Step 101, obtains original remote sensing image data;
Step 102, by presetting size to described original remote sensing image Data Placement fixed block;
Step 103, obtains the value of the color component of pixel unit in described fixed block;
Step 104, judges whether the value of described color component is all less than the first predetermined threshold value; If then perform step 105, if not, then step 106 is performed;
Step 105, adopts 1 value recording the color component of pixel unit in described fixed block, and distributes the first mark for described fixed block;
Step 106, judges whether the value of described color component is all less than the second predetermined threshold value; If then perform step 107, if not, then step 108 is performed; Wherein, described second predetermined threshold value is greater than described first predetermined threshold value;
Step 107, adopts 2 values recording the color component of pixel unit in described fixed block, and distributes the second mark for described fixed block;
Step 108, judges whether the value of described color component is all less than the 3rd predetermined threshold value; If then perform step 109, if not, then step 110 is performed; Wherein, described 3rd predetermined threshold value is greater than described second predetermined threshold value;
Step 109, adopts 4 values recording the color component of pixel unit in described fixed block, and distributes the 3rd mark for described fixed block;
Step 110, adopts 8 values recording the color component of pixel unit in described fixed block, and distributes the 4th mark for described fixed block;
Step 111, judges whether to have traveled through described original remote sensing image data, if so, then performs step 112, if not, then returns step 103;
Step 112, by described first mark, the second mark, the 3rd mark and the 4th mark are organized as memory length information according to the order of sequence;
The value of the color component of pixel unit in described fixed block and memory length Information Organization are target remote sensing image data by step 113.
2. method according to claim 1, is characterized in that, the size of described fixed block is a*b pixel unit, and described a is row, and b is row; Described step 102 comprises:
As the aliquant a of M, then the line number of supplementing corresponding pixel unit makes M aliquot a;
As the aliquant b of N, then the columns supplementing corresponding pixel unit makes N aliquot b.
3. method according to claim 1, is characterized in that, the color component of described pixel unit comprises R, G, B tri-color components.
4. method according to claim 1 and 2, is characterized in that, also comprises:
Write the essential information of described remote sensing image data, the essential information of described remote sensing image data comprises the size of fixed block.
5. the method that reads of remote sensing image data, it is characterized in that, remote sensing image data file comprises essential information, the value of the color component of pixel unit in memory length information and fixed block; Wherein, described essential information comprises the size of fixed block, and described memory length information comprises the first mark, the second mark, the 3rd mark and the 4th mark; Described method comprises:
Step 201, reads target remote sensing image data;
Step 202, obtains the size of described memory length information and described fixed block;
Step 203, reads described memory length information successively, judges that described memory length information is the first mark, the second mark, the 3rd mark or the 4th mark; If the first mark, then perform step 204; If the second mark, then perform step 205; If the 3rd mark, then perform step 206; If the 4th mark, then perform step 207;
Step 204, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 1 record in described fixed block successively from target remote sensing image data;
Step 205, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 2 records in described fixed block successively from target remote sensing image data;
Step 206, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 4 records in described fixed block successively from target remote sensing image data;
Step 207, the size according to described fixed block extracts the value of the color component of the pixel unit adopting 8 records in described fixed block successively from target remote sensing image data;
Step 208, judges whether to have traveled through described target remote sensing image data, if so, then performs step 209, if not, then returns step 202;
Step 209, is organized as original remote sensing image data according to the order of sequence by the value of the color component of pixel unit in described fixed block.
6. a device for remote sensing image data write, it is characterized in that, original remote sensing image data comprise M*N pixel unit, and described M is row, and N is row; Wherein, described pixel unit comprises K color component, and described K is greater than 1, and described device comprises:
Remote sensing image data acquisition module, for obtaining original remote sensing image data;
Remote sensing image data divides module, presets size to described original remote sensing image Data Placement fixed block for pressing;
Numerical value acquisition module, for obtaining the value of the color component of pixel unit in described fixed block;
First judge module, for judging whether the value of described color component is all less than the first predetermined threshold value; If then call the first logging modle, if not, then the second judge module is called;
First logging modle, for adopting 1 value recording the color component of pixel unit in described fixed block, and distributes the first mark for described fixed block;
Second judge module, for judging whether the value of described color component is all less than the second predetermined threshold value; If then call the second logging modle, if not, then the 3rd judge module is called; Wherein, described second predetermined threshold value is greater than described first predetermined threshold value;
Second logging modle, for adopting 2 values recording the color component of pixel unit in described fixed block, and distributes the second mark for described fixed block;
3rd judge module, for judging whether the value of described color component is all less than the 3rd predetermined threshold value; If then call the 3rd logging modle, if not, then the 4th logging modle is called; Wherein, described 3rd predetermined threshold value is greater than described second predetermined threshold value;
3rd logging modle, for adopting 4 values recording the color component of pixel unit in described fixed block, and distributes the 3rd mark for described fixed block;
4th logging modle, for adopting 8 values recording the color component of pixel unit in described fixed block, and distributes the 4th mark for described fixed block;
Ergodic judgement module, having traveled through described original remote sensing image data for judging whether, if so, then having called length information memory module, if not, then called numerical value acquisition module;
Length information memory module, for identifying described first, the second mark, the 3rd mark and the 4th mark are organized as memory length information according to the order of sequence;
Molded tissue block, for being target remote sensing image data by the value of the color component of pixel unit in described fixed block and memory length Information Organization.
7. device according to claim 6, is characterized in that, the size of described fixed block is a*b pixel unit, and described a is row, and b is row; Described remote sensing image data divides module and comprises:
First supplements submodule, and for as the aliquant a of M, then the line number of supplementary corresponding pixel unit makes M aliquot a;
Second supplements submodule, and for as the aliquant b of N, then the columns of supplementary corresponding pixel unit makes N aliquot b.
8. device according to claim 6, is characterized in that, the color component of described pixel unit comprises R, G, B tri-color components.
9. the device according to claim 6 or 7, is characterized in that, also comprises:
Essential information writing module, for writing the essential information of described remote sensing image data, the essential information of described remote sensing image data comprises the size of fixed block.
10. the device that reads of remote sensing image data, it is characterized in that, remote sensing image data file comprises essential information, the value of the color component of pixel unit in memory length information and fixed block; Wherein, described essential information comprises the size of fixed block, and described memory length information comprises the first mark, the second mark, the 3rd mark and the 4th mark; Described device comprises:
Remote sensing image data read module, for reading target remote sensing image data;
Data obtaining module, for obtaining the size of described memory length information and described fixed block;
Length information judge module, for reading described memory length information successively, judges that described memory length information is the first mark, the second mark, the 3rd mark or the 4th mark; If the first mark, then call the first extraction module; If the second mark, then call the second extraction module; If the 3rd mark, then call the 3rd extraction module; If the 4th mark, then call the 4th extraction module;
First extraction module, extracts the value of the color component of the pixel unit adopting 1 record in described fixed block successively from target remote sensing image data for the size according to described fixed block;
Second extraction module, extracts the value of the color component of the pixel unit adopting 2 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
3rd extraction module, extracts the value of the color component of the pixel unit adopting 4 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
4th extraction module, extracts the value of the color component of the pixel unit adopting 8 records in described fixed block successively from target remote sensing image data for the size according to described fixed block;
Ergodic judgement module, having traveled through described target remote sensing image data for judging whether, if so, then having called molded tissue block, if not, then returned recalls information acquisition module;
Molded tissue block, for being organized as original remote sensing image data according to the order of sequence by the value of the color component of pixel unit in described fixed block.
CN201310013116.4A 2013-01-14 2013-01-14 A kind of remote sensing image data write and the method and apparatus read Active CN103093413B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310013116.4A CN103093413B (en) 2013-01-14 2013-01-14 A kind of remote sensing image data write and the method and apparatus read

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310013116.4A CN103093413B (en) 2013-01-14 2013-01-14 A kind of remote sensing image data write and the method and apparatus read

Publications (2)

Publication Number Publication Date
CN103093413A CN103093413A (en) 2013-05-08
CN103093413B true CN103093413B (en) 2015-08-19

Family

ID=48205949

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310013116.4A Active CN103093413B (en) 2013-01-14 2013-01-14 A kind of remote sensing image data write and the method and apparatus read

Country Status (1)

Country Link
CN (1) CN103093413B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103763059B (en) * 2013-10-25 2017-05-10 中国科学院对地观测与数字地球科学中心 Remote-sensing satellite data quick-look substitution method
CN107992555B (en) * 2017-11-28 2021-08-24 鲁东大学 Method for storing and reading raster data
CN111125113B (en) * 2019-12-25 2020-09-15 中科三清科技有限公司 Method and device for storing air pollutant data
CN111405294B (en) * 2020-03-25 2022-02-15 鲁东大学 Storage and transmission method of image raster data

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1851692A (en) * 2005-08-05 2006-10-25 华为技术有限公司 Picture data storage and read method
CN101060629A (en) * 2007-04-27 2007-10-24 华为技术有限公司 Image compression/decompression method and image coder/decoder and decoding circuit
EP2530649A1 (en) * 2011-06-03 2012-12-05 BAE Systems Plc Sensor data processing

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3706408B2 (en) * 1995-04-20 2005-10-12 富士写真フイルム株式会社 Digital image data recording apparatus and method
JP2006076089A (en) * 2004-09-08 2006-03-23 Fuji Photo Film Co Ltd Light emitting device and fixing device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1851692A (en) * 2005-08-05 2006-10-25 华为技术有限公司 Picture data storage and read method
CN101060629A (en) * 2007-04-27 2007-10-24 华为技术有限公司 Image compression/decompression method and image coder/decoder and decoding circuit
EP2530649A1 (en) * 2011-06-03 2012-12-05 BAE Systems Plc Sensor data processing

Also Published As

Publication number Publication date
CN103093413A (en) 2013-05-08

Similar Documents

Publication Publication Date Title
CN100595758C (en) Storing method and system of playing map and obtaining method and system of playing map
CN103093413B (en) A kind of remote sensing image data write and the method and apparatus read
CN103995684A (en) Method and system for synchronously processing and displaying mass images under ultrahigh resolution platform
CN101916299B (en) Three-dimensional spatial data storage and management method based on file system
US20070067326A1 (en) Method of managing storage and retrieval of data objects
CN102301349A (en) Database operation-aware striping technique
CN101162441A (en) Access apparatus and method for data
CN104599324A (en) Map data loading method and map data loading device based on GIS (geographic information system) platform
CN104967807B (en) Caching method and apparatus
CN108491445A (en) The methods of exhibiting and system of achievement data in region
CN106101712B (en) A kind of processing method and processing device of video stream data
CN106354890A (en) Implementation method of random access file system based on N-ary tree structure
CN104407384A (en) Seismic section display method
CN105022788A (en) Lossless compression algorithm for bin file in PNG picture format and full liquid crystal instrument display system
CN100578542C (en) Graphic processing system and method for storing texture data in graphic processing system
CN103389413A (en) Real-time statistical method for frequency spectrum histogram
CN102663664B (en) Method for processing supersized texture images
CN110765298B (en) Tile coding method for decoupling geometric attributes of vector data
CN104881425A (en) WebGIS (geographic information system) map optimization based gradation loading method for tens of thousands of cameras
CN104111899A (en) Cache data storage method and system and cache data reading method
CN104320692A (en) Chip simultaneously supporting multi-window image display and display method
CN106873906A (en) Method and apparatus for managing metamessage
CN103886045A (en) Access method and device including local valid grid data
CN104715070A (en) Large image file as well as generation and read method thereof
CN102902491B (en) The method of remote sensing image data write and reading and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant