Text

Answered

Writing recognition slows down

Hi,

Writing recognition slows down while writing on multiple editor engines.

Is there  any way to make faster recognition?



Best Answer

Dear Kannan,


currently, I just thought of the following way you may proceed:

-When there is a penup event, you start a timer (e.g. 500 ms)

-if before the timer expires, there is a pendown, you cancel the timer

-If the timer expires, i.e. there is no pendown, then you call the export

=>Finding the proper value for the timer, you may be able to export only when a word is finished, and proceed with less exports. Your application should therefore use less CPU.


Best regards,


Olivier


Answer

Dear Kannan,


currently, I just thought of the following way you may proceed:

-When there is a penup event, you start a timer (e.g. 500 ms)

-if before the timer expires, there is a pendown, you cancel the timer

-If the timer expires, i.e. there is no pendown, then you call the export

=>Finding the proper value for the timer, you may be able to export only when a word is finished, and proceed with less exports. Your application should therefore use less CPU.


Best regards,


Olivier

Hi,

Currently i want to call that Export function while they are writing each word.Because i have the custom DisplayViewcontroller.

I want to show the MyScript Displayviewcontroller's conversion words (With that word's position also) to My Custom DisplayViewcontroller.

So I want to call that function frequently.


Dear kannan,


currently, calling the "export" function is demanding, thus shall not be called for any event, as it will indeed, significantly slow down the iink


Currently, the question is why are you exporting so much? Could you give more insights, so that we may think of another way to proceed?


Best regards,


Olivier

Hi,

I have used Apple iPad 6th Gen 32 GB.(I think it is capable for running that function properly)

My Export function was,

 if let jsonText = try? editorViewController.editor.export_(editorViewController.editor.rootBlock, mimeType: IINKMimeType.JIIX){

 print( jsonText)

 }

I have call this function while writing the each and individual letter(Even put a single dot(.)).

At that time my writing view was lagged.When write the next letter that one was lagged for one sec.(I can't write anything at that time).

Even i put the export function in Main Thread but still writing area was lagged.

Main Thread function was,

DispatchQueue.main.asyn{

}

How can i make the export function more faster?

Dear Kannan,


Thank you for contacting us.


Indeed, our technology is very CPU demanding, and the more data is provided, the longer recognition will take. On our side, we have no way to make the recognition faster, except having a more powerful device.


Best regards,


Olivier