Showing posts with label Coursera. Show all posts
Showing posts with label Coursera. Show all posts

Logistic Regression - Machine Learning with Python - IBM AI Engineering certificate program on Coursera

 

Intro to Logistic Regression

https://www.coursera.org/learn/machine-learning-with-python/lecture/eySE4/intro-to-logistic-regression


  • Logistic Regression is a statistical and Machine Learning algorithm to classify data in the dataset.
  • it is similar to linear regression, but it takes categorical (discrete) target fields instead the numeric continuous values.
  • The classification can b binary (i.e. yes, no), or multi-class.
  • Logistic Regression gives the probability of a given class
  • The independent variables (features, x) should be continuous (i.e 0.0 .. 1.0)
  • The dependent variable (the label, y) should be categorical (i.e. TRUE, FALSE, MAYBE)

What are the applications of Logistic Regression?
  • a chance of mortality
  • a likelihood of propensity to purchase a product
  • a probability for the failure of a process or a product
  • a likelihood of default on a loan 
When should I use Logistic Regression?

  • If the data is binary (i.e. 0/1, Yes/No, True, False)
  • If you need probabilistic results
  • When you need a decision boundary (linear, polynomial, or more complex hyperplane)
  • if you need to understand the impact of the features





As an Amazon Associate I earn from qualifying purchases.

Decision Trees - Machine Learning with Python - IBM AI Engineering certificate program on Coursera

NOTE: This is a continuation of the:
"IBM AI Engineering certificate program on Coursera - Machine Learning with Python"



I am also maintaining a PRIVATE Jupyter notebook on GitHub:



Please note that the Mathematic formulas (LaTex script) DO NOT show on the MOBILE phone, to read this post please use the desktop Chrome browser.

All images, unless otherwise marked, are copyrighted by IBM Developer Skills Network.



Introduction to Decision Trees


It is built by splitting the training set into distinct nodes. One node in a Decision Tree contains all of, or most of, one category of the data.





  • internal node - the test
  • branch node - the result of the test
  • leaf node - the assigned classification


Building Decision Trees

How to create a decision tree?

Use recursive partitioning by using the most predictive feature:
  1. choose an attribute from the dataset
  2. calculate the significance of the attribute in splitting data
  3. split the data based on the value of the best attribute
  4. go back to step 1

The pure nodes are those that contain the same type of category.
The impurity of nodes is calculated by the entropy of the data.
The entropy is the amount of randomness or uncertainty, the lower the entropy, the less uniform the distribution, and the purer (homogenous) the node. Homogenous has entropy = 0.

Entropy in a node is the amount of information disorder calculated in each node.

Use the frequency table calculated by the entropy formula:

$$ entropy = - p(A) log_2(p(A)) - p(B) log_2(p(B)) $$

Where
  • p is the proportion or ratio of the category A or B

Which tree has less entropy after splitting?
Choose the tree with the higher information gain after splitting.

$$ information \ gain = (entropy \ before \ the \ split) - ( weighted \ entropy \ aftersplit) $$







As an Amazon Associate I earn from qualifying purchases.

Regression - Machine Learning with Python - IBM AI Engineering certificate program on Coursera

Machine Learning with Python



Please note that the Mathematic formulas (LaTex script) DO NOT show on the MOBILE phone, to read this post please use the desktop Chrome browser.

All images are copyrighted by IBM.




Definitions:

Machine learning is a subfield of computer science that gives "computers the ability to learn without being explicitly programmed."

Machine Learning tries to train on a large quantity of data and derive solutions to cases not encountered during the training.

AI, a subset of machine Learning, tries to make computers intelligent with vision, language, creativity, etc.

Deep Learning is a subset of AI, where computers learn and make decisions on their own.




The course covers:
  • Regression / Estimation
    • predicting continuous values
  • Classification
    • predicting the item class or category
  • Clustering
    • finding the structure of the data, summarization
  • Association
    • finding co-occurring items or events
  • Anomaly detection
    • discovering abnormal or unusual cases
  • Sequence mining
    • predicting next events; e.g. click stream (Markov Model, HMM)
  • Dimension Reduction
    • reducing the size of the data (PCA)
  • Recommendation Systems
    • discovering preferences
