raamana / neuropredict

Easy and comprehensive assessment of predictive power, with support for neuroimaging features

Home Page:https://raamana.github.io/neuropredict/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CSV export fails when numpy.matlib not properly imported

atheyers opened this issue · comments

Traceback (most recent call last):
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/reports.py", line 73, in export_results
    avg_cfmat, misclf_rate = visualize.compute_pairwise_misclf(confusion_matrix)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/visualize.py", line 337, in compute_pairwise_misclf
    avg_cfmat[dd, :, :] = mean_over_cv_trials(cfmat_array[:, :, :, dd], num_classes)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/visualize.py", line 314, in mean_over_cv_trials
    class_size_elementwise = np.transpose(np.matlib.repmat(np.sum(avg_cfmat, axis=1), num_classes, 1))
AttributeError: module 'numpy' has no attribute 'matlib'
Traceback (most recent call last):
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/reports.py", line 73, in export_results
    avg_cfmat, misclf_rate = visualize.compute_pairwise_misclf(confusion_matrix)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/visualize.py", line 337, in compute_pairwise_misclf
    avg_cfmat[dd, :, :] = mean_over_cv_trials(cfmat_array[:, :, :, dd], num_classes)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/visualize.py", line 314, in mean_over_cv_trials
    class_size_elementwise = np.transpose(np.matlib.repmat(np.sum(avg_cfmat, axis=1), num_classes, 1))
AttributeError: module 'numpy' has no attribute 'matlib'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/global/home/hpc4089/.local/bin/neuropredict", line 11, in <module>
    sys.exit(main())
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/__main__.py", line 11, in main
    run_workflow.cli()
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/run_workflow.py", line 967, in cli
    grid_search_level, classifier, feat_select_method)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/run_workflow.py", line 942, in prepare_and_run
    options_path=options_path)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/rhst.py", line 405, in run
    export_results(dict_to_save, out_results_dir, options_path)
  File "/global/home/hpc4089/.local/lib/python3.5/site-packages/neuropredict/reports.py", line 108, in export_results
    raise IOError('Unable to export the results to CSV files.')
OSError: Unable to export the results to CSV files.