Closed jacky0218 closed 1 day ago
Thank you for your feedback. Tagging and routing to the team member best able to assist.
@jacky0218 thanks for your feedback, @YalinLi0312 will take a look and get back to you as soon as possible. Can I ask how you're measuring speed between sync and async?
@kristapratico Thanks for the support. I've tested a 5-page PDF, and the speed from sync is 11.322867231443524. Async yields a speed of 11.022184098139405.
Hi @jacky0218
AIO programming means that the HTTP IOs under the hood are managed using async/await and an asyncio event loop, in order to avoid blocking code on sockets. If the Azure service needs 11 seconds to process your PDF, you can't finish faster than what the service will do, you just do a better usage of your local CPU and socket usage with aio. Therefore, the times you got here sounds reasonable given your limitation is service related, not Python related. To say it differently, if you run the same PDF through C# or Java SDK, you will still get 11 seconds, since the SDK is just a messenger here and there isn't heavy processing done by the SDK in this specific scenario.
Hi @jacky0218. Thank you for opening this issue and giving us the opportunity to assist. We believe that this has been addressed. If you feel that further discussion is needed, please add a comment with the text "/unresolve" to remove the "issue-addressed" label and continue the conversation.
Hi @jacky0218, since you haven’t asked that we /unresolve
the issue, we’ll close this out. If you believe further discussion is needed, please add a comment /unresolve
to reopen the issue.
Describe the bug The AIO version runs no faster than without AIO
To Reproduce I just followed the code example as below. (https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/documentintelligence/azure-ai-documentintelligence/samples/aio/sample_analyze_general_documents_async.py)
Expected behavior AIO-level speed.