I've tested image recognition with own demo app (with captured frame) and also with OrcSdkDemo.

Both returns empty response data (tested with simple text or numbers in white background).

I also noticed that while downloading result the (BOOL)connection:(NSURLConnection *)connection canAuthenticateAgainstProtectionSpace:(NSURLProtectionSpace *)protectionSpace function returns false (both apps).

Is that a expected behavior or not?

Some sample log output from OrcSdkDemo app:

OcrSdkDemo[2674:907] connection didReceiveResponse: 200
OcrSdkDemo[2674:907] connection didReceiveData: 
  <?xml version="1.0" encoding="utf-8"?>
  <response>
    <task id="*****" registrationTime="2013-04-24T06:15:17Z"
       statusChangeTime="2013-04-24T06:15:38Z" status="InProgress"
       filesCount="1" credits="5" estimatedProcessingTime="10" />
  </response>
OcrSdkDemo[2674:907] Waiting for image processing complete...
OcrSdkDemo[2674:907] connection didReceiveResponse: 200
OcrSdkDemo[2674:907] connection didReceiveData: 
  <?xml version="1.0" encoding="utf-8"?>
  <response>
     <task id="*****" registrationTime="2013-04-24T06:15:17Z"
        statusChangeTime="2013-04-24T06:17:17Z" status="Completed"
        filesCount="1" credits="5" resultUrl="*****" />
  </response>
OcrSdkDemo[2674:907] connection canAuthenticateAgainstProtectionSpace NOK
OcrSdkDemo[2674:907] connection didReceiveResponse: 200
OcrSdkDemo[2674:907] connection didReceiveData:

Some more info, even though canAuthenticateAgainstProtectionSpace fails, the recognition seems to work (tried another test paper with text&numbers).

The first text & numbers where hand written and the paper quality was poorer, which may explain the empty result.

asked 24 Apr '13, 10:39

mikan's gravatar image

mikan
1112

edited 25 Apr '13, 14:52

Dmitry%20Me's gravatar image

Dmitry Me ♦♦
2387

What's the implementation of canAuthenticateAgainstProtectionSpace, what comes as the input parameter and how exactly does the implementation return false?

(25 Apr '13, 15:04) Dmitry Me ♦♦

I used OrcSDKDemo app (for iOS) with just additional logging.

No is returned from HTTPOperation.m by NSURLConnectionDelegate.

(25 Apr '13, 16:01) mikan

Does control pass through return NO; line?

(26 Apr '13, 18:29) Dmitry Me ♦♦

Yes, it does. And it seems to happen always, when downloading result.

(29 Apr '13, 09:43) mikan

Okay, here's what's going on. The code is incomplete (it's not you, it's us) - control passes through return NO; only when authenticationDelegate is nil, but authenticationDelegate is not set anywhere in the code. Nothing to worry about however - returning NO from there causes default SSL certificate verification which is okay. I opened an issue on Github to have this fixed - https://github.com/abbyysdk/ocrsdk.com/issues/9

(29 Apr '13, 16:54) Dmitry Me ♦♦
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×1

Asked: 24 Apr '13, 10:39

Seen: 4,758 times

Last updated: 29 Apr '13, 16:57

Related questions

© 2016 ABBYY. All rights Reserved. www.ABBYY.com | Privacy Policy | Legal