Error for "sct_testing"

Hi, I am using Mac, installed the SCT , successfully run “$SCT_DIR/batch_processing.sh”. However, when I run “sct_testing” in the terminal, the message below showed up (4 failed and 1error). I wonder if anyone can help me fix this. Thank you. Not sure if it matters, I have previously installed FSL and AFNI on the same Mac laptop.

================================================================== short test summary info ==================================================================

FAILED …/…/…/testing/batch_processing/test_batch_processing.py::test_batch_processing_results[mt/mtr_in_wm.csv-0-MAP()] - assert 54.41599946382591 == 54.39462068731342 ± 5.4e-05

FAILED …/…/…/testing/batch_processing/test_batch_processing.py::test_batch_processing_results[dmri/fa_in_cst.csv-0-WA()] - assert 0.7807687333018286 == 0.7793857115174943 ± 7.8e-07

FAILED …/…/…/testing/batch_processing/test_batch_processing.py::test_batch_processing_results[dmri/fa_in_cst.csv-1-WA()] - assert 0.7746473188250437 == 0.7756883298906552 ± 7.8e-07

FAILED …/…/…/testing/cli/test_cli_sct_process_segmentation.py::test_sct_process_segmentation_no_checks - ValueError: Shape mismatch between vertfile [5] and metric [55]). Please verify that your vertfile has the same number of slices as your input image, an…

ERROR …/…/…/testing/dependencies/test_ants.py::test_ants_registration - AssertionError: assert not [(‘/Users/jialiu/sct_6.1/data/sct_testing_data/t2_seg-manual_labeled_discs.nii.gz’, ‘a782d7cf2c1b0dc2715ecf3f1e847c28’), ('/U…

======================================== 4 failed, 439 passed, 13 skipped, 40 warnings, 1 error in 449.70s (0:07:29) ========================================

Hi @Jia_Liu,

Thank you for reporting these test failures.

For the first three, we are aware of this issue (Discrepancies in `batch_processing.sh` results between Linux and macOS · Issue #3194 · spinalcordtoolbox/spinalcordtoolbox · GitHub).

For the fourth failure, I have not seen this issue before, and cannot reproduce on my end. Could you try starting with a fresh copy of the testing dataset, then re-run the test?

# Start with fresh copy
sct_download_data -d sct_testing_data
# Rerun the failing test
sct_testing "$SCT_DIR/testing/cli/test_cli_sct_process_segmentation.py"

Kind regards,
Joshua