PowerModels generation and branch result data extraction

Dears

I’m working on the package PowerModels and I’m trying to extract results data for further manipulation. the problem that I have faced is regrading generation results and how to extract them in an accurate way. I have noticed that if a bus has more than one generator, the extracted data will not be in the same exact order as the original m file of the system. I would appreciate any information about how to extract generation and branch data with correct bus numbers from PowerModels.

Regards