Udacity course: AI programming with Python

Leave a comment
Education

I continued to look for free materials on Python 3 with AI/machine learning applications.  While it’s definitely possible to find and gobble together a string of free resources, it didn’t really work for me and I felt I was spending a lot of time just doing so.  I decided to enroll in the Udacity nano degree program on AI programming with Python.  After I confirmed that we were going to learn Python 3 specifically and read through the course outline and reviews, I felt that it was worth signing up.

First impressions:

The platform is clean, the videos are engaging, and coding is done right in the same module.

This slideshow requires JavaScript.

The “student hub” seems a mess though.  It’s like a chat with 2100 people and I haven’t been able to find it useful yet.  Quite the difference between the MIT course, where student groups were small enough to make meaningful connections.  I’ll give it another shot later in the course.

udacity student hub

Lastly, the deadlines are all self imposed and there isn’t a weekly assignment.  This could be good or bad… what I actually liked about the MIT course is that there was a real person grading my assignment on a weekly basis, keeping that pace.  That is not the case with the Udacity course.  Course outline below.

Part 1:  Welcome to AI Programming

Part 2: Introduction to Python
Start coding with Python, drawing upon libraries and automation scripts to solve complex problems quickly

Part 3: Jupyter Notebooks, Anaconda, Numpy, Pandas
Learn how to use all the key tools for working with data in Python: Jupyter Notebooks, NumPy, Anaconda, Pandas, and Matplotlib.

Part 4: Linear Algebra Essentials
Learn the foundational linear algebra you need for AI success: vectors, linear transformations, and matrices—as well as the linear algebra behind neural networks.

Part 5: Calculus Essentials
Learn the foundations of calculus to understand how to train a neural network: plotting, derivatives, the chain rule, and more. See how these mathematical skills visually come to life with a neural network example.

Part 6: Neural networks
Acquire a solid foundation in deep learning and neural networks. Learn about techniques for how to improve the training of a neural network, and how to use PyTorch for building deep learning models.

Part 7: Create your own image classifier
In the second and final project for this course, you’ll build a state-of-the-art image classification application.

Stay tuned for updates on this course…

Boosted board unboxing!

Leave a comment
Uncategorized

boostedEver since Back to the Future, I have fantasized of owning a motorized skateboard. Today is the day! I’ve been eyeing the Boosted Board electric skateboard for a few years now. They only came in a long board format, but earlier this year, they released the Mini and I pulled the trigger last week.

Check out the full unboxing video here.

youtube boosted

Not included in the video are screenshots of the Boosted iphone app below.  The board was super easy to connect and the app shows useful info such as battery power left and miles traveled.

Make sure to check out the video for the actual unboxing and review!

* update video 11/4/2018 one week on the board

I’m an MIT graduate! (sort of…)

Leave a comment
Education

I have fulfilled my lifelong dream of becoming an M.I.T. graduate!!! Kidding, it’s only a certificate, but it was a fun experience.  I enrolled in the Artificial Intelligence: Implications for Business Strategy online course at M.I.T.

MIT_School_of_Management.svg

I really enjoyed the course.  It was a 6 week course, outline below:

