У меня есть файл jsonlines, который выглядит следующим образом:
{"id":123,"source":"this is a text string"}
{"id":456,"source":"this is another text string"}
{"id":789,"source":"yet another string"}
Когда я запускаю задание пакетного преобразования BlazingText для файла, который содержит только источник, это работает. При попытке объединить входы и выходы, я получаю Customer Error: Unable to decode payload: Incorrect data format. (caused by AttributeError)
.
Есть предложения?
Код:
bt_transformer = bt_model.transformer(
instance_count = 1,
instance_type = "ml.m4.xlarge",
assemble_with = "Line",
output_path = s3_batch_out_data,
accept = "application/jsonlines"
)
bt_transformer.transform(
s3_batch_in_data,
content_type = "application/jsonlines",
split_type = "Line",
input_filter = "$.source",
join_source = "Input",
output_filter = "$['id', 'SageMakerOutput']"
)
bt_transformer.wait()