Image processing using Python, GDAL and Scikit-Image

المشرف العام

Administrator
طاقم الإدارة
I'm new here and I'm sorry if I do something wrong.

I am struggling with a processing and hopefully I will be able to solve here.

I work with Remote Sensing applied to Forestry, especially working with LiDAR data.The idea is to use Scikit-image for tree top detection. Since I'm new in Python, I considered a great personal triumph to do the following:

  1. Import a CHM (with matplotlib);
  2. Run a gaussian filter (with scikit-image package);
  3. Run a maxima filter (with scikit-image package);
  4. Run the peak_local_max (with scikit-image package);
  5. Show the CHM with the local maxima (with matplotlib);
Now my problem. When I import with matplot, the image loses its geographic coordinates. So the coordinates I have are just basic image coordinates (i. e. 250,312). What I need is to get the value of the pixel under the local maxima dot in the image (red dots in the image). Here in the forum I saw one guy asking the same thing (How do I get the pixel value of a GDAL raster under an OGR point without NumPy?), but he already had the points in a shape file. In my case the points were computed with scikit-image (It is an array with the coordinates of each tree top). So I do not have the shape file.

In conclusion, what I want in the end is a txt file with the coordinates of each local maxima in geographic coordinates, for example:

525412 62980123 1150...



Thanks a lot for your attention.



أكثر...
 
أعلى