Module 1: An introduction to artificial intelligence (history, collective intelligence, how to gain strategic advantage

Module 2: Machine learning in business (how ML can be be applied in business context to gain strategic advantage

Module 3: Natural language processing in business (how NLP can be applied to gain strategic advantage)

Module 4: Robotics in business (how robotics and robotic process automation can be applied…)

Module 5:  Artificial intelligence in business and society (human-machine partnerships and ethical and organizational concerns)

Module 6: The future of artificial intelligence (developing a roadmap for implementing AI)

The Platform: B

MIT uses a platform called “getsmarter” for its online course offerings.  The platform itself is clean and easy to use.  Below is a typical lesson plan and tracks progress, encourages interaction with other students through discussion boards, incorporates interactive videos, supplemental materials, and of course, the homework assignment.  The only gripe is that some of the search functionality didn’t work for me when I was trying to search for previous posts in the discussion board.  I probably could have called the support line, but it wasn’t an obvious fix.

mit capture

The lectures: A-

The interactive videos are well produced and the faculty is world class from both the business school and the computer science and artificial intelligence laboratory.  The B-school professors would typically introduce the lessons and then have conversations with the AI experts about real world applications and their research.  This was definitely not a technical course and they only touched on what you needed to know to make a fair assessment of when and how AI could be leveraged in business.  The B-school spin was that each AI initiative had to help further a business strategy by adopting one of Porter’s competitive strategies: i.e. cost leadership, differentiation, and focus.  It was helpful to think in these terms to gain eventual top down support for the initiatives.  The module on robotics was very heavy on autonomous driving, which was fine, but I think they could have expanded a bit more on RPA, which will be a more likely application of robotics for many professionals.

The homework assignments: B +

The homework assignments mostly involved applying the “AI tool of the week” to an organization of your choice.  I, of course, chose an multi-national law firm.  Prior to that, one of the assignments was to analyze current state of the organization.

In module 2, for example , the assignment consisted of:

  1. Describing processes where machine learning could be used
  2. Explaining how the machine learning applications would give the firm a strategic advantage within Porter’s structure
  3. Describing what technical and organizational support was needed to make it happen

This structure was repeated for the modules about NLP and robotics.  While it was a bit mechanical, it was necessary to have materials for the last assignment, which was a full blown roadmap to implement AI within the organization.  All assignments are due within the week and I probably spent about 50% of the time that was suggested and received “exceptional” marks throughout.  Not tooting my own horn, but if you’re a decent writer and have been a professional for a bit, you’ll be fine.  I probably spent about 3-4 hours total/week.

The discussion boards/collaboration: A

I was impressed with how engaged many students were on the discussion boards.  We had folks from pretty much all industries, but the most interesting person I connected with was the COO of National Geographic magazine.  There were also a few legal professionals on there and we have connected on Linkedin and have discussed where AI in legal is going.  Lastly, there is also a closed Linkedin group for alumni of the program, which I joined.

Conclusion: B+

This was a well organized, interesting, and fun course.  The roadmap as the last assignment is an excellent tool to use to drive actual AI projects forward within your organization of choice as it’s a comprehensive collection of all the other homework assignments prior.  The community and collaboration between the other students and teaching facilitators was excellent.   The price of the course is a bit steep at $2600, but given all of the positives and the end deliverable, I’d say it was worth it.  I probably could have gotten all the information through free courses out there, but it would have taken me a bit to organize.  I would recommend this course for anyone who is interested in taking an introductory course to AI business applications and coming out with good fundamental AI knowledge and a real deliverable, i.e. the roadmap.

Watson natural language demo site

Leave a comment
Uncategorized

I came across IBM Watson’s natural language demo site and played around with it a bit. Watson can be tested by entering any text or url link to get his take on sentiment analysis, emotion, keywords, semantic parsing and more.  Here I had Watson analyze the Gettysburg address:

gettysburg

NLP is pretty good at sentiment and emotion analysis and is regularly used to monitor a company’s reputation, for example.  In legal, we have been using NLP for quite some time for example, in the form of Technology Assisted Review for purposes of discovery and more recently, contract analysis.

Coding day 2 – Udacity

Leave a comment
Education

In my search for good online coding courses, I came across this very helpful guide/review and was curious to see Udacity’s platform, so I decided to take a look at this free course.  Right off the bat, the style is completely different than Codecademy.  It was more about identifying a problem and using google searches to identify applicacle coding functions.  It also uses the Python program, rather than an in-platform design. This is good because it’s what you will be doing in the real world, but I did like the three pane approach in Codecademy.  In any case, Udacity is much more focused on instructional videos:

udacity clip 2udacity clip 3

In the first 30 minutes, I created a “break reminder program” that plays a this Han Solo video every 3 hours.  The point was to search for functions and read the documentation.  This does assume you are familiar with the basic loop function, which they only briefly explain.

import webbrowser
import time

total_breaks = 3
break_count = 0

print ("This program started on "+time.ctime())

while (break_count < total_breaks):

    time.sleep (60*3) 

    webbrowser.open ("https://www.youtube.com/watch?v=q6li7dQqQdM&feature=youtu.be")
    break_count = break_count + 1

I like Udacity’s intuitive approach a bit more, focusing on simple problems to solve and then delving right into solving it.  Unfortunately, this course is also Python 2.  I might go through the course to get the basics first and look for Python 3 specifics later.

Coding day 1 – Codecademy

Leave a comment
Education

Codecademy offers a 7 day trial period and I immediately started the Python 10 hour course.  The platform is useful and consists of three panes: instructions and examples, script editor, and the console showing the results of the script.

codecademy

Within an hour or so, I was able to write a short Mad Libs script, which worked in the Codecademy console:

"""
This program generates passages that are generated in a cool mad-lib format
Author: Johan
"""

# The template for the story is below

STORY = "This morning %s woke up feeling %s. 'It is going to be a %s day!' Outside, a bunch of %s were protesting to keep %s in stores. They began to %s to the rhythm of the %s, which made all the %ss very %s. Concerned, %s texted %s, who flew %s to %s and dropped %s in a puddle of frozen %s. %s woke up in the year %s, in a world where %ss ruled the world."

print "Mad Libs has started!"

name = raw_input("Enter a Name: ")
adj1 = raw_input("Enter an adjective: ")
adj2 = raw_input("Enter a second adjective: ")
adj3 = raw_input("Enter a third adjective: ")

verb = raw_input("Enter a verb: ")

noun1 = raw_input("Enter a noun: ")
noun2 = raw_input("Enter another noun: ")

animal = raw_input("Enter an animal: ")
food = raw_input("Enter a food: ")
fruit = raw_input ("Enter a fruit: ")
superhero = raw_input ("Enter a superhero: ")
country = raw_input ("Enter a country: ")
dessert = raw_input ("Enter a dessert: ")
year = raw_input ("Enter a year: ")

print STORY % (name, adj1, adj2, animal, food, verb, noun1, fruit, adj3, name, superhero, name, country, name, dessert, name, year, noun2)

I wanted to save the code in a console so that people could run it.  I created this Kaggle kernel (open only on desktop).  Kaggle is a site where you can store and run your code and share with others.  However, when I ran it I got an error.  Turns out Kaggle runs Python 3 and the Codecademy course is teaching me Python 2…

Note to self (and you all): decide if you need Python 2 or 3.  Considering I’m expecting to do a lot in Kaggle, I think I need Python 3.  Back to finding an appropriate Python course.

 

Machine learning

Leave a comment
Uncategorized

As I’m working through my materials for the MIT AI course, I wanted to share some of the public information I’m using in my studies.

machine-learning1

image via Adbul Rahid

Three short videos of Facebook’s Head of AI Research on deciphering images, deep learning, and convolutional neural networks.  These are worthwhile for a quick overview.

Also, some of Google’s free online machine learning resources.

Lastly, a case study I found interesting about the online clothing company Stitch Fix’s use of machine learning and human interaction.