CIFAR-10 MLP (3072-128-10)

A multi-layer perceptron for CIFAR-10 on raw pixels.

  • Architecture: 3072-128-10 (394,634 parameters); hidden activation relu, Identity output layer (logits).
  • Trained on the 50,000 CIFAR-10 training images with their true labels for 100 epochs: plain SGD, learning rate 0.01, batch size 64, cross-entropy loss, seed 1076.
  • CIFAR-10 test accuracy (10,000 images): 0.4833; final training accuracy 0.9061.

Files

  • weights.npz: W0, b0, W1, b1 (float64); layer i computes h @ W_i + b_i with W_i of shape (n_in, n_out).
  • preprocessing.npz: mean and std (3072 values each) of the training pixels after dividing by 255.
  • config.json: architecture, preprocessing, training settings and results.

Use

import numpy as np

w, prep = np.load("weights.npz"), np.load("preprocessing.npz")
x = (images.reshape(len(images), 3072) / 255.0 - prep["mean"]) / prep["std"]  # images: uint8 (n, 32, 32, 3)
h = np.maximum(x @ w["W0"] + w["b0"], 0.0)
logits = h @ w["W1"] + w["b1"]  # classes: airplane, automobile, bird, cat, deer, dog, frog, horse, ship, truck
Downloads last month
32
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Dataset used to train Chervith-Reddy/smai-a4-mlp