Skip to content

Instantly share code, notes, and snippets.

View MaverickMeerkat's full-sized avatar

David Refaeli MaverickMeerkat

View GitHub Profile
@MaverickMeerkat
MaverickMeerkat / QuantileRegression.ipynb
Created October 31, 2023 16:25
Different ways to preform quantile-regression in Python (using linear programming, IRLS and gradient descent)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@MaverickMeerkat
MaverickMeerkat / CAVI_Bayes_GMM.R
Last active September 4, 2023 13:27
CAVI_Bayesian_GMM.R
# Using the CAVI algorithm on a (Bayesian) GMM example
library(mvtnorm) # for multivariate normal density
library(extraDistr) # for Categorical distribution
library(pracma) # for 2d-integral, sqrtm
library(matlib) # for solving linear equations
library(ggplot2) # for plotting
# Hyper Parameters
sigma = 3 # Variance of mu
# Expectation Maximization - Gaussian Mixture Model
library(ks) # for kde
library(mvtnorm) # for MVNormal
library(extraDistr) # for Categorical & Dirichlet distribution
library(ggplot2) # for plotting
library(pracma) # for sqrtm
######################
# 1D, 2-components #
library(gganimate)
library(plotly)
###########
# General #
###########
# Set the Kenrel function
# Uniform Kernel
f = function(u) as.numeric((u<=0.5) & (u>=-0.5))
# Normal Kernel
@MaverickMeerkat
MaverickMeerkat / sgd-variants-momentum-rmsprop-adam-part-2-code.ipynb
Created April 4, 2023 16:04
SGD Variants: Momentum, RMSprop, Adam - Part 2: Code.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@MaverickMeerkat
MaverickMeerkat / implement-a-nn-part-5-batch-norm.ipynb
Created April 4, 2023 15:42
Implement a NN - Part 5: Batch Norm.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@MaverickMeerkat
MaverickMeerkat / implement-a-nn-part-3-multiclass-using-softmax.ipynb
Created April 4, 2023 13:04
Implement a NN - Part 3: Multiclass using Softmax.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@MaverickMeerkat
MaverickMeerkat / gpreg-vs-multiple-linear-regression-portfolio.ipynb
Created March 10, 2023 11:18
GPReg vs. (Multiple) Linear Regression - portfolio.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.