Products
Features
YouTube Video Summarizer
Summarize YouTube videos
Web & PDF Highlighter
Highlight web pages & PDFs
Chat with PDF
Ask any PDF questions with AI
Ask AI Clone
Chat with your highlights & memories
Audio Transcriber
Transcribe audio files to text
Glasp Reader
Read and highlight articles
Kindle Highlight Export
Export your Kindle highlights
Idea Hatch
Hatch ideas from your highlights
Integrations
Obsidian Plugin
Notion Integration
Pocket Integration
Instapaper Integration
Medium Integration
Readwise Integration
Snipd Integration
Hypothesis Integration
Apps & Extensions
Chrome Extension
Safari Extension
Edge Add-ons
Firefox Add-ons
iOS App
Android App
Discover
Discover
Ideas
Discover new ideas and insights
Articles
Curated articles and insights
Books
Book recommendations by great minds
Posts
Essays and notes from readers
Quotes
Inspiring quotes collection
Videos
Curated videos and summaries
Explore Glasp
Glasp Newsletter
Weekly insights and updates
Glasp Talk
Interview series with great minds
Glasp Blog
Latest news and articles
Glasp Use Cases
Learn how others use Glasp
Build & Support
Glasp API
Access Glasp's API for developers
MCP Connector
Connect Glasp to Claude & ChatGPT
Community
Glasp Reddit Community
Students
Student discount and benefits
FAQs
Frequently Asked Questions
AboutPricing
DashboardLog inSign up

Coding Challenge #158: Shape Classifier Neural Network with ml5.js

137.4K views
•
December 3, 2020
by
The Coding Train
YouTube video player
Coding Challenge #158: Shape Classifier Neural Network with ml5.js

TL;DR

In this video, the presenter demonstrates how to train a convolutional neural network using p5.js to recognize shapes such as circles, squares, and triangles.

Transcript

[BLOWS TRAIN WHISTLE] Hello, and welcome to a 2020 substitute train whistle Coding Train Coding. I am so excited for you to watch this one. I just finished making it. So I'm just recording a little intro here to show you the end result, because this one might be kind of long. So you can see, ultimately, where I get to. I have a p5.js sketch that is... Read More

Key Insights

  • 😒 The presenter uses Processing to generate a dataset by programmatically creating shapes and saving them as images.
  • 🚂 The ml5 library in p5.js is utilized to train a convolutional neural network model using the dataset.

Install to Summarize YouTube Videos and Get Transcripts

Explore YouTube Video Summarizer or Get YouTube Transcript Extractor

Questions & Answers

Q: What tools are used to generate the dataset?

The presenter uses Processing, a Java-based programming environment, to programmatically generate shapes and save them as images.

Q: What shapes does the neural network recognize?

The neural network is trained to recognize circles, squares, and triangles.

Q: How is the dataset loaded into the p5.js sketch?

The dataset images are loaded using the preload() function in p5.js, and the ml5 library's loadModel() function is used to load the pre-trained neural network model.

Q: Can the model be used to classify shapes drawn on a canvas?

Yes, the presenter demonstrates how shapes drawn on a canvas can be classified by the trained model using the ml5 library's classify() function.

Summary & Key Takeaways

  • The presenter collects a dataset by generating shapes programmatically using Processing and saves them as images.

  • The dataset is then used to train a convolutional neural network model using the ml5 library in p5.js.

  • After training, the model is able to classify shapes drawn on a canvas, and the presenter shows examples of it recognizing circles, squares, and triangles.


Read in Other Languages (beta)

English

Share This Summary 📚

Summarize YouTube Videos and Get Video Transcripts with 1-Click

Download browser extensions on:

Try YouTube Summary with ChatGPT & Claude or YouTube Transcript Generator

Explore More Summaries from The Coding Train 📚

ITP/IMA Winter Show 2018 thumbnail
ITP/IMA Winter Show 2018
The Coding Train
Computer Mouse Conference Demos! (node.js + tensorflow.js) thumbnail
Computer Mouse Conference Demos! (node.js + tensorflow.js)
The Coding Train
Classifying Poses with ml5.js Part 2 thumbnail
Classifying Poses with ml5.js Part 2
The Coding Train
Coding Challenge #126: Toothpicks thumbnail
Coding Challenge #126: Toothpicks
The Coding Train
ITP/IMA Winter Show 2019 thumbnail
ITP/IMA Winter Show 2019
The Coding Train
9.4: Genetic Algorithm: Looking at Code - The Nature of Code thumbnail
9.4: Genetic Algorithm: Looking at Code - The Nature of Code
The Coding Train

Summarize YouTube Videos and Get Video Transcripts with 1-Click

Download browser extensions on:

Try YouTube Summary with ChatGPT & Claude or YouTube Transcript Generator

Apps & Extensions

  • Chrome Extension
  • Safari Extension
  • Edge Add-ons
  • Firefox Add-ons
  • iOS App
  • Android App

Key Features

  • YouTube Video Summarizer
  • Web & PDF Summarizer
  • Web & PDF Highlighter
  • Chat with PDF
  • Ask AI Clone
  • Audio Transcriber
  • Glasp Reader
  • Kindle Highlight Export
  • Idea Hatch

Integrations

  • Obsidian Plugin
  • Notion Integration
  • Pocket Integration
  • Instapaper Integration
  • Medium Integration
  • Readwise Integration
  • Snipd Integration
  • Hypothesis Integration

More Features

  • APIs
  • MCP Connector
  • Blog & Post
  • Embed Links
  • Image Highlight
  • Personality Test
  • Quote Shots

Company

  • About us
  • Blog
  • Community
  • FAQs
  • Job Board
  • Newsletter
  • Pricing
Terms

•

Privacy

•

Guidelines

© 2026 Glasp Inc. All rights reserved.