mirror of
https://github.com/tesseract-ocr/tesseract.git
synced 2024-11-27 12:49:35 +08:00
Merge pull request #4150 from tfmorris/4149-directory-to-stdout
Send output of combine_tessdata -d to stdout instead of stderr. Fixes #4149
This commit is contained in:
commit
eb612f0786
@ -211,11 +211,11 @@ void TessdataManager::Clear() {
|
||||
|
||||
// Prints a directory of contents.
|
||||
void TessdataManager::Directory() const {
|
||||
tprintf("Version:%s\n", VersionString().c_str());
|
||||
printf("Version:%s\n", VersionString().c_str());
|
||||
auto offset = TESSDATA_NUM_ENTRIES * sizeof(int64_t);
|
||||
for (unsigned i = 0; i < TESSDATA_NUM_ENTRIES; ++i) {
|
||||
if (!entries_[i].empty()) {
|
||||
tprintf("%u:%s:size=%zu, offset=%zu\n", i, kTessdataFileSuffixes[i], entries_[i].size(),
|
||||
printf("%u:%s:size=%zu, offset=%zu\n", i, kTessdataFileSuffixes[i], entries_[i].size(),
|
||||
offset);
|
||||
offset += entries_[i].size();
|
||||
}
|
||||
|
@ -265,6 +265,9 @@ int main(int argc, char **argv) {
|
||||
"Usage for listing directory of components:\n"
|
||||
" %s -d traineddata_file\n\n",
|
||||
argv[0]);
|
||||
printf(
|
||||
"NOTE: Above two flags may combined as -dl or -ld to get both outputs"
|
||||
);
|
||||
printf(
|
||||
"Usage for compacting LSTM component to int:\n"
|
||||
" %s -c traineddata_file\n",
|
||||
|
Loading…
Reference in New Issue
Block a user