This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt-get update -y && apt-get upgrade -y | |
apt-get install -y nginx | |
echo "Hello World from " $HOSTNAME | sudo tee -a /var/www/html/index.html |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
^+c:: | |
Clipboard := random_Chars(10) | |
return | |
^+v:: Send, %Clipboard% | |
;------------------------------------------------------------------------------- | |
random_Chars(Count) { ; returns count random characters | |
;------------------------------------------------------------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
^+c:: | |
Clipboard := random_Chars(10) | |
return | |
^+v:: Send, %Clipboard% | |
;------------------------------------------------------------------------------- | |
random_Chars(Count) { ; returns count random characters | |
;------------------------------------------------------------------------------- | |
static Char_List := "ABCDEFGHIJKLMNOPQRSTUVW" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from moviepy.editor import * | |
clip = VideoFileClip("C:/Users/thoma/OneDrive/Workspace/Projects/Yawman/media/prototype_2_demo.mp4") \ | |
.subclip(8*60+7,8*60+30)\ | |
.without_audio() | |
final_clip = concatenate_videoclips([clip]) | |
clip.write_videofile("C:/Users/thoma/OneDrive/Workspace/Projects/Yawman/media/turn.mp4") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sympy import * | |
m, b, i, n = symbols('m b i n') | |
x, y = symbols('x y', cls=Function) | |
sum_of_squares = Sum((m*x(i) + b - y(i)) ** 2, (i, 0, n)) | |
d_m = diff(sum_of_squares, m) | |
d_b = diff(sum_of_squares, b) | |
print(d_m) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sympy import * | |
# Declare weight, bias, layer outputs, and input variables | |
# W1 and W2 are hidden and output layer weights | |
# B1 and B2 are hidden and output layer biases | |
# A1 and A2 are activated layer outputs | |
# Z1 and Z2 are inactivated layer outputs | |
# X and Y are the training data | |
W1, W2, B1, B2, A1, A2, Z1, Z2, X, Y = \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import pandas as pd | |
from sklearn.model_selection import train_test_split | |
all_data = pd.read_csv("https://tinyurl.com/y2qmhfsr") | |
# Learning rate controls how slowly we approach a solution | |
# Make it too small, it will take too long to run. | |
# Make it too big, it will likely overshoot and miss the solution. | |
L = 0.05 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sympy import * | |
a, b, c, d, e, f = symbols('a b c d e f') | |
x1, x2, x3, x4 = symbols('x:4') | |
y1, y2, y3, y4 = symbols('y:4') | |
z1, z2, z3, z4 = symbols('z:4') | |
""" | |
input = Matrix([ | |
[x1, y1], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
from sympy import * | |
# Import points from CSV | |
points = list(pd.read_csv("https://bit.ly/2KF29Bd").itertuples()) | |
m, b, i, n = symbols('m b i n') | |
x, y = symbols('x y', cls=Function) | |
sum_of_squares = Sum((m*x(i) + b - y(i)) ** 2, (i, 0, n)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sympy import * | |
import pandas as pd | |
m, b, i, n = symbols('m b i n') | |
x, y = symbols('x y', cls=Function) | |
joint_likelihood = Sum(log((1.0 / (1.0 + exp(-(b + m * x(i)))))**y(i) * (1.0 - (1.0 / (1.0 + exp(-(b + m * x(i))))))**(1-y(i))), (i, 0, n)) | |
points = list(pd.read_csv("https://tinyurl.com/y2cocoo7").itertuples()) |