Software tools:
  • Scikit Learn
    • algorithms for machine learning
  • SciPy
    • signal processing, optimization, statistics, etc.
  • NumPy
    • arrays, dictionaries, data structures, etc.
  • MatPlotLib
    • 2D and 3D plotting
  • Pandas
    • high-performance data structures, data importing, manipulation, and analysis, numerical tables and time-series
Projects:
  • Cancer detection
  • Economic trends
  • Customer churn
  • Recommendation engines
  • more

Example:

Benign or malignant?


Pipeline:

  1. Data Preprocessing
  2. Train vs Test data split
  3. Algorithm Setup
  4. Model Fitting
  5. Prediction
  6. Evaluation
  7. Model Export
scikit-learn functions


Supervised vs Unsupervised Algorithms

Supervised learning is using a "labeled" data set.
data column = feature
data row = observation

There are 2 types of "supervised" learning:
  • Classification
  • Regression






The unsupervised model draws conclusions on unlabeled data.


Unsupervised techniques:
  • Dimension reduction
  • Density estimation
  • Market basket analysis
  • Clustering
    • Discovering structure
    • Summarization
    • Anomaly detection


 

Linear Regression

Introduction to Regression




Simple Linear Regression



Data:
  • X: independent variable
    • explanatory variables
    • can be measured on a categorical or continuous scale
  • Y: dependent variable 
    • which we try to predict
    • needs to be continuous and cannot be a discrete value
Types of regression models:
  • Simple regression  (1 feature vs the dependent variable)
    • simple linear regression
    • simple non-linear regression
  • Multiple regression   (comparing 2+ features)
    • multiple linear regression
    • multiple non-linear regression 
Applications:
  • sales forecasting
  • satisfaction analysis
  • price estimation
  • employment income
Regression algorithms:
  • ordinal regression
  • poison regression
  • fast forest quantile regression
  • Linear, Polynomial, Lasso, Stepwise, Ridge regression
  • Bayesian linear regression
  • Neural network regression
  • Boosted decision tree regression
  • KNN (K-nearest neighbors)
Fit line:
  • it is a polynomial written as $ ŷ=\theta_0 + \theta_1 x_1  $ 
    • where 
      • y is a particular, observed, dependent variable (i.e. emissions )
      • $ \hat{y} $, or y "hat" is the response variable or predicted value (ideal value on fitted regression line)
      • $  \theta_0 $ y-intercept of the line
      • $ \theta_1 $ is the slope or gradient of the line
      • $  x_1  $ is the independent variable or a single predictor (i.e engine size in liters)
      • $ \theta_0  $ and $  \theta_1 $ are also called the coefficients of the equation

Error

The difference between the ŷ and y is the error.

The mean of the squared sum of errors (differences) formula:

$$ MSE = \frac{1}{n} \sum_{i=1} ^{n} \left( y_i - ŷ_i \right)^2 $$

Objective:
We have to find the best parameters $ \theta_0 $ and $ \theta_1 $ to minimize the MSE

Options to find $ \theta_0 $ and $ \theta_1 $:
  • mathematical approach
  • optimization approach


$$
\theta_1 =
\frac{
\sum_{i=1} ^{s}
\left( x_i - \bar{x} \right) 
\left( y_i - \bar{y} \right) 
}{
\sum_{i=1} ^{s}
\left( x_i - \bar{x} \right)^2 
}
$$

where:
  • s = n  , or number of observations (rows in the table)
  • $ \bar{x} = \frac{\sum_{i=1} ^{n} \left( x_i \right)  }{n}  $ or, x "bar" is mean of x
  • $ \bar{y} = \frac{\sum_{i=1} ^{n} \left( y_i \right)  }{n}  $ or,  y "bar" is mean of y


Conclusions for Linear Regression:
  • very fast
  • no parameter tuning
  • easy to interpret

Model Evaluation in Regression Models


Calculate the Error:

$$
\hat{y} =
\frac{1}{n} 
\sum_{j=1}^{n}   
|    y_j - \hat{y}_j     |
$$

Understanding the difference:
  • train and test on the same data
    • High training accuracy is not necessarily a good thing
    • Overfitting
      • memorized the input to output data and produced a non-generalized model
      • aka: rote learning
      • provides bad results for the input data that the model was not trained on
  • train and test on the split data



Wrong "Out of Sample Accuracy" is the percentage of correct predictions that the model makes on data that the model has NOT been trained on.

