Coder Social home page Coder Social logo

positeval's Introduction

Comparative tool for comparing IEEE 754 and Posit32 floating point precision with Matrix Multiplication

This project provides a tool for comparing the IEEE 754 and Posit32 floating point precision in regards to Matrix Multiplication. The tool generates a set of matrices and calculates the Euclidian error compared to the double IEEE 754 64-bit format.

image As can be observed, Posit outperforms IEEE 754 (which is the current standard used for floating points in most modern computers) in a specific range of interval for numbers. We therefore hypothesize that Posit may be a viable format for computers specialized in deep learning or machine learning tasks, where many of the calculations are on probabilities, thus centering between 0 and 1.

Compilation

To compile the nessecary binaries and libraries, issue the following command in matrix_multiplication/:

make compile

Running

To run the automated mean error calculations, issue:

make all RANGE=xx SIZE=yy NUM=zz

This will create NUM randomly generated matrices of size SIZE x SIZE, where each matrix entry is a value between -RANGE and RANGE in the matrices/in folder. Each matrix is then multiplied with another, and the resulting matrix is stored in out/32, out/64 and out/posit.

An error is then calculated by comparing the matrices generated in the 32-bit IEEE 754 format and the 32-bit Posit format, to the double precision IEEE 754 64-bit format. The error is calculated as the Euclidian norm. The final result is the average of the Euclidian norms for all the matrices.

positeval's People

Contributors

it4e avatar abrolo avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.