Skip to main content
Module

x/mnist/mod.ts

Famous MNIST dataset ported to Deno land
Latest
import * as mnist from "https://deno.land/x/mnist@v1.1.0/mod.ts";

Functions

Reduces size of 28×28 pixel image to 14×14

Loads MNIST from data archives, unpacks it on the first run and caches it. Data is organized in pairs of images and labels, which in turn are split up into training (60,000) and test sets (10,000). More on which data and how it is ordered on original Yann LeCun's page: http://yann.lecun.com/exdb/mnist/

Turns each image pixel from 0..255 to 0..1

Returns a string that can be printed to console and looks like a digit, e.g.:

Fisher-Yates (aka Knuth) Shuffle. https://stackoverflow.com/a/2450976/1105860