"Out of Sample Accuracy" is the accuracy of an overly trained model (which may capture noise and produced a non-generalized model)

Evaluation:
  • testing on the portion of the test data (not split, not randomized)
    • high "training accuracy"
    • low "out of sample" accuracy
  • testing on the split data (randomized)
    • more accurate evaluation for "out of sample" accuracy
    • highly dependent on which data is selected

K-fold cross-validation





Evaluation Metrics in Regression Models

https://www.coursera.org/learn/machine-learning-with-python/lecture/5SxtZ/evaluation-metrics-in-regression-models

Error definition:
The difference between observed data points ($ y_i $) and the fitted trend (regression) line values ($ \hat{y} $).

Mean Absolute Error (MAE):    
  • easy to understand

$$
MAE =
\frac{1}{n}
\sum_{j=1}^{n}
    | \hspace{0.5em}
      y_j - \hat{y}_j
    \hspace{0.5em} |
$$

Mean Squared Error (MSE):
  • more commonly used
  • stresses the large errors, exponentially increasing them (hence $ error^2 $)

$$
MSE =
\frac{1}{n}
\sum_{j=1}^{n}
    \left(
      y_j - \hat{y}_j
    \right)^2
$$

Root Mean Squared Error (RMSE):
  • MOST commonly used
  • interpretable in the same units as the response vector, or y-units, easy to relate the information

$$
RMSE =
\sqrt{
  \frac{1}{n}
  \sum_{j=1}^{n}
      \left(
        y_j - \hat{y}_j
      \right)^2
}
$$


Relative Absolute Error (RAE):
  • aka: residual sum of squares
  • normalizes the value by dividing the derived error by the mean error
$$
RAE =
\frac
{
  \sum_{j=1}^{n}
      |
        y_j - \hat{y}_j
      |
}{
  \sum_{j=1}^{n}
      |
        y_j - \bar{y}
      |
}
$$


Relative Absolute Error (RSE):
  • widely used by the data community to calculate $ R^2 $
    • $ R^2 = 1- RSE $
    • it is a popular metric of your model: shows how close the data values are to the fitted regression line
    • the higher the $ R^2 $ the better the model fits your data
$$
RAE =
\frac
{
  \sum_{j=1}^{n}
      \left(
        y_j - \hat{y}_j
      \right)^2
}{
  \sum_{j=1}^{n}
      \left(
        y_j - \bar{y}
      \right)^2
}
$$

You should do your own investigation of when to use each error estimation method.


Lab: Simple Linear Regression (1hr)




At this point, I decided that adding about 1 hour of setup work will be beneficial in the long run:
_REPOS/UoL_CS/IBM_AI_Eng/ML_Python/ML0101EN-Reg-Simple-Linear-Regression-Co2.ipynb


Multiple Linear Regression


When should I use Multiple Linear Regression?

- When there are multiple dependent variables and EACH independent variable has a linear correlation with the dependent variable.


  • Most of the applications of Linear Regression use multiple variables.
$$  \hat{y} = \theta_0 + \theta_1 x_1 + \theta_2 x_2 + ... + \theta_n x_n $$
$$  \hat{y} = \theta^T  X $$
$$  \theta^T = \left[ \theta_0, \theta_1, \theta_2, ... \right] $$
 
$$
X = \begin{bmatrix}
1 \\
x_1 \\
x_2 \\
x_3 \\
\vdots
\end{bmatrix}
$$

Where:
  • $  \hat{y} $ is a "dot" product of two vectors $ \theta^T  X $, 
    • in one-dimensional space, it is an equation of a line
    • in two-dimensional space, it is a plane
    • in multi-dimensional space, it is a hyper-plane
  • $ \theta^T  $ is the n-by-1 vector of unknown parameters in the multi-dimensional space, 
    • traditionally it is shown as transpose $ \theta $, 
    • it is also called: 
      • the vector of parameters
      • vector of coefficients
      • or the weight vector of the regression equation
  • T indicates "transpose" (see reference 4)
  • X is the feature set vector
  • the first element of X is 1, an intercept, or bias parameter

We have to optimize the parameters $ \theta $ in $  \hat{y} = \theta^T  X $ to result in the fewest errors.

  • For example, let's assume:
    • for a given set of parameters we get the result for row 1:
      • $  \hat{y}_1 $ = 140
    • from the observation dataset, we see
      • $  y_1 $ = 196
    • hence:
      • $  y_1 - \hat{y} $ = 196 -140 = 56 
        • which is called residual error for a single observation
        • or distance from the regression line


