initial commit
This commit is contained in:
3
.gitattributes
vendored
Normal file
3
.gitattributes
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
[attr]lfs-file filter=lfs diff=lfs merge=lfs -text
|
||||
|
||||
*.pdf lfs-file
|
||||
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
.venv
|
||||
.vscode
|
||||
1
.python-version
Normal file
1
.python-version
Normal file
@@ -0,0 +1 @@
|
||||
3.12
|
||||
108
L2.ipynb
Normal file
108
L2.ipynb
Normal file
@@ -0,0 +1,108 @@
|
||||
{
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 1,
|
||||
"id": "129d4b8c",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"import numpy\n",
|
||||
"import matplotlib.pyplot as plt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "d35579ac",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Study of algorithm\n",
|
||||
"\n",
|
||||
"* Improve Performance, $P$\n",
|
||||
"* At some Task, $T$\n",
|
||||
"* With Experience, $E$\n",
|
||||
"\n",
|
||||
"Learning: **Improving $P$ at $T$ with $E$**\n",
|
||||
"\n",
|
||||
"* $T$: Output\n",
|
||||
"* $E$: Training Data\n",
|
||||
"* $P$: Target (or Loss) function\n",
|
||||
" * If you cannot measure it, you cannot improve it - Kelvin\n",
|
||||
" * e.g.: Error rate, Euclidean distance, Logproba, Information theoretical measures(Mutual information, KL)"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "0d742636",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": []
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "255ea9b1",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Derivation w.r.t Matrix\n",
|
||||
"\n",
|
||||
"In the typical $f: \\R \\to \\R$\n",
|
||||
"$$f(x) = ax, \\quad df/dx = a$$\n",
|
||||
"and\n",
|
||||
"\n",
|
||||
"$$f(x) = x^2, \\quad df/dx = 2x$$\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"By the way, $f = w^Tx,\\, (w \\in \\R^D, x\\in \\R^D)$\n",
|
||||
"\n",
|
||||
"$$\\frac{df}{dx} = \\frac{\\partial f}{\\partial x_1}$$\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"In the case $f(x) = x^2 = x^Tx$\n",
|
||||
"\n",
|
||||
"$$\\frac{df}{dx} = 2x$$\n",
|
||||
"\n",
|
||||
"for example: $f(x) = w^Tx$\n",
|
||||
"\n",
|
||||
"$$f(x) = \\sum w_i x_i$$\n",
|
||||
"$$\\frac{\\partial f}{\\partial x_i} = w_i$$\n",
|
||||
"$$\\therefore \\frac{d f}{d x} = w$$"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "84468a76",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"$tr[M] = \\sum^{D}_{i=1}{M_{ii}}$"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "e8671c90",
|
||||
"metadata": {},
|
||||
"source": []
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
"kernelspec": {
|
||||
"display_name": "2025-02-AI (3.12.11)",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython",
|
||||
"version": 3
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.12.11"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
"nbformat_minor": 5
|
||||
}
|
||||
6
main.py
Normal file
6
main.py
Normal file
@@ -0,0 +1,6 @@
|
||||
def main():
|
||||
print("Hello from 2025-02-ai!")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
BIN
pdf/L1.pdf
(Stored with Git LFS)
Normal file
BIN
pdf/L1.pdf
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
pdf/L2_ML_Intro.pdf
(Stored with Git LFS)
Normal file
BIN
pdf/L2_ML_Intro.pdf
(Stored with Git LFS)
Normal file
Binary file not shown.
11
pyproject.toml
Normal file
11
pyproject.toml
Normal file
@@ -0,0 +1,11 @@
|
||||
[project]
|
||||
name = "2025-02-ai"
|
||||
version = "0.1.0"
|
||||
description = "Add your description here"
|
||||
readme = "README.md"
|
||||
requires-python = ">=3.12"
|
||||
dependencies = [
|
||||
"jupyter>=1.1.1",
|
||||
"matplotlib>=3.10.6",
|
||||
"numpy>=2.3.3",
|
||||
]
|
||||
Reference in New Issue
Block a user