You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the RegionGrowingAlgorithm the parameter height_threshold is exposed but never considered during seed detection in find_seedpoints.
This leads to the detection of a lot of seeds with a low amount of height change. As a result, there are a lot of "unwanted" seeds, and, in some cases, large objects of low amount of change might prevent smaller objects with greater height change to grow, as the potential seed is already incorporated in the larger segment.
To fix this we can add an height_threshold check in line 945:
Changing:
# Check whether the volume started decreasing
if previous_volume > volume:
# Only add seed if larger than the minimum period
if target_idx - start_idx >= self.minperiod:
corepoint_seeds.append(
RegionGrowingSeed(i, start_idx, target_idx)
)
break
else:
previous_volume = volume
to:
# Check whether the volume started decreasing
if previous_volume > volume:
# Only add seed if larger than the minimum period and height of the change form larger than threshold
if (target_idx - start_idx >= self.minperiod) and (np.abs(np.max(used_timeseries) - np.min(used_timeseries)) >= self.height_threshold):
corepoint_seeds.append(
RegionGrowingSeed(i, start_idx, target_idx)
)
break
else:
previous_volume = volume
The text was updated successfully, but these errors were encountered:
hdaan
added a commit
to hdaan/py4dgeo
that referenced
this issue
Apr 3, 2024
In the
RegionGrowingAlgorithm
the parameterheight_threshold
is exposed but never considered during seed detection infind_seedpoints
.This leads to the detection of a lot of seeds with a low amount of height change. As a result, there are a lot of "unwanted" seeds, and, in some cases, large objects of low amount of change might prevent smaller objects with greater height change to grow, as the potential seed is already incorporated in the larger segment.
To fix this we can add an height_threshold check in line 945:
Changing:
to:
The text was updated successfully, but these errors were encountered: