P-TRAP architecture and the processing pipeline. The input images and the software options are provided by the user. These images are then binarized and passed to the graph and particle processing modules to identify the structure and the grains on the panicle. The resulting graphs and particles are stored in separate XML files for visualization and additional editing. These editors are part of the Workspace module, which translates the XML files into editable widgets supported by the WidgetFactory GUI helper module. The user can easily edit these visual widgets and send the changes back to the XML files for storage. All interactions between the user and the system are performed using the Workspace module. The final reports are based on the contents of the XML files. The contents of these reports are stored in CSV files with different levels of detail.