Stefan Weil
fbaac9dc9d
Modernize code (clang-tidy -checks='-*,google-readability-braces-around-statements')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:03:51 +01:00
Stefan Weil
49d4afca63
Modernize code (clang-tidy -checks='-*,modernize-use-equals-*')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:57 +01:00
Stefan Weil
2a83c4a898
Modernize code (clang-tidy -checks='-*,modernize-use-emplace')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:57 +01:00
Stefan Weil
a54dc6390d
Modernize code (clang-tidy -checks='-*,modernize-use-auto')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:57 +01:00
Stefan Weil
77ed2886a7
Modernize code (clang-tidy -checks='-*,modernize-loop-convert')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:51 +01:00
Stefan Weil
cb80eb6963
Modernize code (clang-tidy -checks='-*,modernize-use-override')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:13 +01:00
Stefan Weil
7bada4e629
Add braces to single line statements (clang-tidy -checks='-*,google-readability-braces-around-statements')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:13 +01:00
Stefan Weil
d4d51910e1
Add braces to single line statements (clang-tidy -checks='-*,google-readability-braces-around-statements')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:13 +01:00
Egor Pugin
205cd32184
Merge pull request #3351 from stweil/master
...
Modernize code using clang-tidy
2021-03-22 00:43:47 +03:00
Stefan Weil
5384aa7b21
Modernize code (clang-tidy -checks='-*,modernize-use-equals-delete')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:56 +01:00
Stefan Weil
406233f1ae
Modernize code (clang-tidy -checks='-*,modernize-use-equals-default')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:56 +01:00
Stefan Weil
27293fad62
Modernize code (clang-tidy -checks='-*,modernize-use-emplace')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:55 +01:00
Stefan Weil
6fc31c44f8
Modernize code (clang-tidy -checks='-*,modernize-use-bool-literals')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:55 +01:00
Stefan Weil
35e143ddfc
Modernize code (clang-tidy -checks='-*,modernize-use-auto')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:55 +01:00
Stefan Weil
1439efa734
Modernize code (clang-tidy -checks='-*,modernize-make-unique')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:55 +01:00
Stefan Weil
02774bda6e
Modernize code (clang-tidy -checks='-*,modernize-loop-convert')
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 21:45:55 +01:00
Stefan Weil
719dc1d7da
Modernize code using override
...
The modifications were made using this command:
run-clang-tidy -header-filter='.*' -checks='-*,modernize-use-override' -fix
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 20:06:38 +01:00
Stefan Weil
187ac4136a
Fix LGTM alert (local variable hides a parameter)
...
LGTM alert:
Local variable 'correct_text' hides a parameter of the same name.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 18:20:13 +01:00
Egor Pugin
7d17b72ba5
Use more smart pointers.
2021-03-21 15:19:21 +03:00
Egor Pugin
2071430b28
Merge pull request #3350 from stweil/master
...
Fix compiler warnings (mostly -Wsign-compare)
2021-03-21 13:22:22 +03:00
Stefan Weil
0c20d3f843
Fix compiler warnings (mostly -Wsign-compare)
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-21 09:29:34 +01:00
Egor Pugin
c7653bf59f
Merge pull request #3349 from stweil/master
...
Disable most Leptonica messages for tesseract by default
2021-03-20 22:47:11 +03:00
Stefan Weil
55d87f642c
Disable most Leptonica messages for tesseract by default
...
They were disabled in earlier builds which used NDEBUG, too.
Allow manual setting of the Leptonica message level
with environment variable LEPT_MSG_SEVERITY.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 20:16:16 +01:00
Stefan Weil
19afcdb79b
Remove unused function UnicharIdArrayUtils::find_in
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 15:51:28 +01:00
Stefan Weil
7af5b75b8f
Disable unused WriteMemoryCallback if libcurl is not used
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 15:49:06 +01:00
Egor Pugin
db7a977eab
Use smart pointers.
2021-03-20 16:04:45 +03:00
Egor Pugin
69ab5bbf65
Misc.
2021-03-20 16:04:00 +03:00
Stefan Weil
f176e7c274
Fix double free caused by commit f33e80e
(fixes issue #3348 )
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 12:37:56 +01:00
Stefan Weil
87b0a4de97
Rename GenericVector::get
...
The new name GenericVector::at is compatible with standard containers.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 09:42:19 +01:00
Stefan Weil
2c1c09bd6a
Rename UnicityTable::get, UnicityTable::get_mutable
...
The new name UnicityTable::at is compatible with standard containers.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 09:40:00 +01:00
Stefan Weil
883353df63
Replace std::array by std::vector to avoid stack overflow
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 09:39:16 +01:00
Egor Pugin
a88ea7684e
Merge pull request #3345 from stweil/vector
...
Replace more PointerVector by std::vector
2021-03-20 11:15:52 +03:00
Stefan Weil
ec2c989d00
Modernize code in src/classify
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-20 09:06:40 +01:00
Stefan Weil
54aec32586
Replace remaining PointerVector by std::vector for src/lstm
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 22:22:04 +01:00
Stefan Weil
0d739530a5
Remove unused PointerVector::DeSerialize, PonterVector::DeSerializeElement
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 21:53:17 +01:00
Stefan Weil
7207cf13d7
Replace more PointerVector by std::vector for src/ccstruct
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 21:53:08 +01:00
Stefan Weil
aa64d83c2f
Replace more PointerVector by std::vector for src/classify
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 15:22:29 +01:00
Stefan Weil
79477dc2fe
Replace more PointerVector by std::vector for src/ccstruct
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 14:46:25 +01:00
Egor Pugin
2d8054767c
Merge pull request #3344 from stweil/vector
...
Replace more GenericVector and PointerVector by std::vector
2021-03-19 15:40:37 +03:00
Stefan Weil
752779aaed
Replace more PointerVector by std::vector for src/classify
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Stefan Weil
cac116dd11
Replace more PointerVector by std::vector for src/training
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Stefan Weil
dae5accceb
Replace remaining PointerVector by std::vector for src/api
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Stefan Weil
9e006a8bbc
Replace more GenericVector by std::vector for src/ccstruct
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Stefan Weil
65d882f96e
Replace more GenericVector by std::vector for src/ccstruct
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Stefan Weil
8ed6dee8e9
Replace more GenericVector by std::vector for src/ccstruct
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Stefan Weil
abc22976e4
Replace remaining PointerVector by std::vector for src/api
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 12:27:48 +01:00
Egor Pugin
862251b4f7
Merge pull request #3342 from stweil/master
...
Suppress resolution warning if no resolution was given
2021-03-19 13:09:21 +03:00
Stefan Weil
7f11261076
Suppress resolution warning if no resolution was given
...
Tesseract reported confusing information for images without resolution:
Warning: Invalid resolution 0 dpi. Using 70 instead.
Estimating resolution as 642
The warning is also shown when the resolution is not used at all
when preparing data for training.
It is now suppressed when there is no resolution information
(resolution == 0).
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-19 10:45:54 +01:00
Stefan Weil
52a82b4356
Fix new alert reported by LGTM
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-18 23:27:17 +01:00
Egor Pugin
dcedf8d912
Merge pull request #3341 from stweil/vector
...
Replace more GenericVector and PointerVector by std::vector
2021-03-19 00:19:38 +03:00