Analyze Stem Objects¶
Primary, or stem, objects identified during workflows that examine the morphology of plants or plant organs can have specific characteristics measured about the stem segments of a skeleton.
- rgb_img - RGB image data for plotting.
- stem_objects - List of stem segments (output from segment_sort function)
- Used to output stem morphological characteristics, including height, angle, and length.
Output data stored: Data ('stem_angle', 'stem_height', and 'stem_length') automatically gets stored to the
Outputsclass when this function is ran. All data stored in the Outputs class gets printed out while running print_results but these data can always get accessed during a workflow. For more detail about data output see Summary of Output Observations
from plantcv import plantcv as pcv # Set global debug behavior to None (default), "print" (to file), # or "plot" (Jupyter Notebooks or X11) pcv.params.debug = "print" stem_debug_img1 = pcv.morphology.analyze_stem(rgb_img=img1, stem_objects=stem_objects1) stem_debug_img2 = pcv.morphology.analyze_stem(rgb_img=img2, stem_objects=stem_objects2) # Access data stored out from analyze_object stem_angle = pcv.outputs.observations['stem_angle']['value']
Image 1 with identified stem characteristics
Image 2 with identified stem characteristics
Source Code: Here