My master class in Machine Learning & Deep Learning with Python

0

Image result for Machine learning"

Hi,

One of my biggest goals in 2020 is to dive deep in Python and machine learning; two things I haven’t really explored in the time I’ve been in tech. That’s about to change.

Even though I have experience with other frameworks and programming languages, I do not consider my self as an “experienced Python developer”. I do know how to

  • Solve problems
  • Break down complex topics into simpler components
  • Put in place an architecture that emulates pretty well the outside world
  • Implement a “quick and dirty” approach and keep on improving it

For this, I’m going to start learning as if I’m a true beginner and not take anything from granted. I’ve already established a list of resources to go through in 2020. I’m sure there could be better resources out there, but I feel uncomfortable enough with the quantity of information I’ve selected to digest to know that it’ll probably be enough for the year. As I grow into Python, I will add extra resources to my “master class” that I feel are complementary to the education if anyone wants to follow along.

Why am I fascinated by machine learning?

Machine learning has taken the world like a wildfire. In the past few years, we’ve moved from things that were in the world of sci-fi such as self-driving cars, Alexa or trading stocks. It’s a domain that moves really fast and I feel I’m already super late to the party. Most of all, I see it’s potential to do good in the world when combined with other technologies and an application with the sole intent of making the world a better place.

I’m someone who likes to understand a technical topic deeply and instead of having someone tell me what’s going on in the realms of artificial intelligence, I’d rather take a look for myself and make my own opinion of it. So, that’s why I decided to get a jump on it.

My Goals

  1. Be knowledgeable enough to use AI as a tool to bring value in different communities. I like to build cool stuff and I hope that some of that stuff can evolve into something that is useful to others. That’s why technology fascinates me; it is its power to have a gigantic and meaningful impact in the life of people and I want to find ways to help.
  2. I love learning and I want to inspire others to start their own path in ML. In the world of software development, we can’t evolve if we don’t enjoy acquiring new skills. Technology moves at an incredible pace and we have to be careful in order to react to its changes.

Syllabus

The following syllabus may not be the one out there, but I feel that it’s a really good first step towards enlightenment.  If you have any advice for me, including courses I should look at or skills I should work on, please feel free to let me know in the comments or reach me on Twitter.

Legend

  • Strikethrough = course / book  completed
  • Royal blue = course / book partially in progress
  • Non-edited links = Not started

Fundamental Skills

Professional Skills

Improving Software Engineering Skills

Data Structures & Algorithms

Problem Solving

  • Solving problems on Codewars [Free]
    • Moving from 8 kyu (Beginner – white belt level) to 2 kyu (Proficient – purple belt level)
    • Codewars Kata Ranking System
      • White belt: At this level, the kata is only challenging for users new to programming
        • Basic variable assignments
        • Basic functional or object-oriented concepts
      • Yellow belt: At this level, the kata will start to include more advanced algorithmic challenges and more complex language features
        • Complex OOP/Functional concepts
        • Advanced regular expression usage
      • Blue belt: At this level, the kata begins to take some serious thought to complete.
        • Advanced concepts such as concurrency, parallelism, meta programming and cryptography
        • Basic AI/machine learning algorithms
      • Purple belt: At this level, kata requires a mature understanding of complex programming concepts
        • Complex AI/machine learning algorithms
        • Reverse engineering techniques

Books & Resources

As you can see, most of the syllabus is about consuming free resources. In this day and age, we can learn about anything we want if we just put some time aside and find great resources that can bring us to the next level. I’m not going to lie, for those who want to follow along with a similar “master class”, this is going to heavy. In college, I would have skipped a lot of material that I didn’t feel would help land that A. That’s not a great approach towards learning.

Now that I want to learn only for myself and not for a grade, my point of view has drastically change and for the better. Now that my syllabus has been put in place, all that I need is to start my journey starting tomorrow morning @ 5 am.

Thanks for reading if you kept reading thus far 🙂

Kevin

 

 

Experiments and Adventures in 2019 with F#

0

Hi readers,

This year has been a big one in the field of software engineering for me. My close friends know that F# has always been a technology that I loved and I promised myself I would start doing more F# development than I have ever done before.

FSSF

I’ve joined the F# FSSF community and their slack. Talking to other peers who love F# as I do and it’s been a great experience thus far. The people are very welcoming and very forthcoming whenever someone has a software issue. For those who’d like to join the FSSF, here’s a link. It’ll be one of your best decisions! The community is great and very supportive 🙂

Automate grunt work & F# mentoring

At work, I had been talking a little bit about F# and it got my team excited and they asked me to present the language and why it was interesting to know more about functional programming. So for this, I created a presentation to cover

  • What is functional programming
  • What’s F# and basic features of the language
  • Differences between implementing Tic-Tac-Toe in C# and F#

Afterward, I presented a code sample I put together. I wanted to showcase a full implementation with F#. To that end, I created a sample static e-commerce app (only console) to showcase how easy it is to put in place a domain and how quickly it is to implement features from top to bottom.

Some team members have been interested in knowing more of F# and that brought in new projects at work. A coworker was telling me about creating custom UIs for clients based on requirements that could be found in an XML file. The issue he had was that with our current architecture(closely related to MVVM), it would take him about 8hrs-to-16hrs to implement only one custom UI. There was a lot of redundant work and he thought there could be some way to automate it with F#. He liked what he saw in my presentation and loved seeing how type providers worked.

