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

Las resolution tied to GSD #1788

Merged

Conversation

smathermather
Copy link
Contributor

No description provided.

@smathermather smathermather marked this pull request as ready for review August 8, 2024 01:10
las_scale = 0.001
filtered_point_cloud_stats = tree.path("odm_filterpoints", "point_cloud_stats.json")
if os.path.isfile(filtered_point_cloud_stats):
with open(filtered_point_cloud_stats, 'r') as stats:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Would place any file I/O operation inside a try//catch block.
  • We should check for a threshold before triggering a change in scale (currently this will change every time)
  • Spacing should be in 1/10 increments, not spacing / 10. E.g. 0.001, 0.0001, 0.00001, etc. not 0.35893904

It's a good start!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I addressed the first and the third in an update to the pull request. Sorry/not sorry for the function name. Probably doesn't need to be a function, but at least then it's somewhat clear what it's doing.

For the second one, I'm not sure what we are checking for. Do you mean on a rerun from an earlier stage or something else? I haven't profiled it, but relative to (waves hand at all the photogrammetry), I suspect this calculation is trivially inexpensive to recalculate if recalculation happens (I cannot detect the stage running slower than stock). But, as unsure I am what threshold we are checking for, I'm writing here largely from ignorance.

But, happy to address if I understand the concern. And thanks for the quick and thorough review!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should add, I have no idea if there's a stock function to do the log rounding. My googling on the issue was unproductive. It seems like it should be a common function type and have a common name, but it was easier to write than search for.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the second one it's fine, you currently do a call to min, which does that implicitly, I would have done an if threshold then ... but that's just me. The end result is equivalent. Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense. An if would be more explicit indeed.

@smathermather smathermather merged commit 946b39a into OpenDroneMap:master Aug 9, 2024
2 checks passed
@smathermather smathermather deleted the las_resolution_youll_ever_need branch August 9, 2024 02:14
@smathermather smathermather restored the las_resolution_youll_ever_need branch August 9, 2024 02:44
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

Successfully merging this pull request may close these issues.

2 participants