PlantCV v3.9.0
Version 3.9 updates:
plantcv.morphology.find_tips
andplantcv.morphology.find_branch_pts
now saves observations (a list of coordinates of the relevant points identified from a skeleton image) to the Outputs class.- Reworked the
plantcv.color_palette
function to use matplotlib colormaps instead, so users now have a wide range of coloring options.- Added three new parameters to
pcv.params
to controlcolor_palette
(and functions that use it). The parameters arecolor_scale
: the name of the colormap,color_sequence
: "sequential" or "random", andsaved_color_scale
: stores the last color scale. The latter is important for the morphology functions to plot results correctly as the colors of the segments need to get reused to match up from function to function.
- Added three new parameters to
- Add
plantcv.morphology.analyze_stem
- This function measures stem height, length, and angle from sorted segments of a skeletonized plant.
- Plots debug image that shows detected height and angle
- Internal updates to the
plantcv.transform.find_color_card
function- Updates to the contour sorting algorithm to compensate for changes in the outputs of the OpenCV function
cv2.minAreaRect
in version 3.4.10. Their updates were having implications in the sensitivity of the PlantCV algorithm and causing colorcards to stop being identified in example images. - This function now also stores observations to the Outputs class for the mean/median (user defined) color chip area, height, and width. This functionality should remove the need to to include a size marker for scaling measurements in images that already have a color card.
- Updates to the contour sorting algorithm to compensate for changes in the outputs of the OpenCV function
- Updates the documentation and README file to fix a few typos/formatting issues and update some content for relevance to the current version of PlantCV.
- Update/bugfix to
plantcv.hyperspectral.calibrate
- There was a mistake in the calibration code that resulted in the actual algorithm differing slightly from the proposed (raw-dark)/(white-dark).
- Now also truncate any negative values to 0
- PEP8 and other miscellaneous code cleanup to clear the way for GitHub Actions
- Replace prior continuous integration platform with GitHub Actions
- Add
plantcv.spatial_clustering
- New function that segments features of images based on their distance from each other.
- Takes a binary mask, minimum number of clusters, which algorithm to use (either “DBSCAN” or “OPTICS”), the maximum distance between two pixels before they can be considered part of the same cluster, and outputs a clustered image as well as the masks of each cluster.
- Update Dockerfile recipe to fix missing libGL dependency, which was causing an ImportError
- Update
plantcv.hyperspectral.read_data
, which is used ifmode=”ENVI”
duringplantcv.readimage
so that we now set a default wavelength units to “nm” to enable more flexibility in the image files that we can read in. - Bugfix to the data getting saved out to the
hue_circular_std
observation while runningplantcv.analyze_color
. - Add summary statistics to the observations recorded while running
plantcv.analyze_nir
so they now include mean, median, and stdev observations in the Outputs class while running NIR workflows. - Update the order of debug images plotted to match the order of outputs in
plantcv.rectangle_mask
andplantcv.threshold.*
. - Updated and improved documentation for the machine learning tutorial.
- Update
plantcv.threshold.custom_range
to be R,G,B instead of B,G,R - Added many new indices and completely restructured the spectral index family of options into their own functions beneath the
spectral_index
sub-package.- See here for the latest list of supported spectral indices.
- Add
plantcv.visualize.auto_threshold_methods
which aims to assist in streamlining workflow development. - Update input parameter in the function
plantcv.threshold.custom_range
fromrgb_img
toimg
since the function also works on grayscale images. - Internal enhancements to the
plantcv.hyperspectral.extract_index
to significantly increase speed and decrease memory needed for hyperspectral workflows. - Add
plantcv.stdev_filter
- Creates a grayscale image of pixel-wise standard deviation from a grayscale input image
- Made two small updates to
plantcv.utils.sample_images
- Removes newline characters from each row of
SnapshotInfo.csv
- Only appends rows of
SnapshotInfor.csv
to a list for random sampling if the row has image data records
- Removes newline characters from each row of
- Removed a Non-ascii character causing an error.
Version 3.9 breaking changes:
- Update input parameter in the function
plantcv.threshold.custom_range
fromrgb_img
toimg
since the function also works on grayscale images. - Removed
plantcv.hyperspectral.extract_index
and replaced it with theplantcv.spectral_index
subpackage (see above).