plantcv
plantcv copied to clipboard
Color_clustering_alhorithm
contains the scripts for the functionsto automatically segment images by color. There are two scripts: color_cluster_train (in the learn subpackage) which trains the model that does the segmentation and color_cluster_segmentation which does the actual segmenting.
Purpose Adds new functionalities.
Hi @SethPolydore, I suggest refactoring the line causing the error in the tests.py
file to:
spmask = pcv.color_clustering_segmentation(img=img, project_name=os.path.join(TEST_DATA, "temp_testing_multi"))
os.path.join
will use the appropriate OS-specific file path separators.
Codecov Report
Merging #592 (56c21cb) into master (260aa20) will decrease coverage by
0.35%
. The diff coverage is92.20%
.
@@ Coverage Diff @@
## master #592 +/- ##
===========================================
- Coverage 100.00% 99.64% -0.36%
===========================================
Files 142 144 +2
Lines 6482 6790 +308
===========================================
+ Hits 6482 6766 +284
- Misses 0 24 +24
Flag | Coverage Δ | |
---|---|---|
unittests | 99.64% <92.20%> (-0.36%) |
:arrow_down: |
Flags with carried forward coverage won't be shown. Click here to find out more.
Impacted Files | Coverage Δ | |
---|---|---|
plantcv/plantcv/__init__.py | 100.00% <ø> (ø) |
|
plantcv/plantcv/color_clustering_segmentation.py | 89.38% <89.38%> (ø) |
|
plantcv/learn/color_clustering_train.py | 93.78% <93.78%> (ø) |
|
plantcv/learn/__init__.py | 100.00% <100.00%> (ø) |
|
plantcv/__init__.py | 100.00% <0.00%> (ø) |
Hmm I added another two tests to try to cover L53 in gmm.py
and L47 in gmm_classifier.py
but when I try to test them locally they get hung up on the case where remove
is empty. I think I need to do more testing in Jupyter to see why it freezes up under these additional tests.
Archiving