Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
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
Commits
bacc2106
Commit
bacc2106
authored
Apr 17, 2017
by
David Carlier
Committed by
David Carlier
Apr 18, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixing segfaults occuring when launching those unit tests
parent
0d10eb51
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
14 additions
and
1 deletion
+14
-1
test_cameracalibration.cpp
modules/calib3d/test/test_cameracalibration.cpp
+2
-1
lr.cpp
modules/ml/src/lr.cpp
+3
-0
test_emknearestkmeans.cpp
modules/ml/test/test_emknearestkmeans.cpp
+1
-0
test_lr.cpp
modules/ml/test/test_lr.cpp
+5
-0
test_shape.cpp
modules/shape/test/test_shape.cpp
+3
-0
No files found.
modules/calib3d/test/test_cameracalibration.cpp
View file @
bacc2106
...
...
@@ -1570,7 +1570,8 @@ void CV_StereoCalibrationTest::run( int )
{
ts
->
printf
(
cvtest
::
TS
::
LOG
,
"The file %s can not be opened or has invalid content
\n
"
,
filepath
.
c_str
()
);
ts
->
set_failed_test_info
(
f
?
cvtest
::
TS
::
FAIL_INVALID_TEST_DATA
:
cvtest
::
TS
::
FAIL_MISSING_TEST_DATA
);
fclose
(
f
);
if
(
f
)
fclose
(
f
);
return
;
}
...
...
modules/ml/src/lr.cpp
View file @
bacc2106
...
...
@@ -138,6 +138,9 @@ bool LogisticRegressionImpl::train(const Ptr<TrainData>& trainData, int)
// return value
bool
ok
=
false
;
if
(
trainData
.
empty
())
{
return
false
;
}
clear
();
Mat
_data_i
=
trainData
->
getSamples
();
Mat
_labels_i
=
trainData
->
getResponses
();
...
...
modules/ml/test/test_emknearestkmeans.cpp
View file @
bacc2106
...
...
@@ -618,6 +618,7 @@ protected:
{
ts
->
printf
(
cvtest
::
TS
::
LOG
,
"File with spambase dataset cann't be read.
\n
"
);
ts
->
set_failed_test_info
(
cvtest
::
TS
::
FAIL_INVALID_TEST_DATA
);
return
;
}
Mat
samples
=
data
->
getSamples
();
...
...
modules/ml/test/test_lr.cpp
View file @
bacc2106
...
...
@@ -95,6 +95,11 @@ void CV_LRTest::run( int /*start_from*/ )
string
dataFileName
=
ts
->
get_data_path
()
+
"iris.data"
;
Ptr
<
TrainData
>
tdata
=
TrainData
::
loadFromCSV
(
dataFileName
,
0
);
if
(
tdata
.
empty
())
{
ts
->
set_failed_test_info
(
cvtest
::
TS
::
FAIL_INVALID_TEST_DATA
);
return
;
}
// run LR classifier train classifier
Ptr
<
LogisticRegression
>
p
=
LogisticRegression
::
create
();
p
->
setLearningRate
(
1.0
);
...
...
modules/shape/test/test_shape.cpp
View file @
bacc2106
...
...
@@ -83,6 +83,9 @@ protected:
vector
<
PointType
>
convertContourType
(
const
Mat
&
currentQuery
)
const
{
if
(
currentQuery
.
empty
())
{
return
vector
<
PointType
>
();
}
vector
<
vector
<
Point
>
>
_contoursQuery
;
findContours
(
currentQuery
,
_contoursQuery
,
RETR_LIST
,
CHAIN_APPROX_NONE
);
...
...
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