Skip to content

Commit

Permalink
setup venv, torch, tensorflow
Browse files Browse the repository at this point in the history
  • Loading branch information
ChriSil committed Apr 1, 2024
1 parent 8b3352b commit 27d1055
Show file tree
Hide file tree
Showing 3 changed files with 112 additions and 208 deletions.
216 changes: 11 additions & 205 deletions basic_data_exploration/melbourne.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,213 +2,19 @@
"cells": [
{
"cell_type": "code",
"execution_count": 14,
"execution_count": 1,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>Rooms</th>\n",
" <th>Price</th>\n",
" <th>Distance</th>\n",
" <th>Postcode</th>\n",
" <th>Bedroom2</th>\n",
" <th>Bathroom</th>\n",
" <th>Car</th>\n",
" <th>Landsize</th>\n",
" <th>BuildingArea</th>\n",
" <th>YearBuilt</th>\n",
" <th>Lattitude</th>\n",
" <th>Longtitude</th>\n",
" <th>Propertycount</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>count</th>\n",
" <td>13580.000000</td>\n",
" <td>1.358000e+04</td>\n",
" <td>13580.000000</td>\n",
" <td>13580.000000</td>\n",
" <td>13580.000000</td>\n",
" <td>13580.000000</td>\n",
" <td>13518.000000</td>\n",
" <td>13580.000000</td>\n",
" <td>7130.000000</td>\n",
" <td>8205.000000</td>\n",
" <td>13580.000000</td>\n",
" <td>13580.000000</td>\n",
" <td>13580.000000</td>\n",
" </tr>\n",
" <tr>\n",
" <th>mean</th>\n",
" <td>2.937997</td>\n",
" <td>1.075684e+06</td>\n",
" <td>10.137776</td>\n",
" <td>3105.301915</td>\n",
" <td>2.914728</td>\n",
" <td>1.534242</td>\n",
" <td>1.610075</td>\n",
" <td>558.416127</td>\n",
" <td>151.967650</td>\n",
" <td>1964.684217</td>\n",
" <td>-37.809203</td>\n",
" <td>144.995216</td>\n",
" <td>7454.417378</td>\n",
" </tr>\n",
" <tr>\n",
" <th>std</th>\n",
" <td>0.955748</td>\n",
" <td>6.393107e+05</td>\n",
" <td>5.868725</td>\n",
" <td>90.676964</td>\n",
" <td>0.965921</td>\n",
" <td>0.691712</td>\n",
" <td>0.962634</td>\n",
" <td>3990.669241</td>\n",
" <td>541.014538</td>\n",
" <td>37.273762</td>\n",
" <td>0.079260</td>\n",
" <td>0.103916</td>\n",
" <td>4378.581772</td>\n",
" </tr>\n",
" <tr>\n",
" <th>min</th>\n",
" <td>1.000000</td>\n",
" <td>8.500000e+04</td>\n",
" <td>0.000000</td>\n",
" <td>3000.000000</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>1196.000000</td>\n",
" <td>-38.182550</td>\n",
" <td>144.431810</td>\n",
" <td>249.000000</td>\n",
" </tr>\n",
" <tr>\n",
" <th>25%</th>\n",
" <td>2.000000</td>\n",
" <td>6.500000e+05</td>\n",
" <td>6.100000</td>\n",
" <td>3044.000000</td>\n",
" <td>2.000000</td>\n",
" <td>1.000000</td>\n",
" <td>1.000000</td>\n",
" <td>177.000000</td>\n",
" <td>93.000000</td>\n",
" <td>1940.000000</td>\n",
" <td>-37.856822</td>\n",
" <td>144.929600</td>\n",
" <td>4380.000000</td>\n",
" </tr>\n",
" <tr>\n",
" <th>50%</th>\n",
" <td>3.000000</td>\n",
" <td>9.030000e+05</td>\n",
" <td>9.200000</td>\n",
" <td>3084.000000</td>\n",
" <td>3.000000</td>\n",
" <td>1.000000</td>\n",
" <td>2.000000</td>\n",
" <td>440.000000</td>\n",
" <td>126.000000</td>\n",
" <td>1970.000000</td>\n",
" <td>-37.802355</td>\n",
" <td>145.000100</td>\n",
" <td>6555.000000</td>\n",
" </tr>\n",
" <tr>\n",
" <th>75%</th>\n",
" <td>3.000000</td>\n",
" <td>1.330000e+06</td>\n",
" <td>13.000000</td>\n",
" <td>3148.000000</td>\n",
" <td>3.000000</td>\n",
" <td>2.000000</td>\n",
" <td>2.000000</td>\n",
" <td>651.000000</td>\n",
" <td>174.000000</td>\n",
" <td>1999.000000</td>\n",
" <td>-37.756400</td>\n",
" <td>145.058305</td>\n",
" <td>10331.000000</td>\n",
" </tr>\n",
" <tr>\n",
" <th>max</th>\n",
" <td>10.000000</td>\n",
" <td>9.000000e+06</td>\n",
" <td>48.100000</td>\n",
" <td>3977.000000</td>\n",
" <td>20.000000</td>\n",
" <td>8.000000</td>\n",
" <td>10.000000</td>\n",
" <td>433014.000000</td>\n",
" <td>44515.000000</td>\n",
" <td>2018.000000</td>\n",
" <td>-37.408530</td>\n",
" <td>145.526350</td>\n",
" <td>21650.000000</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" Rooms Price Distance Postcode Bedroom2 \\\n",
"count 13580.000000 1.358000e+04 13580.000000 13580.000000 13580.000000 \n",
"mean 2.937997 1.075684e+06 10.137776 3105.301915 2.914728 \n",
"std 0.955748 6.393107e+05 5.868725 90.676964 0.965921 \n",
"min 1.000000 8.500000e+04 0.000000 3000.000000 0.000000 \n",
"25% 2.000000 6.500000e+05 6.100000 3044.000000 2.000000 \n",
"50% 3.000000 9.030000e+05 9.200000 3084.000000 3.000000 \n",
"75% 3.000000 1.330000e+06 13.000000 3148.000000 3.000000 \n",
"max 10.000000 9.000000e+06 48.100000 3977.000000 20.000000 \n",
"\n",
" Bathroom Car Landsize BuildingArea YearBuilt \\\n",
"count 13580.000000 13518.000000 13580.000000 7130.000000 8205.000000 \n",
"mean 1.534242 1.610075 558.416127 151.967650 1964.684217 \n",
"std 0.691712 0.962634 3990.669241 541.014538 37.273762 \n",
"min 0.000000 0.000000 0.000000 0.000000 1196.000000 \n",
"25% 1.000000 1.000000 177.000000 93.000000 1940.000000 \n",
"50% 1.000000 2.000000 440.000000 126.000000 1970.000000 \n",
"75% 2.000000 2.000000 651.000000 174.000000 1999.000000 \n",
"max 8.000000 10.000000 433014.000000 44515.000000 2018.000000 \n",
"\n",
" Lattitude Longtitude Propertycount \n",
"count 13580.000000 13580.000000 13580.000000 \n",
"mean -37.809203 144.995216 7454.417378 \n",
"std 0.079260 0.103916 4378.581772 \n",
"min -38.182550 144.431810 249.000000 \n",
"25% -37.856822 144.929600 4380.000000 \n",
"50% -37.802355 145.000100 6555.000000 \n",
"75% -37.756400 145.058305 10331.000000 \n",
"max -37.408530 145.526350 21650.000000 "
]
},
"execution_count": 14,
"metadata": {},
"output_type": "execute_result"
"ename": "ModuleNotFoundError",
"evalue": "No module named 'pandas'",
"output_type": "error",
"traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
"\u001b[0;31mModuleNotFoundError\u001b[0m Traceback (most recent call last)",
"Cell \u001b[0;32mIn[1], line 1\u001b[0m\n\u001b[0;32m----> 1\u001b[0m \u001b[38;5;28;01mimport\u001b[39;00m \u001b[38;5;21;01mpandas\u001b[39;00m \u001b[38;5;28;01mas\u001b[39;00m \u001b[38;5;21;01mpd\u001b[39;00m\n\u001b[1;32m 3\u001b[0m melbourne_data \u001b[38;5;241m=\u001b[39m pd\u001b[38;5;241m.\u001b[39mread_csv(\u001b[38;5;124m'\u001b[39m\u001b[38;5;124m../data/melb_data.csv\u001b[39m\u001b[38;5;124m'\u001b[39m)\n\u001b[1;32m 5\u001b[0m melbourne_data\u001b[38;5;241m.\u001b[39mdescribe()\n",
"\u001b[0;31mModuleNotFoundError\u001b[0m: No module named 'pandas'"
]
}
],
"source": [
Expand Down Expand Up @@ -1321,7 +1127,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.1"
"version": "3.11.8"
}
},
"nbformat": 4,
Expand Down
17 changes: 14 additions & 3 deletions intro_deep_learning/neuron.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,20 @@
"cells": [
{
"cell_type": "code",
"execution_count": 7,
"execution_count": 1,
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"2024-04-01 12:31:16.478183: I tensorflow/core/util/port.cc:113] oneDNN custom operations are on. You may see slightly different numerical results due to floating-point round-off errors from different computation orders. To turn them off, set the environment variable `TF_ENABLE_ONEDNN_OPTS=0`.\n",
"2024-04-01 12:31:16.502568: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\n",
"To enable the following instructions: AVX2 AVX_VNNI FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\n",
"2024-04-01 12:31:16.868944: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT\n"
]
}
],
"source": [
"from tensorflow import keras\n",
"from tensorflow.keras import layers\n",
Expand Down Expand Up @@ -32,7 +43,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.1"
"version": "3.11.8"
}
},
"nbformat": 4,
Expand Down
87 changes: 87 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
absl-py==2.1.0
asttokens==2.4.1
astunparse==1.6.3
certifi==2024.2.2
charset-normalizer==3.3.2
comm==0.2.2
debugpy==1.8.1
decorator==5.1.1
executing==2.0.1
filelock==3.13.3
flatbuffers==24.3.25
fsspec==2024.3.1
gast==0.5.4
google-pasta==0.2.0
grpcio==1.62.1
h5py==3.10.0
idna==3.6
ipykernel==6.29.4
ipython==8.23.0
jedi==0.19.1
Jinja2==3.1.3
jupyter_client==8.6.1
jupyter_core==5.7.2
keras==3.1.1
libclang==18.1.1
Markdown==3.6
markdown-it-py==3.0.0
MarkupSafe==2.1.5
matplotlib-inline==0.1.6
mdurl==0.1.2
ml-dtypes==0.3.2
mpmath==1.3.0
namex==0.0.7
nest-asyncio==1.6.0
networkx==3.2.1
numpy==1.26.4
nvidia-cublas-cu12==12.1.3.1
nvidia-cuda-cupti-cu12==12.1.105
nvidia-cuda-nvrtc-cu12==12.1.105
nvidia-cuda-runtime-cu12==12.1.105
nvidia-cudnn-cu12==8.9.2.26
nvidia-cufft-cu12==11.0.2.54
nvidia-curand-cu12==10.3.2.106
nvidia-cusolver-cu12==11.4.5.107
nvidia-cusparse-cu12==12.1.0.106
nvidia-nccl-cu12==2.19.3
nvidia-nvjitlink-cu12==12.4.99
nvidia-nvtx-cu12==12.1.105
opt-einsum==3.3.0
optree==0.11.0
packaging==24.0
pandas==2.2.1
parso==0.8.3
pexpect==4.9.0
pillow==10.2.0
platformdirs==4.2.0
prompt-toolkit==3.0.43
protobuf==4.25.3
psutil==5.9.8
ptyprocess==0.7.0
pure-eval==0.2.2
Pygments==2.17.2
python-dateutil==2.9.0.post0
pytz==2024.1
pyzmq==25.1.2
requests==2.31.0
rich==13.7.1
six==1.16.0
stack-data==0.6.3
sympy==1.12
tensorboard==2.16.2
tensorboard-data-server==0.7.2
tensorflow==2.16.1
tensorflow-io-gcs-filesystem==0.36.0
termcolor==2.4.0
torch==2.2.2
torchaudio==2.2.2
torchvision==0.17.2
tornado==6.4
traitlets==5.14.2
triton==2.2.0
typing_extensions==4.10.0
tzdata==2024.1
urllib3==2.2.1
wcwidth==0.2.13
Werkzeug==3.0.1
wrapt==1.16.0

0 comments on commit 27d1055

Please sign in to comment.