0

I am doing a course on ML on Coursera. I am using graphlab for this course

When I execute the below line, my python gets crashed. Please help me in solving this. I have no clue why it crashes everytime

sf = graphlab.SFrame('people-example.csv')

Picture of Python crashing

ahairshi
  • 381
  • 3
  • 18

2 Answers2

1

What I had to do to fix this (on my firewalled Windows 10 system). First I completely uninstalled Anaconda2 and reinstalled it from scratch.

Second go to Turi, register and download the GraphLab license file.

Then in a browser go to pypi.python.org/simple/ and download the GraphLab-Create (currently file GraphLab_Create-2.1-py2.7.tar.gz)

Now open a CMD window as Administrator on your system.

Using the install license info (registration email and license number) from Turi run the command to install GraphLab License like so:

pip install --upgrade -U --no-cache-dir http://get.graphlab.com/GraphLab-Create/2.1/registrationemail@mail.com/F8DC-YOUR-LICEN-HERE-0000-0000-0000-000/GraphLab-Create-License.tar.gz --trusted-host get.graphlab.com

Now install the sources you downloaded from Python like this:

pip install --upgrade  -U --index-url=http://pypi.python.org/simple/ --trusted-host pypi.python.org   ./GraphLab_Create-2.1-py2.7.tar.gz

Finally open Python and run the following:

import graphlab as gl
gl.get_dependencies()
0

SFrame syntax requires that you use:

sf = graphlab.SFrame.read_csv('people-example.csv')

That should would, I'm not sure why python would crash as result of incorrect syntax.

J_Heads
  • 490
  • 2
  • 11
  • It crashes just like that – ahairshi Jul 06 '16 at 09:51
  • I was trying to read .gl, not csv Getting this every time - The kernel appears to have died. It will restart automatically. – ahairshi Jul 06 '16 at 09:57
  • In your example it looks like your trying to load a csv file. You may need to check what you file name is, remove '.csv', or potentialy add '.gl'. Additionally you need to use graphlab.load_sframe() instead of graphlab.SFrame(). – J_Heads Jul 06 '16 at 14:46
  • Same happens when i use the function load_sframe() – ahairshi Jul 12 '16 at 14:05