Json file with poor structring

I am working on json file that has many dictionaries of the format:


it is formed this way:


it seems that this is a wrong way of structuring it, is there a way to use it in this format or I have to edit it to make it look like this :


The question doesn’t seem to be related to PyTorch so you would most likely get a faster and better answer in another board (e.g. StackOverflow).
In any case, I would recommend to clean up your data once in order to avoid any issues further down in the training, which could yield unexpected results. pandas might come handy to process the data (in case it could load and understand it).

1 Like