Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
ftl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nicolas Pope
ftl
Commits
a25ec149
Commit
a25ec149
authored
4 years ago
by
Nicolas Pope
Browse files
Options
Downloads
Patches
Plain Diff
Correction to feature bug
parent
28867224
No related branches found
No related tags found
1 merge request
!358
Updates to SDK and alternative fusion
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
components/operators/src/fusion/smoothing/mls_multi_weighted.cu
+16
-2
16 additions, 2 deletions
...ents/operators/src/fusion/smoothing/mls_multi_weighted.cu
with
16 additions
and
2 deletions
components/operators/src/fusion/smoothing/mls_multi_weighted.cu
+
16
−
2
View file @
a25ec149
...
@@ -57,13 +57,27 @@ __device__ inline float featureWeight(int f1, int f2) {
...
@@ -57,13 +57,27 @@ __device__ inline float featureWeight(int f1, int f2) {
float3
X
=
camera_origin
.
screenToCam
((
int
)(
x
),(
int
)(
y
),
d0
);
float3
X
=
camera_origin
.
screenToCam
((
int
)(
x
),(
int
)(
y
),
d0
);
int2
s
=
camera_in
.
camToScreen
<
int2
>
(
o_2_in
*
X
);
const
float3
camPos
=
o_2_in
*
X
;
const
int2
s
=
camera_in
.
camToScreen
<
int2
>
(
camPos
);
// TODO: Could dynamically adjust the smoothing factors depending upon the
// TODO: Could dynamically adjust the smoothing factors depending upon the
// number of matches. Meaning, if lots of good local and feature matches
// number of matches. Meaning, if lots of good local and feature matches
// then be less likely to include poorer matches. Conversely, if only poor
// then be less likely to include poorer matches. Conversely, if only poor
// non-local or feature distance matches, then increase search range.
// non-local or feature distance matches, then increase search range.
// Could also adapt smoothing parameters using variance or some other local
// image measures. Or by just considering distance of the central projected
// points as an indication of miss-alignment. Both spatial distance and
// feature distance could be used to adjust parameters.
/*if (s.x >= 0 && s.x < camera_in.width && s.y >= 0 && s.y <= camera_in.height) {
// Get depth at exact reprojection point
const float d = depth_in[s.x+s.y*dpitch_i];
// Get feature at exact reprojection point
const uchar2 feature2 = feature_in[s.x+y+(s.y+v)*fpitch_i];
}*/
// Neighbourhood
// Neighbourhood
for
(
int
v
=-
SEARCH_RADIUS
;
v
<=
SEARCH_RADIUS
;
++
v
)
{
for
(
int
v
=-
SEARCH_RADIUS
;
v
<=
SEARCH_RADIUS
;
++
v
)
{
for
(
int
u
=-
SEARCH_RADIUS
;
u
<=
SEARCH_RADIUS
;
++
u
)
{
for
(
int
u
=-
SEARCH_RADIUS
;
u
<=
SEARCH_RADIUS
;
++
u
)
{
...
@@ -74,7 +88,7 @@ __device__ inline float featureWeight(int f1, int f2) {
...
@@ -74,7 +88,7 @@ __device__ inline float featureWeight(int f1, int f2) {
const
float3
Xi
=
in_2_o
*
camera_in
.
screenToCam
(
s
.
x
+
u
,
s
.
y
+
v
,
d
);
const
float3
Xi
=
in_2_o
*
camera_in
.
screenToCam
(
s
.
x
+
u
,
s
.
y
+
v
,
d
);
const
float3
Ni
=
make_float3
(
normals_in
[
s
.
x
+
u
+
(
s
.
y
+
v
)
*
npitch_in
]);
const
float3
Ni
=
make_float3
(
normals_in
[
s
.
x
+
u
+
(
s
.
y
+
v
)
*
npitch_in
]);
const
uchar2
feature2
=
feature_in
[
s
.
x
+
y
+
(
s
.
y
+
v
)
*
fpitch_i
];
const
uchar2
feature2
=
feature_in
[
s
.
x
+
u
+
(
s
.
y
+
v
)
*
fpitch_i
];
// Gauss approx weighting functions
// Gauss approx weighting functions
// Rule: spatially close and feature close is strong
// Rule: spatially close and feature close is strong
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment