Project-MONAI / MONAI

AI Toolkit for Healthcare Imaging
https://monai.io/
Apache License 2.0
5.73k stars 1.05k forks source link

TypeError: regionprops() got an unexpected keyword argument 'coordinates' #6084

Closed wyli closed 1 year ago

wyli commented 1 year ago
[2023-03-01T01:56:26.191Z] ======================================================================
[2023-03-01T01:56:26.191Z] ERROR: test_read_patches_cucim_0 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.191Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.191Z] Traceback (most recent call last):
[2023-03-01T01:56:26.191Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.191Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.191Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.191Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.191Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.191Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.191Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.191Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.191Z] 
[2023-03-01T01:56:26.191Z] ======================================================================
[2023-03-01T01:56:26.191Z] ERROR: test_read_patches_cucim_1 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.191Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.191Z] Traceback (most recent call last):
[2023-03-01T01:56:26.191Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.191Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.191Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.191Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.191Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.191Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.191Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.191Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.191Z] 
[2023-03-01T01:56:26.191Z] ======================================================================
[2023-03-01T01:56:26.191Z] ERROR: test_read_patches_cucim_2 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.191Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.191Z] Traceback (most recent call last):
[2023-03-01T01:56:26.191Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.191Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.191Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.191Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.191Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.191Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.191Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.191Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.191Z] 
[2023-03-01T01:56:26.191Z] ======================================================================
[2023-03-01T01:56:26.191Z] ERROR: test_read_patches_cucim_3 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.191Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.191Z] Traceback (most recent call last):
[2023-03-01T01:56:26.191Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.191Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.191Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.191Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.191Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.191Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.191Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.191Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.191Z] 
[2023-03-01T01:56:26.191Z] ======================================================================
[2023-03-01T01:56:26.191Z] ERROR: test_read_patches_cucim_4 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.191Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.191Z] Traceback (most recent call last):
[2023-03-01T01:56:26.191Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.191Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.191Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.191Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.192Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.192Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.192Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.192Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.192Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.192Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.192Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.192Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.192Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.192Z] 
[2023-03-01T01:56:26.192Z] ======================================================================
[2023-03-01T01:56:26.192Z] ERROR: test_read_patches_cucim_5 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.192Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.448Z] Traceback (most recent call last):
[2023-03-01T01:56:26.448Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.448Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.448Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.448Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.448Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.448Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.448Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.448Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.448Z] 
[2023-03-01T01:56:26.448Z] ======================================================================
[2023-03-01T01:56:26.448Z] ERROR: test_read_patches_cucim_6 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.448Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.448Z] Traceback (most recent call last):
[2023-03-01T01:56:26.448Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.448Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.448Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.448Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.448Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.448Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.448Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.448Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.448Z] 
[2023-03-01T01:56:26.448Z] ======================================================================
[2023-03-01T01:56:26.448Z] ERROR: test_read_patches_cucim_7 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.448Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.448Z] Traceback (most recent call last):
[2023-03-01T01:56:26.448Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.448Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.448Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.448Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.448Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.448Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.448Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.448Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.448Z] 
[2023-03-01T01:56:26.448Z] ======================================================================
[2023-03-01T01:56:26.448Z] ERROR: test_read_patches_cucim_8 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.448Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.448Z] Traceback (most recent call last):
[2023-03-01T01:56:26.448Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.448Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.448Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.448Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.448Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.448Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.448Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.448Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.448Z] 
[2023-03-01T01:56:26.448Z] ======================================================================
[2023-03-01T01:56:26.448Z] ERROR: test_read_patches_cucim_9 (tests.test_lesion_froc.TestEvaluateTumorFROC)
[2023-03-01T01:56:26.448Z] ----------------------------------------------------------------------
[2023-03-01T01:56:26.448Z] Traceback (most recent call last):
[2023-03-01T01:56:26.448Z]   File "/usr/local/lib/python3.8/dist-packages/parameterized/parameterized.py", line 533, in standalone_func
[2023-03-01T01:56:26.448Z]     return func(*(a + p.args), **p.kwargs)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_lesion_froc.py", line 324, in test_read_patches_cucim
[2023-03-01T01:56:26.448Z]     froc_score = froc.evaluate()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 161, in evaluate
[2023-03-01T01:56:26.448Z]     fp_probs, tp_probs, num_targets, num_images = self.compute_fp_tp()
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 139, in compute_fp_tp
[2023-03-01T01:56:26.448Z]     ground_truth, itc_labels = self.prepare_ground_truth(sample)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/metrics/lesion_froc.py", line 122, in prepare_ground_truth
[2023-03-01T01:56:26.448Z]     itc_labels = compute_isolated_tumor_cells(tumor_mask=tumor_mask, threshold=itc_threshold)
[2023-03-01T01:56:26.448Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/monai/apps/pathology/utils.py", line 55, in compute_isolated_tumor_cells
[2023-03-01T01:56:26.448Z]     properties = measure.regionprops(tumor_mask, coordinates="rc")
[2023-03-01T01:56:26.448Z] TypeError: regionprops() got an unexpected keyword argument 'coordinates'
[2023-03-01T01:56:26.448Z] 
[2023-03-01T01:56:26.448Z] ----------------------------------------------------------------------
wyli commented 1 year ago

the parameter is deprecated in scikit-image 0.20 https://github.com/scikit-image/scikit-image/pull/6583

'The coordinates keyword argument to skimage.measure.'
                   'regionprops is deprecated. All features are now computed '
                   'in rc (row-column) coordinates. Please remove '
                   '`coordinates="rc"` from all calls to regionprops before '
                   'updating scikit-image.'