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
0ecff0e6
Commit
0ecff0e6
authored
Feb 08, 2016
by
Davis King
Browse files
Removed gif filtering
parent
4eb253af
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
6 deletions
+0
-6
examples/dnn_mit67_ex.cpp
examples/dnn_mit67_ex.cpp
+0
-6
No files found.
examples/dnn_mit67_ex.cpp
View file @
0ecff0e6
...
@@ -9,7 +9,6 @@
...
@@ -9,7 +9,6 @@
#include <dlib/image_transforms.h>
#include <dlib/image_transforms.h>
#include <dlib/dir_nav.h>
#include <dlib/dir_nav.h>
#include <iterator>
#include <iterator>
#include <regex>
using
namespace
std
;
using
namespace
std
;
using
namespace
dlib
;
using
namespace
dlib
;
...
@@ -116,18 +115,13 @@ std::vector<image_info> get_mit67_listing(
...
@@ -116,18 +115,13 @@ std::vector<image_info> get_mit67_listing(
auto
subdirs
=
directory
(
images_folder
).
get_dirs
();
auto
subdirs
=
directory
(
images_folder
).
get_dirs
();
// sort the sub directories so the numeric labels will be assigned in sorted order.
// sort the sub directories so the numeric labels will be assigned in sorted order.
std
::
sort
(
subdirs
.
begin
(),
subdirs
.
end
());
std
::
sort
(
subdirs
.
begin
(),
subdirs
.
end
());
regex
is_gif
(
".*_gif.jpg"
);
for
(
auto
subdir
:
subdirs
)
for
(
auto
subdir
:
subdirs
)
{
{
// Now get all the images in this scene type
// Now get all the images in this scene type
temp
.
label
=
subdir
.
name
();
temp
.
label
=
subdir
.
name
();
for
(
auto
image_file
:
subdir
.
get_files
())
for
(
auto
image_file
:
subdir
.
get_files
())
{
{
// Ignore gif files in this dataset since dlib::load_image() doesn't support
// them and there are only a tiny number of them.
temp
.
filename
=
image_file
;
temp
.
filename
=
image_file
;
if
(
regex_match
(
temp
.
filename
,
is_gif
))
continue
;
results
.
push_back
(
temp
);
results
.
push_back
(
temp
);
}
}
++
temp
.
numeric_label
;
++
temp
.
numeric_label
;
...
...
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