gather_results#
- ams.routines.routine.gather_results(rtn: RoutineBase, data_dict: Dict, items: Dict, attr: str, *, group: bool = False)[source]#
Gather routine results into
data_dictfor export.Two output shapes, selected by
group:group=False(flat): one entry per device, keyedf'{key} {dev}', values rounded to 6 decimals. Used byRoutineBase.export_csv().group=True(nested by owner): one section perowner.class_namewith a sharedidxlist and one entry perkey. Used byRoutineBase.export_json().
- Parameters:
- rtnams.routines.routine.RoutineBase
The routine to gather results from.
- data_dictDict
The data dictionary to populate in place.
- itemsdict
Items to gather (typically
rtn.vars,rtn.exprs, orrtn.exprcs).- attrstr
Attribute to read from each item via
rtn.get().- groupbool, keyword-only
Output shape selector — see above.