We can use the Means Square Error formula to calculate the error for all the observations:

$$
MSE =
\frac{1}{n}
\sum_{j=1}^{n}
    \left(
      y_j - \hat{y}_j
    \right)^2
$$

Methods to find optimal coefficients:
  • Ordinary Least Squares
    • Linear algebra operations
    • it takes a long time for large datasets (10k+ rows)
    • Scikit-learn uses the plain Ordinary Least Squares method
  • Optimization Approach
    • Gradient Decent
    • a proper approach for the large data sets




Concerns:
  • multiple linear regression may give you a better predictive model
  • avoid overfitting
  • convert variables to continuous numbers
  • analyze the relationships between dependent and independent variables
    • use scatterplots to check for linearity, if there is no dependency then do not use it


Lab: Multiple Linear Regression















Non-Linear (Polynomial) Regression


Non-linear regression is a method to model the non-linear relationship between the independent variables 𝑥x and the dependent variable 𝑦y. Essentially any relationship that is not linear can be termed as non-linear and is usually represented by the polynomial of 𝑘k degrees (maximum power of 𝑥x). For example:

$$ 𝑦 = 𝑎𝑥^3 + 𝑏𝑥^2 + 𝑐𝑥 + 𝑑 $$



Non-linear functions can have elements like exponentials, logarithms, fractions, etc. For example:
$$ 𝑦 = log(𝑥) $$


$$  \hat{y} = \frac{ \theta_0 }{ 1 + \theta_1^ \left( x -  \theta_2 \right) } $$

We can have a function that's even more complicated such as :

$$ 𝑦 = log(𝑎𝑥^3 + 𝑏𝑥^2 + 𝑐𝑥 + 𝑑) $$


How do we know whether the problem is linear or non-linear?
  • inspect data visually
  • fit non-linear model
  • transform your data






Exponential (hockey stick) functions:


$$  \hat{y} =
\theta_0
+ \theta_1
\theta_2^x
$$









Logarithmic (inverse hockey stick) Regression


$$  \hat{y} =
\log{
  \left(
     \theta_0
  + \theta_1 x
  + \theta_2 x^2 
  + \theta_3 x^3 
 \right)
 }
$$





In the case below, 

$$  \hat{y} =  
\theta_0
+ \theta_1  
\log{x}
$$










Quadratic (parabolic) Regression

$$  \hat{y} =
\theta_0
+ \theta_1 x
+ \theta_2 x^2
$$

in the example below:

$$  \hat{y} =
\theta_0 * 0
+ \theta_1 x * 0
+ \theta_2 x^2
$$






Cubic (s-curve) Polynomial (3rd degree) Regression


$$  \hat{y} =
\theta_0
+ \theta_1 x
+ \theta_2 x^2
+ \theta_3 x^3
$$




Logistic Regression (sigmoid curve)



generic:
$$ Y = a + \frac{b}{1+ c^{(X-d)}} $$

Specific below:
$$ Y = \hat{y} = 0 + \frac{-3}{1 + 3^{(X-2)}} $$














Given the 3rd-degree polynomial equation:

$$
x_1 = x \\
x_2 = x^2 \\
x_3 = x^3
$$

The model is converted to a simple (special case of multiple) linear regression:


$$  \hat{y} =
\theta_0
+ \theta_1 x_1
+ \theta_2 x_2
+ \theta_3 x_3
$$

Least Squares is a method of estimating unknown parameters in a linear regression model by 
minimizing the sum of the squares of the differences between $ y $ and  $\hat{y} $.



References

  1. https://oeis.org/wiki/List_of_LaTeX_mathematical_symbols
  2. https://tex.stackexchange.com/questions/13865/how-to-use-latex-on-blogspot
  3. Special Characters (i.e. Greek) LaTex https://uki.blogspot.com/search/label/Jupyther%20Lab
  4. https://en.wikipedia.org/wiki/Transpose
  5. https://www.atqed.com/latex-column-vector





As an Amazon Associate I earn from qualifying purchases.

University of Illinois CS_400: Object-Oriented Data Structures in C++

I decided to take a refresher on my C++ skills.

