Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Christophe #87

Open
wants to merge 39 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
4fb56ff
Finished the lab 1
Thierrix Sep 12, 2024
bc63051
Redesigned the architecture of exs
Thierrix Sep 18, 2024
746b2ce
Merge branch 'epfml:main' into main
Thierrix Sep 18, 2024
0b84144
Finished Exercise Session 2
Thierrix Sep 19, 2024
73fc0d6
Delete taskA.ipynb
Thierrix Sep 19, 2024
077b0c8
Update .gitignore
Thierrix Sep 24, 2024
433a072
Merge branch 'epfml:main' into main
Thierrix Sep 24, 2024
8f8ee9d
Added function build_polynomial
Thierrix Sep 25, 2024
d2191a7
Update ex03.ipynb
Thierrix Oct 2, 2024
3b72f0a
Merge branch 'epfml:main' into main
Thierrix Oct 2, 2024
4e42b4b
Finished the exercice session4
Thierrix Oct 3, 2024
83fceb8
Merge branch 'epfml:main' into main
Thierrix Oct 8, 2024
9b127c0
Finished exercise session 5
Thierrix Oct 8, 2024
2aa305c
Created the project
Thierrix Oct 10, 2024
4f97a30
Created the project, we have some errors
Thierrix Oct 10, 2024
22f2089
PCA is not working otherwise everything works
Thierrix Oct 10, 2024
15c4731
Still problem with PCA
Thierrix Oct 11, 2024
271310b
fix pca
Oct 11, 2024
8c6cb1e
Merge branch 'epfml:main' into main
Thierrix Oct 11, 2024
f0d48ee
Finished creating the run.py and the cleaning_data.py
Thierrix Oct 11, 2024
00956e4
data normalization
Oct 11, 2024
15a8c52
Created the methods to run statistics in stats.py
Thierrix Oct 12, 2024
4c7ae1c
help how to rebalance pleasssouuuuu
Oct 15, 2024
fb59f82
rome ne s'est pas faite en un jour
Oct 15, 2024
aca565a
Merge branch 'epfml:main' into main
Thierrix Oct 16, 2024
2fe3db5
Update gitignore
Thierrix Oct 16, 2024
d4debf2
rome ne s'est pas fait en un jour
Oct 17, 2024
11c5b46
fix conflict
Oct 17, 2024
5f06a12
fix conflict
Oct 17, 2024
adc9aae
this version is good
Oct 17, 2024
f1a731d
Update ex06.ipynb
Thierrix Oct 17, 2024
6057920
Merge branch 'main' of https://github.com/Thierrix/ML_course
Thierrix Oct 17, 2024
4ef2e8d
Update cleaning_data and run
Thierrix Oct 17, 2024
2c85e4b
Updated my exercise session
Thierrix Oct 18, 2024
dac918e
trying things
Oct 18, 2024
ef03aaf
trying things
Oct 18, 2024
291ed65
Create implementations.py
cmlavo Oct 18, 2024
ab09dd0
Moved to projects/project1
cmlavo Oct 18, 2024
8284093
Merge branch 'main' into christophe
Thierrix Oct 18, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,11 @@ ENV/
*.cb2
*.fdb_latexmk
*.synctex.gz
projects/project1/data/dataset/dataset/sample_submission.csv
projects/project1/data/dataset/dataset/x_test.csv
projects/project1/data/dataset/dataset/x_train.csv
projects/project1/data/dataset/dataset/y_train.csv
projects/project1/x_train_cleaned.csv
projects/project1/data/dataset/dataset/x_train_clean.csv
projects/project1/data/dataset/dataset/x_train_cleaned.csv
projects/project1/latex-example-paper.zip
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"git.ignoreLimitWarning": true
}
33 changes: 33 additions & 0 deletions Untitled.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": null,
"id": "f00748fc-eb20-4a98-87ad-0f38fc307222",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python [conda env:ada] *",
"language": "python",
"name": "conda-env-ada-py"
},
"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.11.8"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
86 changes: 73 additions & 13 deletions labs/ex01/template/taskA.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": null,
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -20,7 +20,6 @@
},
{
"cell_type": "markdown",
"execution_count": null,
"metadata": {},
"source": [
"Data Generation\n",
Expand All @@ -29,7 +28,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 2,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -38,7 +37,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 3,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -48,7 +47,6 @@
},
{
"cell_type": "markdown",
"execution_count": null,
"metadata": {},
"source": [
"Solution\n",
Expand All @@ -57,18 +55,43 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 4,
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[[0.77132064 0.02075195 0.63364823 0.74880388 0.49850701]\n",
" [0.22479665 0.19806286 0.76053071 0.16911084 0.08833981]\n",
" [0.68535982 0.95339335 0.00394827 0.51219226 0.81262096]\n",
" [0.61252607 0.72175532 0.29187607 0.91777412 0.71457578]\n",
" [0.54254437 0.14217005 0.37334076 0.67413362 0.44183317]\n",
" [0.43401399 0.61776698 0.51313824 0.65039718 0.60103895]\n",
" [0.8052232 0.52164715 0.90864888 0.31923609 0.09045935]\n",
" [0.30070006 0.11398436 0.82868133 0.04689632 0.62628715]\n",
" [0.54758616 0.819287 0.19894754 0.8568503 0.35165264]\n",
" [0.75464769 0.29596171 0.88393648 0.32551164 0.1650159 ]]\n"
]
}
],
"source": [
"print(data)"
]
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 6,
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"✅ Your `standardize` passed 1 tests.\n"
]
}
],
"source": [
"def standardize(x):\n",
" \"\"\"Stadartize the input data x\n",
Expand All @@ -88,7 +111,8 @@
" # INSERT YOUR CODE HERE\n",
" # TODO: standartize input data x\n",
" # ***************************************************\n",
" raise NotImplementedError\n",
" #Here we use axis=0 because we are standardizing the data by dimension, and hence column\n",
" std_data = (x - np.mean(x, axis = 0))/np.std(x, axis = 0)\n",
" return std_data\n",
"\n",
"\n",
Expand All @@ -97,9 +121,31 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 7,
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[[ 1.0775774 -1.34411605 0.31525355 0.80665878 0.24128662]\n",
" [-1.81711634 -0.77630186 0.74088404 -1.25592235 -1.42276759]\n",
" [ 0.62228127 1.64254169 -1.797091 -0.03521894 1.51565143]\n",
" [ 0.23651339 0.90075228 -0.83122987 1.40786459 1.11788073]\n",
" [-0.13414844 -0.95529104 -0.55795449 0.54097769 0.01136005]\n",
" [-0.70898541 0.56774371 -0.08900028 0.45652209 0.65726018]\n",
" [ 1.2571441 0.25993298 1.23775021 -0.72176808 -1.4141686 ]\n",
" [-1.41508984 -1.04555188 0.96949701 -1.69076861 0.75969247]\n",
" [-0.10744434 1.21308427 -1.14296098 1.19109415 -0.35450368]\n",
" [ 0.98926822 -0.46279408 1.15485183 -0.69943932 -1.11169162]] \n",
"\n",
" [-1.66533454e-16 4.99600361e-17 -2.22044605e-17 1.11022302e-17\n",
" 3.33066907e-16] \n",
"\n",
" [1. 1. 1. 1. 1.]\n"
]
}
],
"source": [
"std_data = standardize(data)\n",
"print(std_data, \"\\n\\n\", np.mean(std_data, axis=0), \"\\n\\n\", np.std(std_data, axis=0))"
Expand All @@ -114,8 +160,22 @@
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"name": "python"
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.7"
}
},
"nbformat": 4,
Expand Down
Loading