Author archives

keras-Tensorboard

Many times we need to visualize our model on Tensorboard, for this we have to save our model and at runtime check out the performance. Here is the code for a simple linear regression using Keras and tensorboard. import Libraries: import keras import numpy as np from pandas import read_csv from keras.models import Sequential from …

Imbalanced-Data Set for Classification

Machine Learning algorithms unsatisfied problem with classifiers when faced with imbalanced datasets. Let’s take an example of the Red-wine problem. The Data we have is as: Here we have a data set in which we have different six categories, but not balanced categories. So, in the case available the samples are not equally balanced so …

Heteroscedasticity (Heteroskedasticity)

Heteroscedasticity refers to the condition in which the variability of a variable is unequal across the range of values of a second variable that predicts it. A scatterplot of these variables will often create a cone-like shape, as the scatter (or variability) of the dependent variable (DV) widens or narrows as the value of the independent …

Decision Tree

Decision Trees (DTs) are a non-parametric supervised learning method used for classification and regression. It works for both categorical and continuous input and output variables. It is a non-parametric algorithm. It uses the following algorithms. 1- ID3: ID3 uses Entropy and Information gain to construct a decision tree. 2- Gini Index (, if we select two items from a population …

KNN

KNN is another supervised classification technique, which makes no assumption of distribution of data. It is a non-parametric algorithm.It is the simplest technique of classification, the algorithm used for this technique is as: Algorithm Let m be the number of training data samples. Let p be an unknown point. Store the training samples in an …

LSTM-Long Short Term Memory

LSTM it a type of Recurrent neural network, Various variants of RNNs have been around since the 1980s but were not widely used until recently because of insufficient computation power and difficulties in training. Since the invention of architectures like LSTM in 2006 we have seen very powerful applications of RNNs. In 1997 by Hochreiter & …