The University of Illinois (U-C) had a class on Coursera: "Object-Oriented Data Structures in C++"

https://www.coursera.org/learn/cs-fundamentals-1

The funny thing is, that I actually learned C/C++ at the University of Illinois (UIC), just over 20 years ago!


Getting the instructor's code:
Uki@iMac 18:38 Coursera_OO_data_structures_Cpp $ cd ..
Uki@iMac 18:38 _REPOS $ git clone https://github.com/wadefagen/coursera.git coursera-cs400
Cloning into 'coursera-cs400'...


Setting up macOS for C++

I am following these instructions:

Install Apple XCode


$ xcode-select --install
xcode-select: error: command line tools are already installed, use "Software Update" to install updates


IMPORTANT, if you get Xcode errors when running the make command, execute this command:

sudo xcode-select --reset




by the way, I cannot get XCode IDE because my 2012 iMac is outdated and does not support higher macOS:





Getting BREW


$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"


the above will take quite a few minutes.

Once BREW is installed, install the following:

brew install ghostscript
brew link --overwrite freetype
 
brew install imagemagick

brew link --overwrite libtool

 

brew install graphviz 
brew install cmake


brew edit valgrind



This will open your default code editor. In the opened file, change the URL in the head section from https://sourceware.org/git/valgrind.git 
to 
git://sourceware.org/git/valgrind.git 
and run the following:

brew update brew install --HEAD valgrind


Test MAKE



$ cd /Volumes/GoogleDrive/My\ Drive/_REPOS/coursera_wadefagen/cpp-std
cpp-std $ make




xcrun: error: active developer path ("/Volumes/SSD500GB/Applications/Xcode.app/Contents/Developer") does not exist
...





Uki@iMac 02:03 cpp-std $ sudo xcode-select --reset
Password:

Uki@iMac 02:07 cpp-std $ make
g++ -std=c++14 -O0 -pedantic -Wall -Wfatal-errors -Wextra -MMD -MP -g -c main.cpp -o .objs/main.o
g++ -std=c++14 -O0 -pedantic -Wall -Wfatal-errors -Wextra -MMD -MP -g -c Cube.cpp -o .objs/Cube.o
g++ .objs/main.o .objs/Cube.o -std=c++14 -o main
g++ cout.cpp -std=c++14 -o cout
g++ cout2.cpp -std=c++14 -o cout2
Uki@iMac 02:08 cpp-std $ open .



Uki@iMac  02:10 cpp-std $ ls -alt

total 96

drwx------@ 1 Uki  staff    16K Aug 12 02:10 ../

drwx------@ 1 Uki  staff    16K Aug 12 02:08 ./

-rwx------@ 1 Uki  staff    54K Aug 12 02:08 cout*

-rwx------@ 1 Uki  staff    54K Aug 12 02:08 cout2*

-rwx------@ 1 Uki  staff    61K Aug 12 02:08 main*

drwx------@ 1 Uki  staff    16K Aug 12 02:08 .objs/

-rwx------@ 1 Uki  staff    26B Aug 10 18:37 .gitignore*

-rwx------@ 1 Uki  staff   368B Aug 10 18:37 Cube.cpp*

-rwx------@ 1 Uki  staff   312B Aug 10 18:37 Cube.h*

-rwx------@ 1 Uki  staff   228B Aug 10 18:37 Makefile*

-rwx------@ 1 Uki  staff   209B Aug 10 18:37 cout.cpp*

-rwx------@ 1 Uki  staff   248B Aug 10 18:37 cout2.cpp*

-rwx------@ 1 Uki  staff   395B Aug 10 18:37 main.cpp*

Uki@iMac  02:14 cpp-std $ ./main

Volume: 13.824

Surface Area: 34.56





Week 2




2.1 Stack Memory and Pointers
https://www.coursera.org/learn/cs-fundamentals-1/lecture/Iccq3/2-1-stack-memory-and-pointers


I got to use Microsoft Code and Terminal properly




How to make the compiled files execute in the command line?


If you get a similar error, you might have to change the mode to execute the file..

zsh: permission denied: ./addressOf

cpp-memory % chmod +x addressOf
cpp-memory % ./addressOf
Value: 7
Address: 0x7ff7b9eef878



















As an Amazon Associate I earn from qualifying purchases.

Python GraphLab in Anaconda

