Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dlib
Commits
33c8d0c2
Commit
33c8d0c2
authored
Feb 27, 2016
by
Davis King
Browse files
Added pose and detection scores to the box object.
parent
2b2c6f01
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
1 deletion
+11
-1
dlib/data_io/image_dataset_metadata.cpp
dlib/data_io/image_dataset_metadata.cpp
+6
-0
dlib/data_io/image_dataset_metadata.h
dlib/data_io/image_dataset_metadata.h
+5
-1
No files found.
dlib/data_io/image_dataset_metadata.cpp
View file @
33c8d0c2
...
@@ -80,6 +80,10 @@ namespace dlib
...
@@ -80,6 +80,10 @@ namespace dlib
fout
<<
" ignore='"
<<
b
.
ignore
<<
"'"
;
fout
<<
" ignore='"
<<
b
.
ignore
<<
"'"
;
if
(
b
.
angle
!=
0
)
if
(
b
.
angle
!=
0
)
fout
<<
" angle='"
<<
b
.
angle
<<
"'"
;
fout
<<
" angle='"
<<
b
.
angle
<<
"'"
;
if
(
b
.
pose
!=
0
)
fout
<<
" pose='"
<<
b
.
pose
<<
"'"
;
if
(
b
.
detection_score
!=
0
)
fout
<<
" detection_score='"
<<
b
.
detection_score
<<
"'"
;
if
(
b
.
has_label
()
||
b
.
parts
.
size
()
!=
0
)
if
(
b
.
has_label
()
||
b
.
parts
.
size
()
!=
0
)
{
{
...
@@ -192,6 +196,8 @@ namespace dlib
...
@@ -192,6 +196,8 @@ namespace dlib
if
(
atts
.
is_in_list
(
"occluded"
))
temp_box
.
occluded
=
sa
=
atts
[
"occluded"
];
if
(
atts
.
is_in_list
(
"occluded"
))
temp_box
.
occluded
=
sa
=
atts
[
"occluded"
];
if
(
atts
.
is_in_list
(
"ignore"
))
temp_box
.
ignore
=
sa
=
atts
[
"ignore"
];
if
(
atts
.
is_in_list
(
"ignore"
))
temp_box
.
ignore
=
sa
=
atts
[
"ignore"
];
if
(
atts
.
is_in_list
(
"angle"
))
temp_box
.
angle
=
sa
=
atts
[
"angle"
];
if
(
atts
.
is_in_list
(
"angle"
))
temp_box
.
angle
=
sa
=
atts
[
"angle"
];
if
(
atts
.
is_in_list
(
"pose"
))
temp_box
.
pose
=
sa
=
atts
[
"pose"
];
if
(
atts
.
is_in_list
(
"detection_score"
))
temp_box
.
detection_score
=
sa
=
atts
[
"detection_score"
];
temp_box
.
rect
.
bottom
()
+=
temp_box
.
rect
.
top
()
-
1
;
temp_box
.
rect
.
bottom
()
+=
temp_box
.
rect
.
top
()
-
1
;
temp_box
.
rect
.
right
()
+=
temp_box
.
rect
.
left
()
-
1
;
temp_box
.
rect
.
right
()
+=
temp_box
.
rect
.
left
()
-
1
;
...
...
dlib/data_io/image_dataset_metadata.h
View file @
33c8d0c2
...
@@ -45,7 +45,9 @@ namespace dlib
...
@@ -45,7 +45,9 @@ namespace dlib
truncated
(
false
),
truncated
(
false
),
occluded
(
false
),
occluded
(
false
),
ignore
(
false
),
ignore
(
false
),
angle
(
0
)
angle
(
0
),
pose
(
0
),
detection_score
(
0
)
{}
{}
rectangle
rect
;
rectangle
rect
;
...
@@ -58,6 +60,8 @@ namespace dlib
...
@@ -58,6 +60,8 @@ namespace dlib
bool
truncated
;
bool
truncated
;
bool
occluded
;
bool
occluded
;
bool
ignore
;
bool
ignore
;
double
pose
;
double
detection_score
;
// The angle of the object in radians. Positive values indicate that the
// The angle of the object in radians. Positive values indicate that the
// object at the center of the box is rotated clockwise by angle radians. A
// object at the center of the box is rotated clockwise by angle radians. A
...
...
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