Skip to content

Joseph-Wave/CudaExamples2-C_ML_Kernels

Repository files navigation

CUDA MNIST Neural Network

A basic C/CUDA implementation of a Feedforward Neural Network for handwritten digit classification on the MNIST dataset.

This project was originally intended to run on my old HP Pavilion laptop with an NVIDIA GeForce 840M GPU. Because the service is supose to attent never kicked off, this repository is published as a example for learning purposes.

Methodology

The project implements a classic multilayer perceptron entirely from scratch using native CUDA kernels for parallel acceleration:

  • Forward Propagation: Matrix-vector multiplications computed in parallel across GPU threads to calculate layer activations.
  • Activation Function: Sigmoid activation applied element-wise via custom device functions.
  • Backpropagation: Parallel execution of the chain rule to calculate gradients for weights and biases across all layers.
  • Optimization: Stochastic Gradient Descent (SGD) to update network weights dynamically across training batches.

Prerequisites

  • NVIDIA CUDA Toolkit - v11.3 nvcc compiler

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages