Community

Parallel Processing with ABBYY FineReader Engine 12 by python

Hi,

    I am using python to develop a batch and find only examples from other languages. I want to know if there is an example of python?

     FREngine.IImageSource imageSource = new CImageSource;

I don't know how to write this sentence in python.

 

0

Comments

2 comments

  • Avatar
    xiaowu lin

    c# code

    // Create Batch Processor
    FREngine.IBatchProcessor batchProcessor = engine.CreateBatchProcessor();
    // Set up multiprocessing parameters
    engine.MultiProcessingParams.RecognitionProcessesCount = coresNumber;
    // Initialize the processor
    FREngine.IImageSource imageSource = new CImageSource; // the class is implemented by the user
    batchProcessor.Start( imageSource, nullnullnull );
    // Start processing
    whiletrue ) {
     FREngine.IFRPage page = batchProcessor.GetNextProcessedPage();
     if( page == null ) {
      break// there are no more pages, end of the work
     }
     // do something with the page
     page.Synthesize( null );
     page.Export("D:\\sample.pdf", FREngine.FileExportFormatEnum.FEF_PDF, null);
    }

     

    Can you give me an example of a python version?

    thank you

    0
    Comment actions Permalink
  • Avatar
    Koen de Leijer

    Hi Xiaowu

    Questions about Python have been asked before, see:
    https://forum.ocrsdk.com/thread/python-module-library-for-engine-sdk/

    So far, the only way to work with Python is that you have to use the Cloud OCR solution,
    code-samples here: https://github.com/abbyysdk/ocrsdk.com/tree/master/Python

    We've already tried to get a Python-binding without success, and are now using the Java-API from Python;
    In our case we used the Django REST Framework and created a Java REST-servlet running in Tomcat doing the trick.

    Regards

    Koen de Leijer

    PS. See some of my other posts with code-samples in Java

    0
    Comment actions Permalink

Please sign in to leave a comment.