Skip to content

Instantly share code, notes, and snippets.

View pourmand1376's full-sized avatar
😉
Learning

Amir Pourmand pourmand1376

😉
Learning
View GitHub Profile
@pourmand1376
pourmand1376 / Data Science CheatSheet.md
Last active November 8, 2025 23:09
Pandas, Numpy, Python Cheatsheet
@pourmand1376
pourmand1376 / github_desktop_ubuntu.sh
Created July 16, 2021 21:52 — forked from berkorbay/github_desktop_ubuntu.md
To install Github Desktop for Ubuntu
#sudo wget https://github.com/shiftkey/desktop/releases/download/release-2.1.0-linux1/GitHubDesktop-linux-2.1.0-linux1.deb
#sudo gdebi GitHubDesktop-linux-2.1.0-linux1.deb
# UPDATE (2021-03-05): Thanks to PaoloRanzi81's comment, the updated code is as follows https://gist.github.com/PaoloRanzi81
sudo wget https://github.com/shiftkey/desktop/releases/download/release-2.6.3-linux1/GitHubDesktop-linux-2.6.3-linux1.deb
### Uncomment below line if you have not installed gdebi-core before
# sudo apt-get install gdebi-core
sudo gdebi GitHubDesktop-linux-2.6.3-linux1.deb
@pourmand1376
pourmand1376 / fast_fourier_transform_impl.py
Last active May 25, 2021 11:45
Fast Fourier Transform Implementation with numpy
import numpy as np
import matplotlib.pyplot as plt
from skimage import color
def fft(length_x,width_y,v,y,image,inner=True):
expVector=np.exp(-2j*np.pi/width_y*(v@y)) if inner else np.exp(-2j*np.pi/length_x*(v@y))
if inner:
return image @ expVector
else:
return expVector @ image
@pourmand1376
pourmand1376 / SimulatedAnnealing.py
Created January 25, 2020 22:17
Minimizing Math Function with Simulated Annealing Algorithm
import math
import random
def calculateCost(x,y):
return -0.0001*((
math.fabs(
math.sin(x)*math.sin(y)*math.exp(
math.fabs(
100 - math.sqrt(x**2+y**2)/math.pi
@pourmand1376
pourmand1376 / GeneticAlgorithmAI.py
Created January 25, 2020 22:16
Minimizing Math Function with Genetic Algorithm
import math
import random
import numpy
def calculateCost(x,y):
return -0.0001*((
math.fabs(
math.sin(x)*math.sin(y)*math.exp(
math.fabs(
DECLARE @Name nvarchar(1000);
DECLARE @Sql nvarchar(1000);
DECLARE @Result int;
IF OBJECT_ID('tempdb..#myTable') IS NOT NULL
DROP TABLE #myTable
CREATE TABLE #myTable(
row INT,
query NVARCHAR(500))