Skip to content

Instantly share code, notes, and snippets.

Avatar
🕌
Oh Lord! Bestow me with Knowledge

Md Mahedi Hasan Mahedi-61

🕌
Oh Lord! Bestow me with Knowledge
View GitHub Profile
@Mahedi-61
Mahedi-61 / SqueezeNetCIFAR.py
Created Feb 1, 2022
SqueezeNet on CIFAR-10 Dataset
View SqueezeNetCIFAR.py
import torch
import torch.optim as optim
import numpy as np
from matplotlib import pyplot as plt
from tabnanny import check
from sklearn.metrics import confusion_matrix
import seaborn as sns
from torch import nn
import torch.nn.init as init
from torchvision import transforms, datasets
@Mahedi-61
Mahedi-61 / RBF_Pseudo_Inverse.py
Last active Jun 26, 2022
Radial Basis Function initialized on K-means and trained on Pseudo Inverse for MNIST digit classification
View RBF_Pseudo_Inverse.py
"""
modified from several gist of https://gist.github.com/tarlanahad
For Homework Assingment 12 (CpE 520)
"""
import numpy as np
import torchvision
from matplotlib import pyplot as plt
from sklearn.metrics import confusion_matrix
import seaborn as sns
@Mahedi-61
Mahedi-61 / RBF_classifier.py
Last active Dec 5, 2021
Radial Basis Function Netowork for MNIST classification tranined on gradient decent approach
View RBF_classifier.py
"""
Author: Md Mahedi Hasan
For Homework Assingment 12 (CpE 520)
"""
import numpy as np
import os
import matplotlib.pyplot as plt
from torch.utils.data import DataLoader
from torchvision import transforms
@Mahedi-61
Mahedi-61 / KSOM.py
Created Nov 29, 2021
Implementing Kohonen Self Organizing Maps using numpy
View KSOM.py
"""
Script to implement simple self organizing map
@author: Riley Smith
Created: 1-27-21
"""
"""
@modified: Md Mahedi Hasan (11/28/2021)
For Homework Assingment 11 (CpE 520
"""
@Mahedi-61
Mahedi-61 / autoencoder_mnist.py
Last active Nov 18, 2021
3-layer autoencoder for MNIST digit reconstruction and classification with visualization (Pytorch)
View autoencoder_mnist.py
"""
Course: Applications of NN (CpE - 520)
Homework Assignment 9
"""
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
import torch
@Mahedi-61
Mahedi-61 / parity-3-problem
Last active Nov 18, 2021
Solving Parity-3 problem using 3-layer from scratch
View parity-3-problem
# solving parity-3 problems using numpy only
from os import error
import numpy as np
import math
np.random.seed(1)
def relu(x):
return np.maximum(0, x)
@Mahedi-61
Mahedi-61 / pdftk_commands.sh
Last active Nov 2, 2020
useful commands of shell script pdftk
View pdftk_commands.sh
# Replacing few page from a pdf file using another pdf file
pdftk A=first.pdf B=second.pdf cat A1 B1 A3-end output out.pdf
# Above code means second page of first.pdf is replaced by the first page of second PDF
# merging multiple files into one file
pdftk file1.pdf file2.pdf cat output mergedfile.pdf
@Mahedi-61
Mahedi-61 / bslr.ipynb
Last active Mar 24, 2020
Notebook for running openpose for my Bangla Sign Language Project in Google Colaboratory
View bslr.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Mahedi-61
Mahedi-61 / latex_math.tex
Last active Dec 27, 2019
gait journal latex math
View latex_math.tex
#for equation 3
\begin{align*}
\alpha &=
\begin{cases}
\tan^{-1}{\frac{|J_{2x}-J_{1x}|}{|J_{2y}-J_{1y}|}} & J_{2y} \neq J_{1y}\\
\pi/2 & J_{2y} = J_{1y}
\end{cases} \\ \noalign{\vskip10pt}
\beta &=
\begin{cases}
@Mahedi-61
Mahedi-61 / AlgorithmForBDGovt.py
Last active Aug 19, 2021
how BD government find Abrar Murderer
View AlgorithmForBDGovt.py
"""
Author: A cup of Tea
Description: Algorithm about how BD government is going to find Abrar Murderer
"""
def findGuiltyToAbrarMurder():
if(guilty == activistOfBCL):
victim = activistOfShibir
silenceLikeHell()
useBruteForceToRemoveMovement(BCLGang, BDPolice)