skip to Main Content

I am working with Form Recognizer in Python (version 3.2.1). I’m attempting to train a custom model with pdf’s in Azure storage container, code and error below:

document_model_admin_client = DocumentModelAdministrationClient(endpoint, credential)

poller = await document_model_admin_client.begin_build_document_model(
    ModelBuildMode.TEMPLATE, blob_container_url="[PATH TO AZURE STORAGE CONTAINER]"
)
model = await poller.result()

`

Getting this error below begin_build_document_model():


HttpResponseError: (InvalidRequest) Invalid request.
Code: InvalidRequest
Message: Invalid request.
Inner error: {
    "code": "TrainingContentMissing",
    "message": "Training data is missing: Could not find any training data at the given path."
}

Any insight into what may be causing this? Already gave permissions on the storage accounts.

2

Answers


  1. I am facing the same error as you as I was trying out the notebook from (1) and modifying pieces based on newer version code found in (2) under "Build a Custom Model".

    (1) https://github.com/Azure-Samples/azure-search-power-skills/tree/main/Vision/AnalyzeFormV2

    (2) https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/formrecognizer/azure-ai-formrecognizer


    Separately, the older version codes dont work either as it keeps giving error below:

    HttpResponseError: (2012) Managed Identity credential was rejected by the storage service.
    Invalid model created with ID=xxxxxxxxxxxxxx
    

    even though access was provided as well.

    Hope someone can share a resolution soon.

    Login or Signup to reply.
  2. This came out yesterday and the portal version works. Looks like Form Recognizer in Azure portal has shifted to Document Intelligence. Try this and hope it helps!

    https://learn.microsoft.com/en-us/azure/ai-services/document-intelligence/quickstarts/try-document-intelligence-studio?view=doc-intel-3.0.0

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search