Commit Graph

2192 Commits

Author SHA1 Message Date
Ray Smith
ce76d1c569 Fixes to training process to allow incremental training from a recognition model 2016-11-30 15:51:17 -08:00
Ray Smith
9d9056716f Added std:: to vector 2016-11-30 15:45:36 -08:00
Ray Smith
53003f9074 Formatting changes from clang_tidy on latest pull 2016-11-30 15:44:25 -08:00
Stefan Weil
92d981b93a Change tesseract parameter -psm to --psm
For compatibility reasons the old variant is still supported.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-30 22:23:46 +01:00
Stefan Weil
d2f9264383 Change tesseract parameter -oem to --oem
It was introduced recently in commit f24ef67d, so there is no need
to support the old variant for compatibility reasons.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-30 22:23:46 +01:00
Stefan Weil
78d91701bd Simplify new operations
It is not necessary to check for null pointers after new.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-30 20:24:38 +01:00
Stefan Weil
03eec61a2f cube: Simplify new operations
It is not necessary to check for null pointers after new.

Simplify also two delete operations which were missing
in the previous commit.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-30 20:24:38 +01:00
zdenop
23e420aab0 Merge pull request #512 from NinnOgTonic/master
Correcting link for 3rd party wiki pages
2016-11-30 12:48:33 +01:00
Morten Espersen
392e32d990 Correcting link for 3rd party wiki pages 2016-11-30 12:00:23 +01:00
Egor Pugin
0d4d36f058 Merge pull request #508 from stweil/cube
cube: Fix issues reported by Coverity scan
2016-11-30 00:58:47 +03:00
Egor Pugin
5d3926e460 Merge pull request #507 from stweil/free
cube: Simplify delete operations
2016-11-30 00:55:41 +03:00
zdenop
dd9452cb23 Merge pull request #511 from stweil/mingw
Fix (cross) build for Mingw-w64
2016-11-29 15:16:47 +01:00
Stefan Weil
faea44cbc7 mingw-w64: Fix compiler warnings caused by macro redefinition
GNU compiler report (cross build for Windows on Debian):

In file included from ../ccutil/host.h:63:0,
                 from ../arch/dotproductsse.h:22,
                 from ../arch/dotproductsse.cpp:43:
../ccutil/platform.h:27:0: warning: "NOMINMAX" redefined
 #define NOMINMAX

In file included from /usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/c++/i686-w64-mingw32/bits/c++config.h:495:0,
                 from /usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/c++/cstdlib:41,
                 from /usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/c++/stdlib.h:36,
                 from /usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/mm_malloc.h:27,
                 from /usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/xmmintrin.h:34,
                 from /usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/emmintrin.h:31,
                 from ../arch/dotproductsse.cpp:40:
/usr/lib/gcc/i686-w64-mingw32/6.1-win32/include/c++/i686-w64-mingw32/bits/os_defines.h:45:0:
 note: this is the location of the previous definition
 #define NOMINMAX 1

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-29 14:37:10 +01:00
Stefan Weil
120a5dbdab Fix build for Mingw-w64
The old code (before commit 644469595c)
works well with Mingw-w64 which does not support this_thread.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-29 14:26:22 +01:00
Ray Smith
185a264f52 Fixed the memory leak/double free cleanly 2016-11-28 09:39:17 -08:00
Ray Smith
3d00d3bd94 Missing pdf font file from previous sync 2016-11-28 08:55:03 -08:00
Stefan Weil
f60ff4d575 cube/char_samp: Fix some memory leaks
Coverity report:

