1. Image files
Images:
amsre_200301v3 Description
Download image
(1 MB)
Useful information:
Image data: A grid of pixels
Image data with more than one band
Image file types supported by Bilko
Numerical data formats
Byte swapping
El Nino
|
You will now learn how to open image data that have been stored as a binary flat file. This is a common way of storing remote sensing data, and
more flexible than the picture formats such as GIF and BMP. It allows
- different numerical formats, not just 8-bit integers, and
- a large number of bands, not just one (GIF) or three (BMP).
Note:
In Windows operating system binary flat files are usually given the file extension bin.
Bilko (and Windows) needs this file extension to recognise the file as an image.
However, many binary files available on the Internet have other extensions, and some have none.
If you download such a file, you should rename it before opening it in Bilko.
Give it a name of the format filename.bin.
This has already been done with the file you will be opening here. If you have not already done so, please use the download link
on the sidebar to download the file amsre_200301v3 before continuing.
Binary flat files are selected for opening in the same way as any other image file:
-
Use the toolbar icon or keystrokes [CTRL+O] to load the Open dialog
-
make sure the Extract box is checked and that the file type is set to Images
-
Select the file called amsre_200301v3.bin and press OK. This
will bring up the Open As flat file dialog
figure
(6K)).
File organisation and the 'Open As flat file' dialog
The dialog appears because you are trying to open data that contains no information about how the file is organised
- at least not in a format that Bilko can read. You must therefore supply the information required to divide the data into a recognizable grid of pixels.
Activity:
To see how important this information is you could start by just accept the default provided by the software and see what happens . . .
. . . Not much of an image was it? Bilko clearly needs some information from you, so close the scrambled image and start again.
The flexibility of the flat file data format means it is virtually impossible to guess how the image pixels have been organised,
or how much (if any) extra information has been included in the file. You need to know this beforehand,
and enter the information in the Open As flat file dialog.
When reading the file Bilko skips the header.
In this file there is no extra header information, so the header length is 0 bytes.
To be displayed on your screen the image data must be split into rows and columns.
For this Bilko needs to know
- the number of pixels per line - in this case 1440, and
- the number of lines - in this case 720.
Image data may contain different numerical formats (see left sidebar). In this file the
pixel format is 8-bit unsigned integer.
Question 1.
Use the arrow in the pixel format box to see the alternatives, and consult the sidebar pop-up on
numerical data formats for
more information. Which format would be used to store the following ranges of data?
a) 3 to 156
b) -2345 to 4565
c) -1.35980 to 1000.56575
d) 1.1 to 25.2
The data is not byte-swapped so leave the swap bytes box unchecked.
Note: If you are curious about this the sidebar pop-up on
byte swapping
explains why it may sometimes be necessary to check this box.
Flat files may contain many bands. Bilko needs to know
- the total number of bands in the file - in this case 5 ,
- the number of the first band to open - make this 1 , and
- the number of the last band to open - make this 3 .
Finally you must select the correct interleave format so that the
software knows how the bands are stored and can read the bytes that make up the image grid in
the right sequence. There are three options; the AMSRE file is stored in BSQ - band sequential format.
Note:
The different ways of storing image data with multiple bands are explained in the sidebar pop-up on
image data with more than one band
Having given Bilko all the necessary information, you can now click OK (or press
[Enter] .
In this image the pixel size is 0.25 of a degree Lat/Long. To open an image of a comparable size to the two ATSR images,
select a sample rate of 2,2 in the Extract dialog, and click OK to open the image.
You will have to do this three times - once of each of the bands you are opening.
The Reflect function
The images you have just opened will appear upside down. This is not uncommon.
For various reasons to do with how images are recorded, transmitted and stored,
and with differences between PCs and other computers,
you may sometimes find that an image is mirrored in some way:
-
West and East (left/right) are swapped; the image is reflected in X.
-
North and South (up/down) are swapped; the image is reflected in Y.
-
Upside down and left-right swapped; the image is reflected in X and Y.
Question 2.
Which of the three options describes the way this image is reflected?
You can adjust this by using
the Reflect function in the View menu. Use your answer to question 2
to decide what reflect option to chose (see figure
(3K)). You will need to do this for each of the images in turn.
Later in the tutorial we will be looking at two of these images again, the temperature (#1) and the atmospheric water vapour (#3), so leave these open for the time
being. However, you can close the windspeed band (#2).
Selecting and saving a specified region
You may have noticed that the global AMSRE images uses a different map window from the ATSR images.
The Y-dimension (latitude) is the same, but the X-dimension (longitude) is centered on the Dateline (180°),
not the Meridian (0°). You need to take this difference into account when using the 'Go To' dialog
to select the same equatorial Pacific area you selected earlier.
Question 3
|
a) |
What Y-coordinate represents the longitude of 180°W in the AMSRE images?.
|
b) |
In the AMSRE images, what pixel coordinates correspond to [x,y] = [40,120] in the ATSR images?
|
c) |
What Position coordinates [x,y] and size [DX,DY] would you use to select the same area of the equatorial
Pacific as previously done for the ATSR images?
|
|
Answers:
(Resizable pop-ups)
Answer 1
Answer 2
Answer 3
Back up to:
Q1
Q2
|
-
Activate the AMSRE #1 (SST) by clicking on it
-
Open the Go To dialog, fill it in as indicated by your answers to
question 2 (remember - box selection), and accept these settings.
-
Copy the selection onto the clipboard ( [CTRL+C] ) and use it to open ( [CTRL+N])
a new image.
-
Save the new image [CTRL+S] ) accepting the default file type but change the file name
slightly by replacing #1 with the letters SST.
-
Activate the #3 (water vapour) image and repeat 2-4 above, replacing #3 in the file name with the letters
WV.
Before you continue, save the two full globe AMSRE images (changing the file name to replace #1 with SST, and #3 with WV).
Close these images, leaving the four
equatorial Pacific and the full world ATSR image from January 1997 still open. Minimize these by clicking on the icon
on the title bar of each image.
|