Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

point2dem default grid size #173

Open
oleg-alexandrov opened this issue Sep 18, 2017 · 2 comments
Open

point2dem default grid size #173

oleg-alexandrov opened this issue Sep 18, 2017 · 2 comments

Comments

@oleg-alexandrov
Copy link
Member

There are two issues with the default point2dem grid:

  1. The current algorithm sets the grid size as the "typical" ground sample distance, that is, the estimated value of how far two camera pixels are when projected onto the ground. That is not right, a good rule of thumb is that the DEM resolution is about 4x this ground sample distance.

  2. Currently, this "typical" ground sample distance is obtained by taking the median of all estimated distances between two neighboring pixels on the ground. That usually works, but for LRO NAC and other linescan cameras, the ground sample distance in one direction and the other can be very different, e.g., 0.5 m along a scanline, and 2 m across scanlines. The median of a set of numbers some of which are 2 and some are 0.5 will be one of the two, while the correct solution here is more like 1 m. I think given the list of all GSD values encountered by poinit2dem, one should take the ones in the 25% to 75% range, and average them, rather than taking the median. This will avoid worst outliers and the final result in this example should be on the order of 1 m.

There is already some kind of logic like this for mapproject, maybe it can be factored out and used in both places.

@oleg-alexandrov
Copy link
Member Author

If this work is done, the manual page where we discuss the default point2dem grid size should be updated.

@oleg-alexandrov
Copy link
Member Author

point2dem also currently gives bad results close to poles if used with default options. It should switch to polar stereographic (unless the user explictely chooses a project) if say within 20 degree of a pole (the precise number is to be determined).

Also, a single outlier not filtered out by intersection error can result in huge DEMs mostly filled with empty space (or point2dem can crash running out of memory). A simple filtering based on percentiles (which we already use for triangulation error) but applied to each of projected_x, projected_y, height_above_datum coordinates of each point should be able to throw out points that are way out there compared to the distribution of most of the values. Currently exposed parameters can control this new outlier removal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant