Commit Graph

4016 Commits

Author SHA1 Message Date
Stefan Weil
1d5a320d4a Revert "Simplify class LSTMTrainer"
This reverts commit 563a1717d4.
It removed global symbols, so the binary API was incompatible.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-07-02 06:38:19 +02:00
zdenop
10f5bffa48 decrease reuired version of cmake to build as 3.6 is still in use. Side effect no support for c++17 in CXX_STANDARD 2019-07-01 19:46:36 +02:00
zdenop
6157b8b5da update Changelog (main 4.1 changes) 2019-07-01 19:21:51 +02:00
Stefan Weil
1a205b8bed cmake: Fix build with OpenMP (issue #2462)
Builds with gcc wrongly used /openmp instead of -fopenmp.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Stefan Weil
3dff32e407 Fix check for icu 52.1 or newer
It detected old versions but did not disable the training build.
This completes commit 66da4df11d.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Stefan Weil
4535e4605b Update enum from unicode/uchar.h
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Stefan Weil
4b03d13fff unittest: Fix function QCHECK (issue #2517)
The function must print an error message if the condition fails.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Egor Pugin
afb36b35e4 Add VS2019 2019-06-25 14:55:03 +02:00
Stefan Weil
20a0c61444 Fix format string for 64 bit integer
This fixes also a warning from gcc.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Stefan Weil
daac30e6c4 baseapi: Remove old code
The workaround is no longer needed because _splitpath and _MAX_FNAME
were removed in commit cc0d87c5b8.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Stefan Weil
1ce4c2f83c Replace code using _splitpath_s (win32)
That simplifies the code and removes a dependency on "newer"
versions of Windows.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-25 14:55:03 +02:00
Stefan Weil
1a279d11fc Remove outdated comment
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:55:15 +02:00
Stefan Weil
dc2dada0b5 Remove dummy code from LSTMTrainer::InitTensorFlowNetwork
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:54:58 +02:00
Stefan Weil
7b58962246 Simplify unittest/Makefile.am
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:54:40 +02:00
Stefan Weil
f44be2e81a cmake: Build training tools also on Linux and macOS
This enables CI tests for the code in src/training on Linux and macOS.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:54:26 +02:00
Stefan Weil
c967f8927c Add package libpango1.0-dev to Travis configuration
It is needed to build the training tools.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:54:13 +02:00
Stefan Weil
a30d433356 Move LSTMTrainer from libtesseract to libtesseract_training
LSTMTrainer is only used for training, so the shared library for
Tesseract can be made smaller.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:53:21 +02:00
Stefan Weil
1a44ce3178 Replace callback by direct function calls in TessBaseAPI::GetComponentImages
The new code avoids dynamic memory allocation, uses faster function calls
and allows removing more code from tesscallback.h.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:52:31 +02:00
Stefan Weil
563a1717d4 Simplify class LSTMTrainer
The function pointers and callbacks file_reader_, file_writer_,
checkpointer_reader_ and checkpoint_writer_ are always set to
the same values. Replacing them by direct function calls
simplifies the code and allows removing more code from tesscallback.h.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:51:44 +02:00
Stefan Weil
c5525c4458 Remove wrong description for GenericVector::set_compare_callback and simplify code
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:50:01 +02:00
Stefan Weil
6a0fc4f89f Simplify indirect call of LMPainPoints::GeneratePainPoint
It does neither need a temporary TessResultCallback2 nor the function
LMPainPoints::GenerateForBlamer.

This also allows removing more code from tesscallback.h.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-23 08:49:18 +02:00
zdenop
c614907ea0 tesstrain_utils.sh: remove redundant code 2019-06-23 08:48:23 +02:00
Stefan Weil
6a39b81d45 tesscallback: Remove more unused code
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-20 14:14:00 +02:00
Stefan Weil
3cdafa0fa1 4.1.0 Release candidate 4
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-18 09:48:36 +02:00
Stefan Weil
d7d0500030 Remove code for embedded build
That code is unrelated to Tesseract and can be easily implemented
by external projects which require it.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-18 09:46:16 +02:00
Egor Pugin
4d5eb6d304 Remove old and misguiding build steps on windows. 2019-06-18 09:39:25 +02:00
Stefan Weil
2f51af0f60 ocrfeatures: Remove locally used functions from global interface
ReadFeature, WriteFeature are only used locally.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-18 09:38:32 +02:00
Stefan Weil
9491538fb9 unittest: Add missing Leptonica library for textlineprojection_test
It is needed for builds with --enable-shared.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-17 15:07:42 +02:00
Stefan Weil
9a5f72479a Replace TessBaseAPI::CatchSignals by a dummy function
That function is now a dummy which just exists to be API compatible.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-17 14:55:05 +02:00
zdenop
cf512d3804 4.1.0-rc3 => VERSION 2019-06-17 10:25:37 +02:00
Zdenko Podobný
c400bdff7b Merge branch 'abi_comp' into 4.1
* abi_comp:
  restore CatchSignals to fix API compatibility
  fix build
2019-06-16 21:11:07 +02:00
Zdenko Podobný
7160888653 Revert "Integrated Timesteps per symbol into ChoiceIterator"
This reverts commit 4d3455e1de.
2019-06-16 21:10:18 +02:00
Zdenko Podobný
78ced35a8b restore CatchSignals to fix API compatibility 2019-06-16 21:08:13 +02:00
Zdenko Podobný
c5105c5325 fix build 2019-06-16 20:30:00 +02:00
Zdenko Podobný
4d3455e1de Integrated Timesteps per symbol into ChoiceIterator
Signed-off-by: Noah Metzger <noah.metzger@bib.uni-mannheim.de>

# Conflicts:
#	src/ccmain/ltrresultiterator.cpp
2019-06-16 19:22:19 +02:00
zdenop
9897bc9c8d cmake: backport master changes 2019-06-16 18:54:41 +02:00
zdenop
5d23dfa5ce create OUTPUT_DIR did not exist; fixes #2497 2019-06-16 18:37:03 +02:00
Stefan Weil
153b921c35 unittest: Catch missing eng.traineddata in baseapi_test
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-16 18:37:03 +02:00
Stefan Weil
ce82facc2f unittest: Fix and enable normstrngs_test
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-16 18:37:03 +02:00
Stefan Weil
c01b3229fe unittest: Fix and enable textlineprojection_test
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-16 18:37:03 +02:00
Stefan Weil
bb2ea347b1 unittest: Fix and enable scanutils_test
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-16 18:36:21 +02:00
Shree
3729b7b321 Allow saving of box/tiff pairs during base tesseract training 2019-06-16 18:36:21 +02:00
Shree
dfcdfe565f Allow saving of box/tiff pairs during base tesseract training 2019-06-16 18:36:21 +02:00
Shree
706a2330e2 Allow saving of box/tiff pairs during base tesseract training 2019-06-16 18:35:37 +02:00
Stefan Weil
35b8826289 unittest: Fix and enable ligature_table_test
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-06-16 18:35:19 +02:00
Egor Pugin
15da5c1206 [sw] Remove inexistent include dirs. 2019-06-16 18:35:19 +02:00
Egor Pugin
5b32be82f4 [sw] Exclude missing include dir. 2019-06-16 18:35:19 +02:00
Egor Pugin
f9da14eca1 Update appveyor.yml 2019-06-16 18:35:19 +02:00
Egor Pugin
b6f9ab6616 Update sw script. 2019-06-16 18:34:31 +02:00
zdenop
249acaed28 cmake: using c++ standard for g++ 2019-06-16 18:34:14 +02:00