In this tutorial I wrote down my own steps on how to configure GraphLab on Mac for the Coursera Machine Learning class from the University of Washington:
Starting from the very beginning...

Check your Anaconda


If you do NOT have conda installed, then download it here (Python 3.6 version),
you can always downgrade to 2.7 later.

Sign up to Anaconda cloud:

https://anaconda.org

$ conda --version

conda 4.5.11

Conda update all packages



Even if you installed the newest Anaconda, there will be a ton of changes..

$ conda update --all

Check if you may already have Python 2.7 environment

$ conda env list
# conda environments:
base * /Volumes/DATA/anaconda3


Python Version

You need to work in anaconda=4.0.0 Python 2.7

Without conda you have:
$ python --versionPython 2.7.10


switching to conda:
$ source activate base(base) uki 19:29 ~ $ python --version
Python 3.6.6 :: Anaconda, Inc.

Create the new environment with Python 2.7 anaconda=4.0.0




 $ conda create -n py2 python=2.7.15


List available environments


$ conda env list# conda environments:
base * /Volumes/DATA/anaconda3
py27 /Volumes/DATA/anaconda3/envs/py2

$ source activate py27(py27) uki  19:34 ~ $ python --versionPython 2.7.15 :: Anaconda, Inc.

The actual installation of GraphLab


$ pip install --upgrade --no-cache-dir https://get.graphlab.com/GraphLab-Create/2.1/YOUR_EMAIL/YOUR_LICENSE_FROM_TURI/GraphLab-Create-License.tar.gz


Installing Jupiter kernel to support GraphLab and Python 2.7




$ python -m pip install ipykernel



$ python -m ipykernel install --user --name py2 --display-name "Python (py2.7.15)"Installed kernelspec py2 in /Users/uki/Library/Jupyter/kernels/py2


$ cd SOME SRC ROOT FOLDER OF YOUR NOTEBOOK(py27) uki  19:41 Week3 $ jupyter notebook


Inside jupyter notebook execute:

import graphlab

if the installation was correct it will work (no output), if not you will see:

ImportError: No module named graphlab




As an Amazon Associate I earn from qualifying purchases.

Python GraphLab in Anaconda

In this tutorial I wrote down my own steps on how to configure GraphLab on Mac for the Coursera Machine Learning class from the University of Washington:
Starting from the very beginning...

Check your Anaconda


If you do NOT have conda installed, then download it here (Python 3.6 version),
you can always downgrade to 2.7 later.

Sign up to Anaconda cloud:

https://anaconda.org

$ conda --version

conda 4.5.11

Conda update all packages



Even if you installed the newest Anaconda, there will be a ton of changes..

$ conda update --all

Check if you may already have Python 2.7 environment

$ conda env list
# conda environments:
base * /Volumes/DATA/anaconda3


Python Version

You need to work in anaconda=4.0.0 Python 2.7

Without conda you have:
$ python --versionPython 2.7.10


switching to conda:
$ source activate base(base) uki 19:29 ~ $ python --version
Python 3.6.6 :: Anaconda, Inc.

Create the new environment with Python 2.7 anaconda=4.0.0




 $ conda create -n py2 python=2.7.15


List available environments


$ conda env list# conda environments:
base * /Volumes/DATA/anaconda3
py27 /Volumes/DATA/anaconda3/envs/py2

$ source activate py27(py27) uki  19:34 ~ $ python --versionPython 2.7.15 :: Anaconda, Inc.

The actual installation of GraphLab


$ pip install --upgrade --no-cache-dir https://get.graphlab.com/GraphLab-Create/2.1/YOUR_EMAIL/YOUR_LICENSE_FROM_TURI/GraphLab-Create-License.tar.gz


Installing Jupiter kernel to support GraphLab and Python 2.7




$ python -m pip install ipykernel



$ python -m ipykernel install --user --name py2 --display-name "Python (py2.7.15)"Installed kernelspec py2 in /Users/uki/Library/Jupyter/kernels/py2


$ cd SOME SRC ROOT FOLDER OF YOUR NOTEBOOK(py27) uki  19:41 Week3 $ jupyter notebook


Inside jupyter notebook execute:

import graphlab

if the installation was correct it will work (no output), if not you will see:

ImportError: No module named graphlab




As an Amazon Associate I earn from qualifying purchases.

apt quotation..