I have collection of images of synoptic weather charts downloaded from Bureau of Meteorology (BoM) which is in GIF format. I'm interested in obtaining the lat lon coordinates of cold fronts (thick black lines with triangles). My idea is: First get the pixel coordinates of the cold fronts. After obtaining the pixel coordinates, get the lat lon coordinates based on map projection type. BoM website mentions that the map projection type is Lambert Conformal Conic (LCC) projection. How can I speed up obtaining the pixel coordinates? And how to get the exact lat lon coordinates?

First, I approached extracting pixel coordinates in two ways:

Manual:- Obtain the pixel coordinates using the ginput function of MATLAB where with the help of mouse cursor I got the pixel coordinates. Image processing:- Converted the image into Binary and used edge and boundary detection. But in some cases this is not working properly.

img = imread('IDX0102.201501010000.gif');
binaryImage = imbinarize(img, 'adaptive');
edgeImage = edge(binaryImage, 'Canny');
BW2 = bwareaopen(img,3000);
contourData = bwboundaries(edgeImage);

For obtaining lat lon coordinates based on LCC, I tried in MATLAB using pix2latlon function and also in python using the pyproj. None of them gives the expected results. How do I approach this problem?

  • 1
    $\begingroup$ Interesting stuff. I'd think you have to work out if it's getting the pixel wrong, or converting that pixel to projection wrong. One issue with various tools is that some flip lat/lon or x/y, so perhaps the wrong order. But I'd suggest to narrow down if the pixel seems correct (can put the image into a program like Gimp and get the pixel location from the cursor in X, Y on screen easily to verify). Then give more details on what types of answers it's giving or such. $\endgroup$ Commented Nov 1, 2023 at 10:04
  • $\begingroup$ I hope you'll give results if/when you finally get there, as it sounds neat :) $\endgroup$ Commented Nov 1, 2023 at 10:05
  • $\begingroup$ Also LCC is not a single projection but a family of projections parameterized by central meridian and a pair of standard parallels. While central meridian here is clearly 130E, the standard parallels would require some guessing to figure out. $\endgroup$ Commented Nov 3, 2023 at 14:28

1 Answer 1


This is what I have done: First, using the parameters for LCC projection I did a coordinate transformation on the weather charts using QGIS. For this the charts needs to be georeferenced first based on lat-lon values of grid intersection. After transforming the charts in LCC to rectilinear grid I implemented "detectMSERFeatures", a computer vision tool in MATLAB, to identify the desired pixel. The pixels have one-to-one relationship with lat-lon using which I was able to get the desired feature's coordinates.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.