After putting together a design to match his needs, I was leading in while he was implementing a solution for his problem. When we finished the implementation, we saw that it took about 80hrs for full implementation. The gain was incredible when you knew that it would have taken him 280 to 560hrs manually.

That was my first experience mentoring someone through an entire project and I can definitely see myself doing it some more. I’ve had the chance to mentor interns here and there but here we were talking of an established developer who wanted to learn functional programming and solve a problem quickly so we couldn’t spend too much time on it without proper justification.

Mentorship Program

The program is there to help out F# programmers in any given project they’d like to work on such as learning the language or start contributing to the F# compiler. On my end, I wanted to dive into full-stack development with F#. My mentor was great!

We met for 1 to 2 hrs a week for about 2 months and we were putting together a more advanced implementation of my previous e-commerce application.

The implementation covers domain-driven design, type-driven design and back-end + front-end with only F#. For those that know the React library, the great thing about F# is that you can still leverage all your know-how with only F#. The community has been pretty great at providing toolings that let developers craft great web apps with only F#.

For those who’d like to see this implementation, here’s a link to my repo. On top of this repository, you can also visit the presentation I made with the web app (ReliableElmishApps.pptx).

Performance Monitoring

At work, we had been hit by a performance regression and had no idea how this happened. Being in the DevOps team, I thought to myself, even if we fix it now, there’s no way, without proper tools, that it won’t happen again.

I started to research some performance tools for .NET and that’s when I’ve discovered BenchmarkDotNet and thought

“oh cool! That’s exactly what we need!”

Started to read on how to use and include it in our solution. Little did I know that it wouldn’t be exactly what we needed. We soon discovered with our architecture, we couldn’t use it for automated UI testing but only for low-level component and backend services profiling.

Although it didn’t cover everything in one go, it was still pretty incredible! My team had been searching for a stable solution for performance tests and the Timer ⏱ in .NET wasn’t providing stable results in different environments.

We were missing something and I explored some more to find a way to do performance profiling our implementation in an automated UI test. So I decided to go inside the source implementation of BenchmarkDotNet and see how they do it! Congrats for this by the way, really a great tool 👍🏾

I found how they could monitor the time it took for a method to complete and saw the light! I was glad to see their license was MIT so I could start thinking of my way to solve my work problem!

I implemented a performance watcher for both synchronous and asynchronous actions in .NET. That would allow us to keep using this solution were we to migrate to something else than WPF and still need performance monitoring.

Now that we had data, we needed  a way to understand said data when we’d launch many performance builds in our CI pipeline. So I went on and created another F# tool for this.

The tool parsed the performance logs I create from an automated UI test and create a performance report by leveraging the data. To get a quick understanding of, for instance, an improvement in performance from before and current state, a developer only has to give the resulting performance report in CSV to Excel and the data will be displayed in a table 🙂

First book (In Progress)

So, over the past few years, I’ve read a lot of tech books and an even greater number of blog posts from the tech community. Something in me shifted and I finally took the decision, after years of debating with myself.

“I’m going to write an F# book” I thought.

I really like F# as a programming language and the community around it! I’ll be doing a self-publish for the book so I’ll be sure to share it in the proper channels to make sure anyone that wants to read it can!

Data Structures & Algorithms

One of my areas of focus of 2020 is to revisit one core fundamental tooling of the software developer; data structures and algorithms. To be able to improve my way to approach problems at work and for side-projects, I want to make sure my knowledge is rock solid.

In the next few months, I’ll be taking a class at Coursera. As for now, I’ll be solving algorithms problems on websites such as HackerRank or Codewars until then.

I created a repository for this that I welcome readers to visit and contribute to if you feel it’s helpful. It may be a bit redundant with the variety of information out there concerning data structures and algorithms. That, we can agree on. The idea behind this effort is to lower the entry barrier to F# and let others see that it’s fairly quick to get into the game and F#’s expressiveness is a godsend for solving problems quickly and cleanly. You’ll be able to get more information right here.

Machine Learning & MLOps

This also is an effort to lower the entry barrier to F#. Some aspects of F# such as its rigid type system, its data access capabilities, and functional nature makes it a strong candidate to use for machine learning purposes.

Right now, the world has been taken by a storm with the likes of Python & R. .NET is trying to close the gap that we have and we’re getting close to what others can experiment in other development environments.

The idea here is to be able to use technologies such as Jupyter Notebooks or CI/CD pipelines and create machine learning experiments without having to be forced to learn another language. It’s not about making F# a swiss army knife, but if the tool is already great for this sort of thing, it’s pretty great to leverage it into the unknown without having to learn a new language on top of everything else.

So the idea is for me to get to know more about machine learning and how to put together DevOps pipeline for machine learning or MLOps (Machine Learning Operations). For this, I’ve bought a few books on machine learning

  • Prediction Machines by Agrawal, Ajay
  • The hundred-page machine learning book by Burkov, Andriy
  • Hands-on machine learning with Scikit-Learn, Keras & Tensorflow by Géron, Aurélien

As I’m going through them, I’ll provide my main takeaways from the books in the repository as well as my notes on machine learning courses I’ll be going through. To the best of my abilities, I’ll translate my notes to F# code since the courses will use Python as their main programming languages. You’ll be able to find more information on my progression here in my repo.