Page 1 of 1

geo-coding problem

Posted: Sat Apr 22, 2017 10:36 am America/New_York
by davilal
Hello
I would like to know how to change the Geo-Coding Info of an image using SeaDas. I have an image which show longitudes in the range of 0-360 degree and it has 180 degrees as the center meridian. However, I need to change this range to -180 - +180 longitude with 0 degree as the center longitude.
Thanks!

geo-coding problem

Posted: Sun Apr 23, 2017 10:11 am America/New_York
by gnwiii
Chances are this is more involved than just a change in Geo-Coding.   Depending on the actual organization of the data, you may need to  rewrite the data arrays.  A common case is a data array with 360 columns for longitudes 0--359 and 180 rows for latitudes -90--89.  To get longitudes -180--179 you have to move the rightmost 180 columns to the left of the array.  You can do this with any matrix language (matlab, IDL, python, R, etc.) that can load the image. If the file format is supported by gdal, you can use a Virtual Raster Table (VRT) by usiing the first 180 colums as the second source raster and the second 180 columns as a the first source raster, then using gal_translate with the .vrt file to write a geolocated file with the reorganized data.  See How to reproject raster from 0 -- 360 to -180 -- 180.  One limitation of the GDAL VRT approach is that gdal versions supplied by linux distros are often outdated and omit support for some important formats, so you may need to install gdal from a 3rd party package (or build from source, which can be a bit challenging).

geo-coding problem

Posted: Mon Apr 24, 2017 7:07 am America/New_York
by OB SeaDAS - knowles
A way of doing this on a file within the SeaDAS GUI is to detach the current geo-coding and attach a new one.

Steps:
1. Menu: Raster -> MathBand (Create a new band with for example expression = "LON - 180")
2. Menu:Tools -> Geo-Coding Detach (if needed)
3. Menu:Tools -> Geo-Coding Attach (Select your new longitude band for longitude and the current latitude band for latitude).

Danny