Commit Graph

16 Commits

Author SHA1 Message Date
Stefan Weil
ade0dfaa8c Fix two compiler warnings in tesseract.cpp
Some checks failed
CodeQL / Analyze (cpp) (push) Has been cancelled
vcpkg / build (windows-2019) (push) Has been cancelled
unittest / ${{ matrix.config.name }} (map[cxx:clang++ cxxflags:-g -O2 -fsanitize=address,undefined -stdlib=libc++ name:ubuntu-22.04-clang-unittest os:ubuntu-22.04]) (push) Has been cancelled
unittest / ${{ matrix.config.name }} (map[cxx:g++ cxxflags:-g -O2 -fsanitize=address,undefined name:ubuntu-24.04-gcc-unittest os:ubuntu-24.04]) (push) Has been cancelled
unittest-macos / ${{ matrix.config.name }} (map[cxx:clang++ name:macos-arm-14-clang-unittest os:macos-14]) (push) Has been cancelled
unittest-macos / ${{ matrix.config.name }} (map[cxx:clang++ name:macos-latest-clang-unittest os:macos-latest]) (push) Has been cancelled
unittest-macos / ${{ matrix.config.name }} (map[cxx:g++ name:macos-latest-gcc-unittest os:macos-latest]) (push) Has been cancelled
sw / build (fedora:latest, ubuntu-22.04) (push) Has been cancelled
sw / build (macos-latest) (push) Has been cancelled
sw / build (windows-2022) (push) Has been cancelled
msys2 / windows (mingw-w64-x86_64, MINGW64) (push) Has been cancelled
cmake / ${{ matrix.config.name }} (map[cxx:clang++ name:macos-14-clang-15-cmake os:macos-14]) (push) Has been cancelled
cmake / ${{ matrix.config.name }} (map[cxx:clang++ name:macos-15-clang-cmake os:macos-15]) (push) Has been cancelled
cmake / ${{ matrix.config.name }} (map[cxx:clang++-15 name:ubuntu-22.04-clang-15-cmake os:ubuntu-22.04]) (push) Has been cancelled
cmake / ${{ matrix.config.name }} (map[cxx:g++-12 name:ubuntu-22.04-gcc-12-cmake os:ubuntu-22.04]) (push) Has been cancelled
cmake / ${{ matrix.config.name }} (map[cxx:g++-14 name:macos-14-gcc-14-cmake os:macos-14]) (push) Has been cancelled
cmake / ${{ matrix.config.name }} (map[cxx:g++-14 name:ubuntu-24.04-gcc-12-cmake os:ubuntu-24.04]) (push) Has been cancelled
cmake-win64 / cmake-win64 (push) Has been cancelled
autotools / linux (map[cxx:clang++-15 name:ubuntu-22.04-clang-15-autotools os:ubuntu-22.04]) (push) Has been cancelled
autotools / linux (map[cxx:g++-11 name:ubuntu-22.04-gcc-11-autotools os:ubuntu-22.04]) (push) Has been cancelled
autotools / linux (map[cxx:g++-12 name:ubuntu-22.04-gcc-12-autotools os:ubuntu-22.04]) (push) Has been cancelled
autotools / linux (map[cxx:g++-14 name:ubuntu-24.04-gcc-14-autotools os:ubuntu-24.04]) (push) Has been cancelled
autotools-macos / brew (map[cxx:clang++ name:macos-latest-clang-autotools os:macos-latest]) (push) Has been cancelled
autotools-macos / ports (map[cxx:clang++ name:macos-latest-clang-autotools os:macos-latest]) (push) Has been cancelled
unittest-disablelegacy / linux (clang++-18, ubuntu-24.04) (push) Has been cancelled
unittest-disablelegacy / linux (g++, ubuntu-24.04) (push) Has been cancelled
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2025-05-02 07:26:38 +02:00
Egor Pugin
0a9df94fff Wrap main() into try catch.
Some checks failed
CodeQL / Analyze (cpp) (push) Has been cancelled
sw / build (fedora:latest, ubuntu-22.04) (push) Has been cancelled
sw / build (macos-latest) (push) Has been cancelled
sw / build (windows-2022) (push) Has been cancelled
cmake-win64 / cmake-win64 (push) Has been cancelled
2024-12-03 01:43:39 +03:00
zdenop
2e5a114bd2
add cli -c parameter(s) to init vectors (#4363)
Some checks failed
CodeQL / Analyze (cpp) (push) Has been cancelled
sw / build (fedora:latest, ubuntu-22.04) (push) Has been cancelled
sw / build (macos-latest) (push) Has been cancelled
sw / build (windows-2022) (push) Has been cancelled
2024-11-27 14:04:30 +02:00
Stefan Weil
e83f78020e Fix stringToOEM and stringToPSM
Remove debug output and fix an out-of-bounds read for unsupported arguments.

Fixes: e8a9a56f9f ("Support symbolic values for --oem and --psm options")
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2024-11-10 10:16:37 +01:00
sunyuechi
16fc9d90a4 Add RISC-V V support (#4346)
Convert riscv-v-spec-1.0.pdf into 111 PNG images,
then perform OCR on each one in sequence,
and measure the testing time on banana_f3:

old:        31m16.267s
new:        16m51.155s

Co-authored-by: sunyuechi <sunyuechi@iscas.ac.cn>
Co-authored-by: Stefan Weil <sw@weilnetz.de>
2024-11-08 08:09:01 +01:00
Stefan Weil
e8a9a56f9f Support symbolic values for --oem and --psm options
This fixes issue #4332.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2024-11-02 07:00:59 +01:00
Stefan Weil
6be58e54fa Initialize variables in initialization list
This fixes several performance issues reported by Coverity:

    Variable 'master_trainer_' is assigned in constructor body.
    Consider performing initialization in initialization list.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2024-08-26 13:16:09 +02:00
Jan Kamlah
577e8a8b93 Add PAGE XML renderer / export (#4214)
Add PAGE XML export and documentation.
To generate PAGE XML output just add 'page' to the tesseract command.

The output is outputname + '.page.xml' to avoid conflicts with ALTO export.

The output can be customized with the flags:
tessedit_create_page_polygon and tessedit_create_page_wordlevel.

Co-authored-by: Stefan Weil <sw@weilnetz.de>
2024-04-19 21:12:39 +02:00
Stefan Weil
d5e000bc58
Remove unsupported OpenCL code and related API functions (#4220)
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2024-04-11 19:15:39 +03:00
Stefan Weil
92999505ee Abort with error message if OSD is requested with LSTM-only model
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2023-05-09 19:24:24 +02:00
zdenop
d89ff4667b reformat code (files with tabs) 2022-12-10 20:33:35 +01:00
Stefan Weil
0daf18c202 Detect availability of AVX512-VNNI
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-08-06 11:23:06 +02:00
Gilles Talis
be15b46c60 Check if platform supports feenableexcept
feenableexcept is not supported by uclibc

Signed-off-by: Gilles Talis <gilles.talis@gmail.com>
[Retrieved (and updated to add cmake support and simplify configure.ac)
from
https://git.buildroot.net/buildroot/tree/package/tesseract-ocr/0001-Check-if-platform-supports-feenableexcept.patch]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
2022-01-11 15:23:56 +01:00
Stefan Weil
03f2cfdf02 Show tessdata directory when listing models
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-11-13 21:43:01 +01:00
Stefan Weil
a5f2f90c8d Fix legacy build
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-11-01 08:34:34 +01:00
Stefan Weil
104ef8f30e Move src/api/tesseractmain.cpp to src/tesseract.cpp
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-10-31 21:43:30 +01:00