mlp

A Multilayer Perceptron Neural Network implementation written in ANSI-C.

https://github.com/nikosdelijohn/mlp

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (8.3%) to scientific vocabulary

Keywords

c classifier machine-learning perceptron-learning-algorithm
Last synced: 6 months ago · JSON representation ·

Repository

A Multilayer Perceptron Neural Network implementation written in ANSI-C.

Basic Info
Statistics
  • Stars: 3
  • Watchers: 1
  • Forks: 1
  • Open Issues: 0
  • Releases: 0
Topics
c classifier machine-learning perceptron-learning-algorithm
Created almost 7 years ago · Last pushed over 1 year ago
Metadata Files
Readme License Citation

README.md

Multilayer Perceptron Implementation

This was a project for the course MYE035-CSE.UOI - Computational Intelligence during the 2018-19 winter semester.

Created by: 1. Nick Deligiannis 2. Paschalis Homondozlis

The problem

The mlp was used to solve a three class classification problem which is the following:

Given 6000 examples [points (x1,x2) at 2D space] in which:

  • 3000 points are contained in the rectangle [0,2] x 0,2

  • 3000 points are contained in the rectangle [-2,0] x -2,0

Hence, there are two data sets. The training set and the testing/validation set. Finally we define the three classes/categories as following:

  1. >

  1. >

  1. >

### Visualisation

Specifications

This Neural Network has two hidden layers with customizable number of neurons in each one. The learning method implemented is gradient descent and the activation functions used are the logistic and the hyberbolic tangent.

Known Issues

There is a problem using the hyperbolic tangent as activation function. If you select the tanh function then it is being asserted to all the neurons of the network, including the output layer neurons, something that will not provide the proper results since tanh ranges from -1 to +1 and the encoding used was based on the logistic function which ranges from 0 to 1.

Usage

  1. Generate the dataset using the "datasetgeneration.c" file (compile /w gcc datasetgeneration.c).
  2. Change the path @ lines 752-754 (on mlp.c) or comment out those lines if you don't wish to use gnuplot for visualisation
  3. Compile the "mlp.c" file (compile /w gcc mlp.c -lm)
  4. Run the executable file.

Example

Results of a run.

Visualisation in gnuplot

Points classified correctly

Points classified wrong

Square error behavior

Owner

  • Name: Nick
  • Login: NikosDelijohn
  • Kind: user
  • Location: Turin, Italy
  • Company: Politecnico di Torino

> /dev/null to everything

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
- family-names: "Deligiannis"
  given-names: "Nikolaos"
- family-names: "Pashalis"
  given-names: "Homondozlis"
title: "A Multilayer Perceptron Implementation in ANSI-C"
version: 1.0
date-released: 2019-3-19
url: "https://github.com/NikosDelijohn/MLP"

GitHub Events

Total
Last Year