Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv_contrib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv_contrib
Commits
63bb7c16
Commit
63bb7c16
authored
Jun 03, 2017
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1208 from Bleach665:fix_VS2010
parents
38dd47cf
41559d74
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
14 additions
and
14 deletions
+14
-14
perf_dis_optflow.cpp
modules/optflow/perf/opencl/perf_dis_optflow.cpp
+2
-2
perf_disflow.cpp
modules/optflow/perf/perf_disflow.cpp
+2
-2
sparse_matching_gpc.cpp
modules/optflow/src/sparse_matching_gpc.cpp
+1
-1
test_OF_reproducibility.cpp
modules/optflow/test/test_OF_reproducibility.cpp
+4
-4
projectorcalibration.cpp
modules/structured_light/samples/projectorcalibration.cpp
+1
-1
sinusoidalpattern.cpp
modules/structured_light/src/sinusoidalpattern.cpp
+2
-2
pct_webcam.cpp
modules/xfeatures2d/samples/pct_webcam.cpp
+1
-1
bilateral_texture_filter.cpp
modules/ximgproc/src/bilateral_texture_filter.cpp
+1
-1
No files found.
modules/optflow/perf/opencl/perf_dis_optflow.cpp
View file @
63bb7c16
...
...
@@ -92,12 +92,12 @@ void MakeArtificialExample(UMat &dst_frame1, UMat &dst_frame2)
int
OF_scale
=
6
;
double
sigma
=
dst_frame1
.
cols
/
300
;
UMat
tmp
(
Size
(
dst_frame1
.
cols
/
(
int
)
pow
(
2
,
src_scale
),
dst_frame1
.
rows
/
(
int
)
pow
(
2
,
src_scale
)),
CV_8U
);
UMat
tmp
(
Size
(
dst_frame1
.
cols
/
(
1
<<
src_scale
),
dst_frame1
.
rows
/
(
1
<<
src_scale
)),
CV_8U
);
randu
(
tmp
,
0
,
255
);
resize
(
tmp
,
dst_frame1
,
dst_frame1
.
size
(),
0.0
,
0.0
,
INTER_LINEAR
);
resize
(
tmp
,
dst_frame2
,
dst_frame2
.
size
(),
0.0
,
0.0
,
INTER_LINEAR
);
Mat
displacement_field
(
Size
(
dst_frame1
.
cols
/
(
int
)
pow
(
2
,
OF_scale
),
dst_frame1
.
rows
/
(
int
)
pow
(
2
,
OF_scale
)),
Mat
displacement_field
(
Size
(
dst_frame1
.
cols
/
(
1
<<
OF_scale
),
dst_frame1
.
rows
/
(
1
<<
OF_scale
)),
CV_32FC2
);
randn
(
displacement_field
,
0.0
,
sigma
);
resize
(
displacement_field
,
displacement_field
,
dst_frame2
.
size
(),
0.0
,
0.0
,
INTER_CUBIC
);
...
...
modules/optflow/perf/perf_disflow.cpp
View file @
63bb7c16
...
...
@@ -86,12 +86,12 @@ void MakeArtificialExample(Mat &dst_frame1, Mat &dst_frame2)
int
OF_scale
=
6
;
double
sigma
=
dst_frame1
.
cols
/
300
;
Mat
tmp
(
Size
(
dst_frame1
.
cols
/
(
int
)
pow
(
2
,
src_scale
),
dst_frame1
.
rows
/
(
int
)
pow
(
2
,
src_scale
)),
CV_8U
);
Mat
tmp
(
Size
(
dst_frame1
.
cols
/
(
1
<<
src_scale
),
dst_frame1
.
rows
/
(
1
<<
src_scale
)),
CV_8U
);
randu
(
tmp
,
0
,
255
);
resize
(
tmp
,
dst_frame1
,
dst_frame1
.
size
(),
0.0
,
0.0
,
INTER_LINEAR
);
resize
(
tmp
,
dst_frame2
,
dst_frame2
.
size
(),
0.0
,
0.0
,
INTER_LINEAR
);
Mat
displacement_field
(
Size
(
dst_frame1
.
cols
/
(
int
)
pow
(
2
,
OF_scale
),
dst_frame1
.
rows
/
(
int
)
pow
(
2
,
OF_scale
)),
Mat
displacement_field
(
Size
(
dst_frame1
.
cols
/
(
1
<<
OF_scale
),
dst_frame1
.
rows
/
(
1
<<
OF_scale
)),
CV_32FC2
);
randn
(
displacement_field
,
0.0
,
sigma
);
resize
(
displacement_field
,
displacement_field
,
dst_frame2
.
size
(),
0.0
,
0.0
,
INTER_CUBIC
);
...
...
modules/optflow/src/sparse_matching_gpc.cpp
View file @
63bb7c16
...
...
@@ -570,7 +570,7 @@ bool GPCTree::trainNode( size_t nodeId, SIter begin, SIter end, unsigned depth )
localBestScore
=
score
;
else
{
const
double
beta
=
simulatedAnnealingTemperatureCoef
*
std
::
sqrt
(
i
)
/
(
nSamples
*
(
scoreGainPos
+
scoreGainNeg
)
);
const
double
beta
=
simulatedAnnealingTemperatureCoef
*
std
::
sqrt
(
static_cast
<
float
>
(
i
)
)
/
(
nSamples
*
(
scoreGainPos
+
scoreGainNeg
)
);
if
(
rng
.
uniform
(
0.0
,
1.0
)
>
std
::
exp
(
-
beta
*
(
localBestScore
-
score
)
)
)
coef
[
pos
]
=
randomModification
;
}
...
...
modules/optflow/test/test_OF_reproducibility.cpp
View file @
63bb7c16
...
...
@@ -100,8 +100,8 @@ TEST_P(DenseOpticalFlow_DIS, MultithreadReproducibility)
// resulting flow should be within the frame bounds:
double
min_val
,
max_val
;
minMaxLoc
(
resMultiThread
,
&
min_val
,
&
max_val
);
EXPECT_LE
(
abs
(
min_val
),
sqrt
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
)
);
EXPECT_LE
(
abs
(
max_val
),
sqrt
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
)
);
EXPECT_LE
(
abs
(
min_val
),
sqrt
(
static_cast
<
double
>
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
))
);
EXPECT_LE
(
abs
(
max_val
),
sqrt
(
static_cast
<
double
>
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
))
);
}
}
...
...
@@ -151,8 +151,8 @@ TEST_P(DenseOpticalFlow_VariationalRefinement, MultithreadReproducibility)
// resulting flow should be within the frame bounds:
double
min_val
,
max_val
;
minMaxLoc
(
resMultiThread
,
&
min_val
,
&
max_val
);
EXPECT_LE
(
abs
(
min_val
),
sqrt
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
)
);
EXPECT_LE
(
abs
(
max_val
),
sqrt
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
)
);
EXPECT_LE
(
abs
(
min_val
),
sqrt
(
static_cast
<
double
>
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
))
);
EXPECT_LE
(
abs
(
max_val
),
sqrt
(
static_cast
<
double
>
(
size
.
height
*
size
.
height
+
size
.
width
*
size
.
width
))
);
}
}
...
...
modules/structured_light/samples/projectorcalibration.cpp
View file @
63bb7c16
...
...
@@ -477,7 +477,7 @@ void normalize( const Mat &pts, const int& dim, Mat& normpts, Mat &T )
averagedist
=
averagedist
+
(
float
)
norm
(
ptstmp
);
}
averagedist
=
averagedist
/
normpts
.
cols
;
scale
=
(
float
)(
sqrt
(
dim
)
/
averagedist
);
scale
=
(
float
)(
sqrt
(
static_cast
<
float
>
(
dim
)
)
/
averagedist
);
normpts
=
normpts
*
scale
;
...
...
modules/structured_light/src/sinusoidalpattern.cpp
View file @
63bb7c16
...
...
@@ -200,12 +200,12 @@ bool SinusoidalPatternProfilometry_Impl::generate( OutputArrayOfArrays pattern )
if
(
params
.
horizontal
)
{
period
=
params
.
height
/
params
.
nbrOfPeriods
;
nbrOfMarkersOnOneRow
=
(
int
)
floor
(
(
params
.
width
-
firstMarkerOffset
)
/
m
);
nbrOfMarkersOnOneRow
=
(
int
)
floor
(
static_cast
<
float
>
((
params
.
width
-
firstMarkerOffset
)
/
m
)
);
}
else
{
period
=
params
.
width
/
params
.
nbrOfPeriods
;
nbrOfMarkersOnOneRow
=
(
int
)
floor
(
(
params
.
height
-
firstMarkerOffset
)
/
m
);
nbrOfMarkersOnOneRow
=
(
int
)
floor
(
static_cast
<
float
>
((
params
.
height
-
firstMarkerOffset
)
/
m
)
);
}
frequency
=
(
float
)
1
/
period
;
...
...
modules/xfeatures2d/samples/pct_webcam.cpp
View file @
63bb7c16
...
...
@@ -117,7 +117,7 @@ int main(int argc, char** argv)
cerr
<<
"Sample count have to be a positive integer: "
<<
argv
[
1
]
<<
endl
;
return
1
;
}
initSeedCount
=
(
int
)
floor
(
initSampleCount
/
4
);
initSeedCount
=
(
int
)
floor
(
static_cast
<
float
>
(
initSampleCount
/
4
)
);
initSeedCount
=
std
::
max
(
1
,
initSeedCount
);
// fallback if sample count == 1
}
if
(
argc
>
2
)
// seed count
...
...
modules/ximgproc/src/bilateral_texture_filter.cpp
View file @
63bb7c16
...
...
@@ -63,7 +63,7 @@ namespace ximgproc
if
(
sigmaAlpha
<
0
)
sigmaAlpha
=
5.
*
fr
;
if
(
sigmaAvg
<
0
)
sigmaAvg
=
0.05
*
sqrt
(
s
rc
.
channels
(
));
sigmaAvg
=
0.05
*
sqrt
(
s
tatic_cast
<
float
>
(
src
.
channels
()
));
Mat
I
;
src
.
copyTo
(
I
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment