-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
"segmentation fault python3" error when trying to import scikit-learn #23830
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I suspect it is because we set For testing, can you download this wheel file and run: pip install scikit_learn-1.2.dev0-cp39-cp39-macosx_10_9_x86_64.whl |
I uninstalled scikit-learn and then re-installed it in this way, but the result didn't change |
To capture the segfault, can you run: lldb python -- -c "import sklearn" which should bring you into a debugger. From there run "run": (lldb) run This should give you more information about the segfault. |
I got this error |
Having the debugger blocked by System Integrity Protection is unfortunate. For debugging, can you try to How did you install Python? Another option is to install Python with anaconda and install scikit-learn with conda. |
All other libraries work fine, included numpy and scipy. I think python was already installed |
Trying a different installation of Python is a way to narrow down the issue. Currently you have Python installed here:
I'm trying to see if the issue still happens when using anaconda's Python. |
Any results? |
My comment in #23830 (comment) was to explain why I suggest installing Python with anaconda for debugging. Can you to install Python with anaconda, install scikit-learn with anaconda's Python, and test it? I do not have access to a OSX machine running EDIT: I quick way to install conda's Python is to use miniconda |
I can't install miniconda since it's aviable only for macos version >=10.13. It would take hours to just download the anaconda file, so I think that I'm going to give up |
Describe the bug
When I try to import scikit-learn, I get a segmentation error. All the other libraries I try to use work fine.
Steps/Code to Reproduce
First I installed it using
pip3 install scikit-learn
, then I triedpip3 install sklearn
. Then I removed scikit-learn by typingpip3 uninstall scikit-learn
and re-installed it with the commandpip3 install -U scikit-learn
. It still doesn't work.Expected Results
The result I expected was that I could import the library with no problems
Actual Results
This is wat I get:
In addition there is a pop-up that says: "Python quit unexpectedly."
The report:
...
Versions
The text was updated successfully, but these errors were encountered: