Reputation: 3359
So I have my data structured right.
{'start': '2017-05-02', 'target':[1,2,3,4,5], 'cat':[1,0,13], 'dynamic_feat':[[1,2,3,4],[4,3,2,1], [6,7,8,9]]}
But it's difficult to do all of the coding to train the DeepAR model. I've looked all over the internet to see if there's an easier way to do it (like using AutoPilot) but I haven't found anything. Can someone guide me in the right direction? I got close but I've had no luck whatsoever. It fail every time.
Also, I have more than one JSON object (it's actually a list of dictionaries). Is there even just an easier way to train the model using code that doesn't require a file in the S3 bucket?
Thanks for the help guys!
Upvotes: 0
Views: 172
Reputation: 348
Use Jsonlines and combine all jsons to a single file.
{"start": "2009-11-01 00:00:00", "target": [4.3, "NaN", 5.1, ...], "cat": [0, 1], "dynamic_feat": [[1.1, 1.2, 0.5, ...]]}
{"start": "2012-01-30 00:00:00", "target": [1.0, -5.0, ...], "cat": [2, 3], "dynamic_feat": [[1.1, 2.05, ...]]}
{"start": "1999-01-30 00:00:00", "target": [2.0, 1.0], "cat": [1, 4], "dynamic_feat": [[1.3, 0.4]]}
See in examples given by aws - https://github.com/aws/amazon-sagemaker-examples/blob/main/introduction_to_amazon_algorithms/deepar_electricity/DeepAR-Electricity.ipynb
Upvotes: 0