SFrame connection

595 Views Asked by At

I am taking the ML course from Coursera. I had an error when I had to call SFrame. The same problem was asked around 2 years ago. The problem was when I had to type the sf because I had the following message:

import graphlab
sf = graphlab.SFrame('people-example.csv')
AttributeError Traceback (most recent call last) in ()

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

AttributeError: 'module' object has no attribute 'SFrame'

A solution came up stating that everyone had to do this to solve it:

In your iPython/Jupyter notebook follow these steps in this particular order.

This will download and install dependencies. graphlab.get_dependencies()

Restart Kernel : Kernel > Restart

Now import graphlab: import graphlab

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

Now that I have done all this procedure I face problems. Moreover, now that I try to do the same I get a message:

sf = graphlab.SFrame('people-example.csv')
---------------------------------------------------------------------------
InvalidProductKey                         Traceback (most recent call last)
<ipython-input-2-4df0be298ea8> in <module>()
----> 1 sf = graphlab.SFrame('people-example.csv')

C:\Users\Thanos\Anaconda2\envs\gl-env\lib\site-packages\graphlab\data_structures\sframe.pyc in __init__(self, data, format, _proxy)
    864             self.__proxy__ = _proxy
    865         else:
--> 866             self.__proxy__ = UnitySFrameProxy(glconnect.get_client())
    867             _format = None
    868             if (format == 'auto'):

C:\Users\Thanos\Anaconda2\envs\gl-env\lib\site-packages\graphlab\connect\main.pyc in get_client()
    137     """
    138     if not is_connected():
--> 139         launch()
    140     assert is_connected(), ENGINE_START_ERROR_MESSAGE
    141     return __CLIENT__

C:\Users\Thanos\Anaconda2\envs\gl-env\lib\site-packages\graphlab\connect\main.pyc in launch(server_addr, server_bin, server_log, auth_token, server_public_key)
     89         if server:
     90             server.try_stop()
---> 91         raise e
     92     server.set_log_progress(True)
     93     # start the client

InvalidProductKey: Product key validation failed.

How can I fix this error? Thank you

1

There are 1 best solutions below

0
On

The (second) message clearly implies that you have not obtained a license for using Graphlab Create.

Graphlab Create is not free; however, Coursera students are eligible for academic licenses, which are free for 1 year (I am surprised if this fact is not clearly mentioned in the course materials), from the following link:

Register for Academic Use of GraphLab Create

After obtaining your licence key, you should install Graphlab Create with

# Install your licensed copy of GraphLab Create
pip install --upgrade --no-cache-dir https://get.graphlab.com/GraphLab-Create/2.1/your registered email address here/your product key here/GraphLab-Create-License.tar.gz

See the installation instructions for more details.