Code Monkey home page Code Monkey logo

ml-es6-modules's Introduction

Hi there ๐Ÿ‘‹

I am Davide Ghiotto, and:

  • ๐Ÿ‘จ๐Ÿปโ€๐Ÿ’ป I am working at Bitrock
  • ๐Ÿ“ซ How to reach me: [email protected]
  • โšก Fun fact: I love going to the gym ๐Ÿ’ช

Skills

  • Frontend: Javascript Typescript Vue.js Angular React
  • Backend: Java Python C# C++
  • AI: Machine learning Neural Nets
  • Cloud: Firebase GCP AWS (basics)
  • CI/CD: Github Actions Jenkins Sonarqube Netlify Digital Ocean

Personal Website

davideghiotto.it - personal portfolio website

ml-es6-modules's People

Contributors

davide97g avatar

Stargazers

 avatar  avatar

Forkers

tanliyuan

ml-es6-modules's Issues

K-Means

Integrate K-Means clustering as an extra algorithm.

Algorithm

K-Means takes the original data and calculates the positions of K points of each classe the data gas breb dividere into.

Integration

Input data just need to be transformed from the dataset to these new clustering points.
Could be inserted as a drawer option. If the user wants to use K-Means clustering he will select the option and specify also how many clusters are to be found.

Documentation modules

Documentation

Modules are working and ready to use.
It would be sad if the only one able to use them was me.
Documentation is key: just describe the usage process and briefly how the methods work.

A good doc

The final user should know, in descending order of importance :

  • README module:
    • module information
    • usage tutorial
    • developer instruction
  • Inside file with jsdoc:
    • classes/functions description
    • methods description

To sum up things:

  • a clean and simple README of all the modules

would be perfect: give an introduction without becoming module-specific.

CSS Styling

Styling ๐Ÿ”ฅ

Why

"It's not good if it just work. It's good if it works and looks good."
a FrontEnd WebDeveloper

We know that.
The UI has to be nice and clean for a 360ยฐ experience.
Just kidding, standard colors and shape sucks.

How

Create separeted .css files with hierarchy order.

./css
  - root.css
  - container.css
  - input.css
  - text.css
  ...

What

Here's a list of elements that need to be styled:

  • canvas
    • colors of canvas
  • body
    • font size & font family
  • options container (both draw and algorithm options)
    • slider
    • checkbox
    • radio

Input boosting module

Input Boosting

Why

In the context of Support Vector Machines it's interesting to see how adding some features to the dataset can drastically improve the results of the optimization. Sometimes it's a kernel alternative.

How

Boosting is a simple operation:

  • extract one data point with all his features t0 | t0=[x0,x1,...,xn]
  • choose a function f | f=(x0,x1,...,xn) dependent on one feature or more whose output will be a set of features t=[y0,...,yt] with 1<=|t|<=|t0|
  • replace the data point with the previous features, t0, and the ones you just boosted, t, with function f
    Example
// initial dataset
let dataset = [ [1,2], [2,3], [-2,-4], [-1,0] ];
// boosting function
let f = (v) => v.push( Math.pow(v[0],2) );
// boosting the dataset
dataset.foreach( data => f(data));
// output
// dataset =[ [1,2,1], [2,3,4], [-2,-4,4], [-1,0,1] ];

Where

The boosting operation must no reside inside one machine learning module. They have to be included in one ES6 module on their own, in order to achieve separation, modulation and cleaner code.

Example:

export const booster = function(){};
booster.prototype = {
  boost: function(data,f){
    ...
  },
  getBoostingFunctions: function(){
    ...
  },
  // list of boosting functions
};

When

There are 2 distinct moments when boosting functions need to be known:

  1. Training phase: manager module would feed the training phase with the boosted data whenever we tell him
  2. Prediction phase: it's a bit tricky this time. Prediction is not manager's role. It's handled by the drawer prototype function.
    As we can see, most of the work of managing data is done by the manager class, except from prediction.

A quick fix would be to move the responsibility of the prediction from drawer to manager. The only thing drawer class has to do to receive the predicted value is to sent a "request" to the manager. The latter will calculate the prediction, boosting the data if needed (he knows the boosting functions), and will return the value.

Who

The class that controls the datasets should also control when to boost them.
Manager prototype allow us to easly set new data into algorithm classes.
In this context should be reasonable to specify another option: the boosting.
If boosting is selected then manager applies the boosting functions selected to the data. The algorithm will be fed with the boosted data and they will be agnostic on the boosting operation.
But not only the training phase should be checked: prediction phase needs to know which boosting functions to apply, if there's anyone.

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.