Search code examples
pythonpipscikit-survival

Problem installing scikit-survival in Google Colab


I am facing a problem to install scikit-survival in Google Colaboratory. Everytime it says:

pip install scikit-survival
Collecting scikit-survival
  Using cached https://files.pythonhosted.org/packages/91/f0/047ce90bb831ab34ca287d1d23f0c61b6546cd89494566898c0e17516990/scikit-survival-0.15.0.post0.tar.gz
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
ERROR: Command errored out with exit status 1: /usr/bin/python3 /usr/local/lib/python3.7/dist-packages/pip/_vendor/pep517/_in_process.py get_requires_for_build_wheel /tmp/tmpncdknf_f Check the logs for full command output.

However, I don't get the Error. I've installed the newest Python version and any other pip install command works. Does anyone has an idea?

Kind regards, Hashriama


Solution

  • The error is with different versioning and something related to it. Try the following in Colab.

    !pip install --upgrade pip
    !pip uninstall --yes --quiet osqp
    !pip install -U scikit-survival
    

    This should do the job.