PointCloudLibrary / PointCloudLibrary/pcl

IntegralImageNormaEstimation could/should return signed curvature

Open
#2,289 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

good first issue kind: proposal kind: todo module: features
Dominant language
C++
Stars
11.1k
Forks
4.7k
Avg merge
4d 10h
Merged PRs (30d)
6

Description

Your Environment

  • Operating System and version: Ubuntu 18.04
  • Compiler: gcc 7.3
  • PCL Version: 1.8.1 & trunk

Context

IntegralImageNormalEstimation computes curvature of the surface when used with normal_estimation_method=COVARIANCE_MATRIX. It does not provide the information about the direction of curvature (towards the normal or away from it) as the sign is discarded - https://github.com/PointCloudLibrary/pcl/blob/9084aec8cdd4bc040f24193b5a767d8dfe153299/features/include/pcl/features/impl/integral_image_normal.hpp#L247 (note the fabsf). In my application (height map), this information is important for further processing (distinguising valleys from hills).

Expected Behavior

I am proposing to make the curvature optionally signed, by adding a flag (false by default, not to break existing code) which would keep curvature sign, plus take in account whether the normal was flipped (in that case, curvature would have to be negated to be consistent).

Current Behavior

Sign of curvature is currently discarded by the fabsf as explained above.

Possible Solution

I suggest I will do a PR to implement this, but I would like to have opinion/guidance from upstream as to whether the chane is mergeable or I better subclass IntegralImageNormalEstimation and keep using that one in my project. Thanks!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in features/include/pcl/features/impl/integral_image_normal.hpp at the fabsf call around line 247, where IntegralImageNormalEstimation computes curvature. Trace how the normal-estimation method and normal flipping are handled, then determine how an optional false-by-default flag can preserve existing behavior while retaining a consistent curvature sign. Done means the proposed behavior is implemented without changing default results and is verified for both normal orientations.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
computer-vision
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.