Due to restrictions in my AWS account, I need to create the labeling job manifest file manually for GroundTruth labeling job. However the manifest file fails parsing even though the file seems to be as per JSONL standards - https://jsonlines.org/
'The S3 Input location is verified as accessible by your IAM execution role. However, there was an issue parsing your input manifest file. Do the following: Check that your input manifest follows JSON Lines format. Update your input manifest file and try your request again.'
I'm generating the JSONL files using below python code
items = [{"source-ref": "s3://bucket/file3.jpg"},
{"source-ref": "s3://bucket/file2.jpg"},
{"source-ref": "s3://bucket/file1.jpg"}]
import json
with open('labeling-job.jsonl', 'w', encoding='utf8') as outfile:
for entry in items:
json.dump(entry, outfile, ensure_ascii=False)
outfile.write('\r\n')
Could someone point out what I am doing wrong here?
Relatively late to answer to my query. The issue was wrt the role policy restrictions in my account and nothing related to the jsonl that was created by my snippet above. Needless to say the exception message from AWS was really misleading and not helpful at all.