CID 1164722 (#9 of 9): Resource leak (RESOURCE_LEAK)
20. leaked_storage: Variable label32 going out of scope leaks the storage
 it points to.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-28 15:53:35 +01:00
Stefan Weil
614f44a7b2 cube/char_bigrams: Fix some memory leaks
Coverity report:

CID 1164717 (#1 of 1): Resource leak (RESOURCE_LEAK)
10. leaked_storage: Variable upper_32 going out of scope leaks
 the storage it points to.

CID 1164718 (#1 of 1): Resource leak (RESOURCE_LEAK)
10. leaked_storage: Variable lower_32 going out of scope leaks
 the storage it points to.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-28 15:53:35 +01:00
Stefan Weil
c46e773758 cube: Simplify delete operations
It is not necessary to check for null pointers.

Remove also unneeded delete operations and add missing delete operations
in cube/bmp_8.cpp.

Simplify also a conditional statement in cube/cube_object.cpp.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-28 15:48:36 +01:00
zdenop
d2389a810f Merge pull request #505 from amitdo/contributors-2
AUTHORS: Add more contributors
2016-11-27 21:31:22 +01:00
Amit D
ec99d9f2b2 AUTHORS: Add more contributors
and fix typo
2016-11-27 00:04:05 +02:00
Egor Pugin
7b5b16779a Merge pull request #494 from stweil/free
Simplify delete / free usage
2016-11-26 13:25:41 +03:00
Egor Pugin
0df77e3eef Merge pull request #501 from stweil/warn
lstm: Remove several unused variables
2016-11-26 13:24:10 +03:00
Egor Pugin
d0213fa56d Switch leptonica back to master. 2016-11-26 12:33:50 +03:00
zdenop
cf90e85697 Merge pull request #502 from stweil/ocl
opencl: Format and fix OpenCL kernel code
2016-11-25 17:45:43 +01:00
Stefan Weil
ba6961e0f4 opencl: Fix OpenCL kernel code assertion for newer versions
With Debian package beignet-opencl-icd 1.2.1-1, Tesseract + OpenCL fails:

[DS] Profile file not available (tesseract_opencl_profile_devices.dat); performing profiling.

[DS] Device: "Intel(R) HD Graphics IvyBridge M GT2" (OpenCL) evaluation...
ASSERTION FAILED: sel.hasDoubleType()
  at file /home/geier/beignet/backend/src/backend/gen_insn_selection.cpp, function void gbe::ConvertInstructionPattern::convertDoubleToSmallInts(gbe::Selection::Opaque&, const gbe::ir::ConvertInstruction&, bool&) const, line 5269
Trace/breakpoint trap

Using a pure float expression (instead of double) fixes this issue.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-25 17:41:30 +01:00
Stefan Weil
786b482ef8 opencl: Format OpenCL kernel code
* Remove some empty lines to get a more uniform code
* Fix #endif handling at end of file

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-25 17:39:06 +01:00
Stefan Weil
0020fbc0bd opencl: Clean whitespace issues in OpenCL kernel code
* Remove whitespace at line endings
* Replace tabs by spaces

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-25 17:36:05 +01:00
Stefan Weil
b04879412e lstm: Remove several unused variables
This fixes compiler warnings.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-25 15:43:39 +01:00
Stefan Weil
85e37798cb Simplify delete operations
It is not necessary to check for null pointers.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-24 17:59:13 +01:00
Stefan Weil
6158f7eae2 Simplify calls of free
It is not necessary to check for null pointers.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-24 17:59:13 +01:00
Egor Pugin
a8f444112e Fix build with leptonica 1.73. 2016-11-24 18:42:49 +03:00
Egor Pugin
b4fcd0d8b8 Set leptonica-1.73 as a dependency instead of master. 2016-11-24 18:35:33 +03:00
Egor Pugin
67deea5703 Fix unix build. 2016-11-24 17:39:16 +03:00
Egor Pugin
644469595c Fix windows build. 2016-11-24 17:32:23 +03:00
zdenop
64159c7fbb Merge pull request #177 from stweil/posix
Introduce POSIX data types
2016-11-24 14:25:47 +01:00
Zdenko Podobný
ed81de91a3 Merge branch 'master' of https://github.com/tesseract-ocr/tesseract 2016-11-24 14:18:50 +01:00
Zdenko Podobný
3dddf37b25 Increase version number in VS2010 2016-11-24 14:18:28 +01:00
Egor Pugin
60f6d6ed2b Update cppan.yml 2016-11-24 15:58:57 +03:00
zdenop
d869cd19a2 Merge pull request #499 from amitdo/contributors
AUTHORS - Add community contributors
2016-11-24 11:52:12 +01:00
Amit D
5b64942b2e AUTHORS - Add community contributors
... and Jeff
2016-11-24 12:25:13 +02:00
zdenop
19978a282c Merge pull request #498 from stweil/lstm
Fix 32 bit builds (missing _mm256_extract_epi64)
2016-11-24 08:47:19 +01:00
Stefan Weil
b54894a088 Fix 32 bit builds (missing _mm256_extract_epi64)
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-24 07:32:49 +01:00
zdenop
addb67c739 Merge pull request #496 from stweil/lstm
Fix broken cmake builds
2016-11-23 17:33:39 +01:00
Stefan Weil
95df572083 Fix broken cmake builds
Cmake builds need the additional directories `arch` and `lstm`
to find all include files and also for linking.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-23 16:37:26 +01:00
zdenop
5bb97f9668 Merge pull request #495 from stweil/warn
Fix compiler warning (-Wmaybe-uninitialized)
2016-11-23 08:45:03 +01:00
Stefan Weil
c882373baf Fix compiler warning (-Wmaybe-uninitialized)
gcc report:

ccstruct/blamer.cpp:343:65: warning:
 'truth_x' may be used uninitialized in this function [-Wmaybe-uninitialized]

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2016-11-23 07:22:05 +01:00
Ray Smith
51368c8eb4 Fixed failed merge of memory leak 2016-11-22 10:41:43 -08:00
Ray Smith
14bd70dd85 Merge branch 'stweil-opt'
Testing before pull.
2016-11-22 09:56:20 -08:00
Ray Smith
0169969b6f Merge branch 'opt' of https://github.com/stweil/tesseract into stweil-opt
Testing before pulling.
2016-11-22 09:55:41 -08:00