Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Olena
olena
Commits
e31b7016
Commit
e31b7016
authored
Jul 06, 2010
by
Guillaume Lazzara
Browse files
Disable some debug output.
* text/clean_inplace.hh, * text/recognition.hh: Disable some debug output.
parent
9e66b0bc
Changes
3
Hide whitespace changes
Inline
Side-by-side
scribo/ChangeLog
View file @
e31b7016
2010-07-06 Guillaume Lazzara <z@lrde.epita.fr>
Disable some debug output.
* text/clean_inplace.hh,
* text/recognition.hh: Disable some debug output.
2010-07-06 Guillaume Lazzara <z@lrde.epita.fr>
Add a tool for text recognition in natural pictures.
scribo/
src/Makefile.am: Add a new rule.
*
src/Makefile.am: Add a new rule.
scribo/
src/text_recognition_in_picture.cc: New.
*
src/text_recognition_in_picture.cc: New.
2010-07-06 Guillaume Lazzara <z@lrde.epita.fr>
Add text::look_like_text_lines.
*
scribo/
text/look_like_text_lines.hh: New.
* text/look_like_text_lines.hh: New.
*
scribo/
text/merging.hh: Make use of
* text/merging.hh: Make use of
text::look_like_text_lines.
2010-06-30 Arthur Crepin-Leblond <crepin@stockholm.lrde.epita.fr>
...
...
scribo/text/clean_inplace.hh
View file @
e31b7016
...
...
@@ -111,11 +111,11 @@ namespace scribo
return
;
float
fact
=
line
.
x_height
()
/
40.0
f
;
std
::
cout
<<
fact
<<
" - "
<<
input
.
domain
()
<<
std
::
endl
;
//
std::cout << fact << " - " << input.domain() << std::endl;
if
(
fact
<
1
)
{
std
::
cout
<<
"Upsampling..."
<<
" - "
<<
fact
<<
std
::
endl
;
//
std::cout << "Upsampling..." << " - "
//
<< fact << std::endl;
while
(
fact
<
0.90
)
{
input
=
scribo
::
upsampling
::
eagle
(
input
);
// 2x upsampling
...
...
@@ -127,13 +127,13 @@ namespace scribo
}
else
if
(
fact
>
2.5
f
)
{
std
::
cout
<<
"subsampling::bilinear"
<<
" - "
<<
std
::
ceil
(
fact
)
<<
std
::
endl
;
//
std::cout << "subsampling::bilinear" << " - "
//
<< std::ceil(fact) << std::endl;
input
=
subsampling
::
bilinear
(
input
,
std
::
ceil
(
fact
-
0.5
));
// math::floor instead?
}
else
std
::
cout
<<
"not clean_inplaceing text. Seems ok."
<<
std
::
endl
;
//
else
//
std::cout << "not clean_inplaceing text. Seems ok." << std::endl;
trace
::
exiting
(
"scribo::text::clean_inplace"
);
}
...
...
scribo/text/recognition.hh
View file @
e31b7016
...
...
@@ -121,9 +121,9 @@ namespace scribo
if
(
!
lines
(
i
).
is_valid
()
||
lines
(
i
).
tag
()
!=
line
::
None
||
lines
(
i
).
type
()
!=
line
::
Text
)
continue
;
std
::
cout
<<
"Text recognition... ("
<<
i
<<
"/"
<<
lines
.
nelements
()
<<
")"
<<
std
::
endl
;
std
::
cout
<<
"x_height = "
<<
lines
(
i
).
x_height
()
<<
std
::
endl
;
//
std::cout << "Text recognition... ("
//
<< i << "/" << lines.nelements() << ")" << std::endl;
//
std::cout << "x_height = " << lines(i).x_height() << std::endl;
mln_domain
(
I
)
box
=
lines
(
i
).
bbox
();
...
...
@@ -175,7 +175,7 @@ namespace scribo
if
(
s
!=
0
)
{
std
::
cerr
<<
s
<<
std
::
endl
;
//
std::cerr << s << std::endl;
std
::
string
str
(
s
);
str
=
str
.
substr
(
0
,
str
.
length
()
-
2
);
lines
(
i
).
update_text
(
str
);
...
...
@@ -232,7 +232,7 @@ namespace scribo
if
(
s
!=
0
)
{
std
::
cout
<<
s
<<
std
::
endl
;
//
std::cout << s << std::endl;
if
(
!
output_file
.
empty
())
{
std
::
string
str
(
s
);
...
...
Write
Preview
Supports
Markdown
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