Camillahannesbo commited on
Commit
b47dba5
Β·
1 Parent(s): a102efa

final changes

Browse files
features/__pycache__/calendar.cpython-311.pyc CHANGED
Binary files a/features/__pycache__/calendar.cpython-311.pyc and b/features/__pycache__/calendar.cpython-311.pyc differ
 
features/__pycache__/electricity_prices.cpython-311.pyc CHANGED
Binary files a/features/__pycache__/electricity_prices.cpython-311.pyc and b/features/__pycache__/electricity_prices.cpython-311.pyc differ
 
features/__pycache__/weather_measures.cpython-311.pyc CHANGED
Binary files a/features/__pycache__/weather_measures.cpython-311.pyc and b/features/__pycache__/weather_measures.cpython-311.pyc differ
 
notebooks/1_feature_backfill.ipynb CHANGED
@@ -42,8 +42,8 @@
42
  "name": "stdout",
43
  "output_type": "stream",
44
  "text": [
45
- "/Users/tobiasmjensen/Documents/aau_bds/m5_data-engineering-and-mlops/exam_assigment/MLOPs-Assignment-\n",
46
- "/Users/tobiasmjensen/Documents/aau_bds/m5_data-engineering-and-mlops/exam_assigment/MLOPs-Assignment-/notebooks\n"
47
  ]
48
  }
49
  ],
@@ -953,15 +953,15 @@
953
  " <td>2024-05-10 19:00:00</td>\n",
954
  " <td>2024-05-10</td>\n",
955
  " <td>19</td>\n",
956
- " <td>12.6</td>\n",
957
- " <td>80.0</td>\n",
958
  " <td>0.0</td>\n",
959
  " <td>0.0</td>\n",
960
  " <td>0.0</td>\n",
961
- " <td>1.0</td>\n",
962
- " <td>71.0</td>\n",
963
- " <td>4.3</td>\n",
964
- " <td>15.8</td>\n",
965
  " </tr>\n",
966
  " <tr>\n",
967
  " <th>116</th>\n",
@@ -969,15 +969,15 @@
969
  " <td>2024-05-10 20:00:00</td>\n",
970
  " <td>2024-05-10</td>\n",
971
  " <td>20</td>\n",
972
- " <td>11.2</td>\n",
973
- " <td>83.0</td>\n",
974
  " <td>0.0</td>\n",
975
  " <td>0.0</td>\n",
976
  " <td>0.0</td>\n",
977
- " <td>1.0</td>\n",
978
- " <td>54.0</td>\n",
979
- " <td>4.2</td>\n",
980
- " <td>15.1</td>\n",
981
  " </tr>\n",
982
  " <tr>\n",
983
  " <th>117</th>\n",
@@ -985,15 +985,15 @@
985
  " <td>2024-05-10 21:00:00</td>\n",
986
  " <td>2024-05-10</td>\n",
987
  " <td>21</td>\n",
988
- " <td>10.0</td>\n",
989
- " <td>86.0</td>\n",
990
  " <td>0.0</td>\n",
991
  " <td>0.0</td>\n",
992
  " <td>0.0</td>\n",
993
- " <td>1.0</td>\n",
994
- " <td>37.0</td>\n",
995
- " <td>6.1</td>\n",
996
- " <td>14.4</td>\n",
997
  " </tr>\n",
998
  " <tr>\n",
999
  " <th>118</th>\n",
@@ -1001,15 +1001,15 @@
1001
  " <td>2024-05-10 22:00:00</td>\n",
1002
  " <td>2024-05-10</td>\n",
1003
  " <td>22</td>\n",
1004
- " <td>9.1</td>\n",
1005
- " <td>88.0</td>\n",
1006
- " <td>0.0</td>\n",
1007
  " <td>0.0</td>\n",
1008
  " <td>0.0</td>\n",
1009
  " <td>0.0</td>\n",
1010
- " <td>25.0</td>\n",
1011
- " <td>5.9</td>\n",
1012
- " <td>13.0</td>\n",
 
1013
  " </tr>\n",
1014
  " <tr>\n",
1015
  " <th>119</th>\n",
@@ -1017,15 +1017,15 @@
1017
  " <td>2024-05-10 23:00:00</td>\n",
1018
  " <td>2024-05-10</td>\n",
1019
  " <td>23</td>\n",
1020
- " <td>8.4</td>\n",
1021
- " <td>89.0</td>\n",
1022
  " <td>0.0</td>\n",
1023
  " <td>0.0</td>\n",
1024
  " <td>0.0</td>\n",
1025
- " <td>0.0</td>\n",
1026
- " <td>12.0</td>\n",
1027
- " <td>4.6</td>\n",
1028
- " <td>11.5</td>\n",
1029
  " </tr>\n",
1030
  " </tbody>\n",
1031
  "</table>\n",
@@ -1033,25 +1033,25 @@
1033
  ],
1034
  "text/plain": [
1035
  " timestamp datetime date hour temperature_2m \\\n",
1036
- "115 1715367600000 2024-05-10 19:00:00 2024-05-10 19 12.6 \n",
1037
- "116 1715371200000 2024-05-10 20:00:00 2024-05-10 20 11.2 \n",
1038
- "117 1715374800000 2024-05-10 21:00:00 2024-05-10 21 10.0 \n",
1039
- "118 1715378400000 2024-05-10 22:00:00 2024-05-10 22 9.1 \n",
1040
- "119 1715382000000 2024-05-10 23:00:00 2024-05-10 23 8.4 \n",
1041
  "\n",
1042
  " relative_humidity_2m precipitation rain snowfall weather_code \\\n",
1043
- "115 80.0 0.0 0.0 0.0 1.0 \n",
1044
- "116 83.0 0.0 0.0 0.0 1.0 \n",
1045
- "117 86.0 0.0 0.0 0.0 1.0 \n",
1046
- "118 88.0 0.0 0.0 0.0 0.0 \n",
1047
- "119 89.0 0.0 0.0 0.0 0.0 \n",
1048
  "\n",
1049
  " cloud_cover wind_speed_10m wind_gusts_10m \n",
1050
- "115 71.0 4.3 15.8 \n",
1051
- "116 54.0 4.2 15.1 \n",
1052
- "117 37.0 6.1 14.4 \n",
1053
- "118 25.0 5.9 13.0 \n",
1054
- "119 12.0 4.6 11.5 "
1055
  ]
1056
  },
1057
  "execution_count": 13,
@@ -1366,9 +1366,20 @@
1366
  },
1367
  {
1368
  "cell_type": "code",
1369
- "execution_count": null,
1370
  "metadata": {},
1371
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
1372
  "source": [
1373
  "# Importing the hopsworks module for interacting with the Hopsworks platform\n",
1374
  "import hopsworks\n",
@@ -1400,7 +1411,7 @@
1400
  },
1401
  {
1402
  "cell_type": "code",
1403
- "execution_count": null,
1404
  "metadata": {},
1405
  "outputs": [],
1406
  "source": [
@@ -1424,9 +1435,44 @@
1424
  },
1425
  {
1426
  "cell_type": "code",
1427
- "execution_count": null,
1428
  "metadata": {},
1429
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1430
  "source": [
1431
  "# Inserting the electricity_df into the feature group named electricity_fg\n",
1432
  "electricity_fg.insert(electricity_df)"
@@ -1441,7 +1487,7 @@
1441
  },
1442
  {
1443
  "cell_type": "code",
1444
- "execution_count": null,
1445
  "metadata": {},
1446
  "outputs": [],
1447
  "source": [
@@ -1468,7 +1514,7 @@
1468
  },
1469
  {
1470
  "cell_type": "code",
1471
- "execution_count": null,
1472
  "metadata": {},
1473
  "outputs": [],
1474
  "source": [
@@ -1485,9 +1531,44 @@
1485
  },
1486
  {
1487
  "cell_type": "code",
1488
- "execution_count": null,
1489
  "metadata": {},
1490
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1491
  "source": [
1492
  "# Inserting the weather_df into the feature group named weather_fg\n",
1493
  "weather_fg.insert(historical_weather_df)"
@@ -1495,7 +1576,7 @@
1495
  },
1496
  {
1497
  "cell_type": "code",
1498
- "execution_count": null,
1499
  "metadata": {},
1500
  "outputs": [],
1501
  "source": [
@@ -1523,7 +1604,7 @@
1523
  },
1524
  {
1525
  "cell_type": "code",
1526
- "execution_count": null,
1527
  "metadata": {},
1528
  "outputs": [],
1529
  "source": [
@@ -1539,9 +1620,44 @@
1539
  },
1540
  {
1541
  "cell_type": "code",
1542
- "execution_count": null,
1543
  "metadata": {},
1544
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1545
  "source": [
1546
  "# Inserting the calendar_df into the feature group named danish_calendar_fg\n",
1547
  "danish_calendar_fg.insert(calender_df)"
@@ -1549,7 +1665,7 @@
1549
  },
1550
  {
1551
  "cell_type": "code",
1552
- "execution_count": null,
1553
  "metadata": {},
1554
  "outputs": [],
1555
  "source": [
@@ -1593,7 +1709,7 @@
1593
  "name": "python",
1594
  "nbconvert_exporter": "python",
1595
  "pygments_lexer": "ipython3",
1596
- "version": "3.11.8"
1597
  }
1598
  },
1599
  "nbformat": 4,
 
42
  "name": "stdout",
43
  "output_type": "stream",
44
  "text": [
45
+ "/Users/camillahannesbo/Documents/AAU/Master - BDS/2. semester/Data Engineering and Machine learning operations in Business/MLOPs-Assignment-\n",
46
+ "/Users/camillahannesbo/Documents/AAU/Master - BDS/2. semester/Data Engineering and Machine learning operations in Business/MLOPs-Assignment-/notebooks\n"
47
  ]
48
  }
49
  ],
 
953
  " <td>2024-05-10 19:00:00</td>\n",
954
  " <td>2024-05-10</td>\n",
955
  " <td>19</td>\n",
956
+ " <td>11.5</td>\n",
957
+ " <td>68.0</td>\n",
958
  " <td>0.0</td>\n",
959
  " <td>0.0</td>\n",
960
  " <td>0.0</td>\n",
961
+ " <td>3.0</td>\n",
962
+ " <td>89.0</td>\n",
963
+ " <td>5.2</td>\n",
964
+ " <td>13.0</td>\n",
965
  " </tr>\n",
966
  " <tr>\n",
967
  " <th>116</th>\n",
 
969
  " <td>2024-05-10 20:00:00</td>\n",
970
  " <td>2024-05-10</td>\n",
971
  " <td>20</td>\n",
972
+ " <td>10.5</td>\n",
973
+ " <td>71.0</td>\n",
974
  " <td>0.0</td>\n",
975
  " <td>0.0</td>\n",
976
  " <td>0.0</td>\n",
977
+ " <td>3.0</td>\n",
978
+ " <td>88.0</td>\n",
979
+ " <td>3.4</td>\n",
980
+ " <td>8.6</td>\n",
981
  " </tr>\n",
982
  " <tr>\n",
983
  " <th>117</th>\n",
 
985
  " <td>2024-05-10 21:00:00</td>\n",
986
  " <td>2024-05-10</td>\n",
987
  " <td>21</td>\n",
988
+ " <td>9.5</td>\n",
989
+ " <td>74.0</td>\n",
990
  " <td>0.0</td>\n",
991
  " <td>0.0</td>\n",
992
  " <td>0.0</td>\n",
993
+ " <td>3.0</td>\n",
994
+ " <td>87.0</td>\n",
995
+ " <td>2.5</td>\n",
996
+ " <td>4.3</td>\n",
997
  " </tr>\n",
998
  " <tr>\n",
999
  " <th>118</th>\n",
 
1001
  " <td>2024-05-10 22:00:00</td>\n",
1002
  " <td>2024-05-10</td>\n",
1003
  " <td>22</td>\n",
1004
+ " <td>8.6</td>\n",
1005
+ " <td>78.0</td>\n",
 
1006
  " <td>0.0</td>\n",
1007
  " <td>0.0</td>\n",
1008
  " <td>0.0</td>\n",
1009
+ " <td>3.0</td>\n",
1010
+ " <td>91.0</td>\n",
1011
+ " <td>2.6</td>\n",
1012
+ " <td>4.3</td>\n",
1013
  " </tr>\n",
1014
  " <tr>\n",
1015
  " <th>119</th>\n",
 
1017
  " <td>2024-05-10 23:00:00</td>\n",
1018
  " <td>2024-05-10</td>\n",
1019
  " <td>23</td>\n",
1020
+ " <td>7.8</td>\n",
1021
+ " <td>81.0</td>\n",
1022
  " <td>0.0</td>\n",
1023
  " <td>0.0</td>\n",
1024
  " <td>0.0</td>\n",
1025
+ " <td>3.0</td>\n",
1026
+ " <td>96.0</td>\n",
1027
+ " <td>2.5</td>\n",
1028
+ " <td>4.3</td>\n",
1029
  " </tr>\n",
1030
  " </tbody>\n",
1031
  "</table>\n",
 
1033
  ],
1034
  "text/plain": [
1035
  " timestamp datetime date hour temperature_2m \\\n",
1036
+ "115 1715367600000 2024-05-10 19:00:00 2024-05-10 19 11.5 \n",
1037
+ "116 1715371200000 2024-05-10 20:00:00 2024-05-10 20 10.5 \n",
1038
+ "117 1715374800000 2024-05-10 21:00:00 2024-05-10 21 9.5 \n",
1039
+ "118 1715378400000 2024-05-10 22:00:00 2024-05-10 22 8.6 \n",
1040
+ "119 1715382000000 2024-05-10 23:00:00 2024-05-10 23 7.8 \n",
1041
  "\n",
1042
  " relative_humidity_2m precipitation rain snowfall weather_code \\\n",
1043
+ "115 68.0 0.0 0.0 0.0 3.0 \n",
1044
+ "116 71.0 0.0 0.0 0.0 3.0 \n",
1045
+ "117 74.0 0.0 0.0 0.0 3.0 \n",
1046
+ "118 78.0 0.0 0.0 0.0 3.0 \n",
1047
+ "119 81.0 0.0 0.0 0.0 3.0 \n",
1048
  "\n",
1049
  " cloud_cover wind_speed_10m wind_gusts_10m \n",
1050
+ "115 89.0 5.2 13.0 \n",
1051
+ "116 88.0 3.4 8.6 \n",
1052
+ "117 87.0 2.5 4.3 \n",
1053
+ "118 91.0 2.6 4.3 \n",
1054
+ "119 96.0 2.5 4.3 "
1055
  ]
1056
  },
1057
  "execution_count": 13,
 
1366
  },
1367
  {
1368
  "cell_type": "code",
1369
+ "execution_count": 19,
1370
  "metadata": {},
1371
+ "outputs": [
1372
+ {
1373
+ "name": "stdout",
1374
+ "output_type": "stream",
1375
+ "text": [
1376
+ "Connected. Call `.close()` to terminate connection gracefully.\n",
1377
+ "\n",
1378
+ "Logged in to project, explore it here https://c.app.hopsworks.ai:443/p/550040\n",
1379
+ "Connected. Call `.close()` to terminate connection gracefully.\n"
1380
+ ]
1381
+ }
1382
+ ],
1383
  "source": [
1384
  "# Importing the hopsworks module for interacting with the Hopsworks platform\n",
1385
  "import hopsworks\n",
 
1411
  },
1412
  {
1413
  "cell_type": "code",
1414
+ "execution_count": 20,
1415
  "metadata": {},
1416
  "outputs": [],
1417
  "source": [
 
1435
  },
1436
  {
1437
  "cell_type": "code",
1438
+ "execution_count": 21,
1439
  "metadata": {},
1440
+ "outputs": [
1441
+ {
1442
+ "name": "stdout",
1443
+ "output_type": "stream",
1444
+ "text": [
1445
+ "Feature Group created successfully, explore it at \n",
1446
+ "https://c.app.hopsworks.ai:443/p/550040/fs/545863/fg/787801\n"
1447
+ ]
1448
+ },
1449
+ {
1450
+ "name": "stderr",
1451
+ "output_type": "stream",
1452
+ "text": [
1453
+ "Uploading Dataframe: 100.00% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| Rows 20541/20541 | Elapsed Time: 00:08 | Remaining Time: 00:00\n"
1454
+ ]
1455
+ },
1456
+ {
1457
+ "name": "stdout",
1458
+ "output_type": "stream",
1459
+ "text": [
1460
+ "Launching job: electricity_prices_1_offline_fg_materialization\n",
1461
+ "Job started successfully, you can follow the progress at \n",
1462
+ "https://c.app.hopsworks.ai/p/550040/jobs/named/electricity_prices_1_offline_fg_materialization/executions\n"
1463
+ ]
1464
+ },
1465
+ {
1466
+ "data": {
1467
+ "text/plain": [
1468
+ "(<hsfs.core.job.Job at 0x12fc0d450>, None)"
1469
+ ]
1470
+ },
1471
+ "execution_count": 21,
1472
+ "metadata": {},
1473
+ "output_type": "execute_result"
1474
+ }
1475
+ ],
1476
  "source": [
1477
  "# Inserting the electricity_df into the feature group named electricity_fg\n",
1478
  "electricity_fg.insert(electricity_df)"
 
1487
  },
1488
  {
1489
  "cell_type": "code",
1490
+ "execution_count": 22,
1491
  "metadata": {},
1492
  "outputs": [],
1493
  "source": [
 
1514
  },
1515
  {
1516
  "cell_type": "code",
1517
+ "execution_count": 23,
1518
  "metadata": {},
1519
  "outputs": [],
1520
  "source": [
 
1531
  },
1532
  {
1533
  "cell_type": "code",
1534
+ "execution_count": 24,
1535
  "metadata": {},
1536
+ "outputs": [
1537
+ {
1538
+ "name": "stdout",
1539
+ "output_type": "stream",
1540
+ "text": [
1541
+ "Feature Group created successfully, explore it at \n",
1542
+ "https://c.app.hopsworks.ai:443/p/550040/fs/545863/fg/786783\n"
1543
+ ]
1544
+ },
1545
+ {
1546
+ "name": "stderr",
1547
+ "output_type": "stream",
1548
+ "text": [
1549
+ "Uploading Dataframe: 100.00% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| Rows 20520/20520 | Elapsed Time: 00:08 | Remaining Time: 00:00\n"
1550
+ ]
1551
+ },
1552
+ {
1553
+ "name": "stdout",
1554
+ "output_type": "stream",
1555
+ "text": [
1556
+ "Launching job: weather_measurements_1_offline_fg_materialization\n",
1557
+ "Job started successfully, you can follow the progress at \n",
1558
+ "https://c.app.hopsworks.ai/p/550040/jobs/named/weather_measurements_1_offline_fg_materialization/executions\n"
1559
+ ]
1560
+ },
1561
+ {
1562
+ "data": {
1563
+ "text/plain": [
1564
+ "(<hsfs.core.job.Job at 0x12fbb3b50>, None)"
1565
+ ]
1566
+ },
1567
+ "execution_count": 24,
1568
+ "metadata": {},
1569
+ "output_type": "execute_result"
1570
+ }
1571
+ ],
1572
  "source": [
1573
  "# Inserting the weather_df into the feature group named weather_fg\n",
1574
  "weather_fg.insert(historical_weather_df)"
 
1576
  },
1577
  {
1578
  "cell_type": "code",
1579
+ "execution_count": 25,
1580
  "metadata": {},
1581
  "outputs": [],
1582
  "source": [
 
1604
  },
1605
  {
1606
  "cell_type": "code",
1607
+ "execution_count": 26,
1608
  "metadata": {},
1609
  "outputs": [],
1610
  "source": [
 
1620
  },
1621
  {
1622
  "cell_type": "code",
1623
+ "execution_count": 27,
1624
  "metadata": {},
1625
+ "outputs": [
1626
+ {
1627
+ "name": "stdout",
1628
+ "output_type": "stream",
1629
+ "text": [
1630
+ "Feature Group created successfully, explore it at \n",
1631
+ "https://c.app.hopsworks.ai:443/p/550040/fs/545863/fg/786784\n"
1632
+ ]
1633
+ },
1634
+ {
1635
+ "name": "stderr",
1636
+ "output_type": "stream",
1637
+ "text": [
1638
+ "Uploading Dataframe: 100.00% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| Rows 1096/1096 | Elapsed Time: 00:05 | Remaining Time: 00:00\n"
1639
+ ]
1640
+ },
1641
+ {
1642
+ "name": "stdout",
1643
+ "output_type": "stream",
1644
+ "text": [
1645
+ "Launching job: dk_calendar_1_offline_fg_materialization\n",
1646
+ "Job started successfully, you can follow the progress at \n",
1647
+ "https://c.app.hopsworks.ai/p/550040/jobs/named/dk_calendar_1_offline_fg_materialization/executions\n"
1648
+ ]
1649
+ },
1650
+ {
1651
+ "data": {
1652
+ "text/plain": [
1653
+ "(<hsfs.core.job.Job at 0x12fe04690>, None)"
1654
+ ]
1655
+ },
1656
+ "execution_count": 27,
1657
+ "metadata": {},
1658
+ "output_type": "execute_result"
1659
+ }
1660
+ ],
1661
  "source": [
1662
  "# Inserting the calendar_df into the feature group named danish_calendar_fg\n",
1663
  "danish_calendar_fg.insert(calender_df)"
 
1665
  },
1666
  {
1667
  "cell_type": "code",
1668
+ "execution_count": 28,
1669
  "metadata": {},
1670
  "outputs": [],
1671
  "source": [
 
1709
  "name": "python",
1710
  "nbconvert_exporter": "python",
1711
  "pygments_lexer": "ipython3",
1712
+ "version": "3.11.9"
1713
  }
1714
  },
1715
  "nbformat": 4,
notebooks/2_feature_pipeline.ipynb CHANGED
@@ -34,8 +34,8 @@
34
  "name": "stdout",
35
  "output_type": "stream",
36
  "text": [
37
- "/Users/tobiasmjensen/Documents/aau_bds/m5_data-engineering-and-mlops/exam_assigment/MLOPs-Assignment-\n",
38
- "/Users/tobiasmjensen/Documents/aau_bds/m5_data-engineering-and-mlops/exam_assigment/MLOPs-Assignment-/notebooks\n"
39
  ]
40
  }
41
  ],
@@ -528,15 +528,15 @@
528
  " <td>2024-05-10 19:00:00</td>\n",
529
  " <td>2024-05-10</td>\n",
530
  " <td>19</td>\n",
531
- " <td>12.6</td>\n",
532
- " <td>80.0</td>\n",
533
  " <td>0.0</td>\n",
534
  " <td>0.0</td>\n",
535
  " <td>0.0</td>\n",
536
- " <td>1.0</td>\n",
537
- " <td>71.0</td>\n",
538
- " <td>4.3</td>\n",
539
- " <td>15.8</td>\n",
540
  " </tr>\n",
541
  " <tr>\n",
542
  " <th>116</th>\n",
@@ -544,15 +544,15 @@
544
  " <td>2024-05-10 20:00:00</td>\n",
545
  " <td>2024-05-10</td>\n",
546
  " <td>20</td>\n",
547
- " <td>11.2</td>\n",
548
- " <td>83.0</td>\n",
549
  " <td>0.0</td>\n",
550
  " <td>0.0</td>\n",
551
  " <td>0.0</td>\n",
552
- " <td>1.0</td>\n",
553
- " <td>54.0</td>\n",
554
- " <td>4.2</td>\n",
555
- " <td>15.1</td>\n",
556
  " </tr>\n",
557
  " <tr>\n",
558
  " <th>117</th>\n",
@@ -560,15 +560,15 @@
560
  " <td>2024-05-10 21:00:00</td>\n",
561
  " <td>2024-05-10</td>\n",
562
  " <td>21</td>\n",
563
- " <td>10.0</td>\n",
564
- " <td>86.0</td>\n",
565
  " <td>0.0</td>\n",
566
  " <td>0.0</td>\n",
567
  " <td>0.0</td>\n",
568
- " <td>1.0</td>\n",
569
- " <td>37.0</td>\n",
570
- " <td>6.1</td>\n",
571
- " <td>14.4</td>\n",
572
  " </tr>\n",
573
  " <tr>\n",
574
  " <th>118</th>\n",
@@ -576,15 +576,15 @@
576
  " <td>2024-05-10 22:00:00</td>\n",
577
  " <td>2024-05-10</td>\n",
578
  " <td>22</td>\n",
579
- " <td>9.1</td>\n",
580
- " <td>88.0</td>\n",
581
- " <td>0.0</td>\n",
582
  " <td>0.0</td>\n",
583
  " <td>0.0</td>\n",
584
  " <td>0.0</td>\n",
585
- " <td>25.0</td>\n",
586
- " <td>5.9</td>\n",
587
- " <td>13.0</td>\n",
 
588
  " </tr>\n",
589
  " <tr>\n",
590
  " <th>119</th>\n",
@@ -592,15 +592,15 @@
592
  " <td>2024-05-10 23:00:00</td>\n",
593
  " <td>2024-05-10</td>\n",
594
  " <td>23</td>\n",
595
- " <td>8.4</td>\n",
596
- " <td>89.0</td>\n",
597
- " <td>0.0</td>\n",
598
  " <td>0.0</td>\n",
599
  " <td>0.0</td>\n",
600
  " <td>0.0</td>\n",
601
- " <td>12.0</td>\n",
602
- " <td>4.6</td>\n",
603
- " <td>11.5</td>\n",
 
604
  " </tr>\n",
605
  " </tbody>\n",
606
  "</table>\n",
@@ -615,11 +615,11 @@
615
  "3 1714964400000 2024-05-06 03:00:00 2024-05-06 3 9.5 \n",
616
  "4 1714968000000 2024-05-06 04:00:00 2024-05-06 4 9.6 \n",
617
  ".. ... ... ... ... ... \n",
618
- "115 1715367600000 2024-05-10 19:00:00 2024-05-10 19 12.6 \n",
619
- "116 1715371200000 2024-05-10 20:00:00 2024-05-10 20 11.2 \n",
620
- "117 1715374800000 2024-05-10 21:00:00 2024-05-10 21 10.0 \n",
621
- "118 1715378400000 2024-05-10 22:00:00 2024-05-10 22 9.1 \n",
622
- "119 1715382000000 2024-05-10 23:00:00 2024-05-10 23 8.4 \n",
623
  "\n",
624
  " relative_humidity_2m precipitation rain snowfall weather_code \\\n",
625
  "0 93.0 0.2 0.2 0.0 51.0 \n",
@@ -628,11 +628,11 @@
628
  "3 91.0 0.0 0.0 0.0 3.0 \n",
629
  "4 92.0 0.0 0.0 0.0 3.0 \n",
630
  ".. ... ... ... ... ... \n",
631
- "115 80.0 0.0 0.0 0.0 1.0 \n",
632
- "116 83.0 0.0 0.0 0.0 1.0 \n",
633
- "117 86.0 0.0 0.0 0.0 1.0 \n",
634
- "118 88.0 0.0 0.0 0.0 0.0 \n",
635
- "119 89.0 0.0 0.0 0.0 0.0 \n",
636
  "\n",
637
  " cloud_cover wind_speed_10m wind_gusts_10m \n",
638
  "0 100.0 14.4 24.8 \n",
@@ -641,11 +641,11 @@
641
  "3 100.0 13.0 23.4 \n",
642
  "4 100.0 14.0 24.1 \n",
643
  ".. ... ... ... \n",
644
- "115 71.0 4.3 15.8 \n",
645
- "116 54.0 4.2 15.1 \n",
646
- "117 37.0 6.1 14.4 \n",
647
- "118 25.0 5.9 13.0 \n",
648
- "119 12.0 4.6 11.5 \n",
649
  "\n",
650
  "[120 rows x 13 columns]"
651
  ]
@@ -671,9 +671,20 @@
671
  },
672
  {
673
  "cell_type": "code",
674
- "execution_count": null,
675
  "metadata": {},
676
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
677
  "source": [
678
  "# Importing the hopsworks module for interacting with the Hopsworks platform\n",
679
  "import hopsworks\n",
@@ -687,7 +698,7 @@
687
  },
688
  {
689
  "cell_type": "code",
690
- "execution_count": null,
691
  "metadata": {},
692
  "outputs": [],
693
  "source": [
@@ -713,9 +724,36 @@
713
  },
714
  {
715
  "cell_type": "code",
716
- "execution_count": null,
717
  "metadata": {},
718
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
719
  "source": [
720
  "# Inserting the electricity_df into the feature group named electricity_fg\n",
721
  "electricity_fg.insert(electricity_df, \n",
@@ -724,9 +762,36 @@
724
  },
725
  {
726
  "cell_type": "code",
727
- "execution_count": null,
728
  "metadata": {},
729
- "outputs": [],
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
730
  "source": [
731
  "# Inserting the weather_df into the feature group named weather_fg\n",
732
  "weather_fg.insert(weather_forecast_df, \n",
@@ -760,7 +825,7 @@
760
  "name": "python",
761
  "nbconvert_exporter": "python",
762
  "pygments_lexer": "ipython3",
763
- "version": "3.11.8"
764
  },
765
  "orig_nbformat": 4
766
  },
 
34
  "name": "stdout",
35
  "output_type": "stream",
36
  "text": [
37
+ "/Users/camillahannesbo/Documents/AAU/Master - BDS/2. semester/Data Engineering and Machine learning operations in Business/MLOPs-Assignment-\n",
38
+ "/Users/camillahannesbo/Documents/AAU/Master - BDS/2. semester/Data Engineering and Machine learning operations in Business/MLOPs-Assignment-/notebooks\n"
39
  ]
40
  }
41
  ],
 
528
  " <td>2024-05-10 19:00:00</td>\n",
529
  " <td>2024-05-10</td>\n",
530
  " <td>19</td>\n",
531
+ " <td>11.5</td>\n",
532
+ " <td>68.0</td>\n",
533
  " <td>0.0</td>\n",
534
  " <td>0.0</td>\n",
535
  " <td>0.0</td>\n",
536
+ " <td>3.0</td>\n",
537
+ " <td>89.0</td>\n",
538
+ " <td>5.2</td>\n",
539
+ " <td>13.0</td>\n",
540
  " </tr>\n",
541
  " <tr>\n",
542
  " <th>116</th>\n",
 
544
  " <td>2024-05-10 20:00:00</td>\n",
545
  " <td>2024-05-10</td>\n",
546
  " <td>20</td>\n",
547
+ " <td>10.5</td>\n",
548
+ " <td>71.0</td>\n",
549
  " <td>0.0</td>\n",
550
  " <td>0.0</td>\n",
551
  " <td>0.0</td>\n",
552
+ " <td>3.0</td>\n",
553
+ " <td>88.0</td>\n",
554
+ " <td>3.4</td>\n",
555
+ " <td>8.6</td>\n",
556
  " </tr>\n",
557
  " <tr>\n",
558
  " <th>117</th>\n",
 
560
  " <td>2024-05-10 21:00:00</td>\n",
561
  " <td>2024-05-10</td>\n",
562
  " <td>21</td>\n",
563
+ " <td>9.5</td>\n",
564
+ " <td>74.0</td>\n",
565
  " <td>0.0</td>\n",
566
  " <td>0.0</td>\n",
567
  " <td>0.0</td>\n",
568
+ " <td>3.0</td>\n",
569
+ " <td>87.0</td>\n",
570
+ " <td>2.5</td>\n",
571
+ " <td>4.3</td>\n",
572
  " </tr>\n",
573
  " <tr>\n",
574
  " <th>118</th>\n",
 
576
  " <td>2024-05-10 22:00:00</td>\n",
577
  " <td>2024-05-10</td>\n",
578
  " <td>22</td>\n",
579
+ " <td>8.6</td>\n",
580
+ " <td>78.0</td>\n",
 
581
  " <td>0.0</td>\n",
582
  " <td>0.0</td>\n",
583
  " <td>0.0</td>\n",
584
+ " <td>3.0</td>\n",
585
+ " <td>91.0</td>\n",
586
+ " <td>2.6</td>\n",
587
+ " <td>4.3</td>\n",
588
  " </tr>\n",
589
  " <tr>\n",
590
  " <th>119</th>\n",
 
592
  " <td>2024-05-10 23:00:00</td>\n",
593
  " <td>2024-05-10</td>\n",
594
  " <td>23</td>\n",
595
+ " <td>7.8</td>\n",
596
+ " <td>81.0</td>\n",
 
597
  " <td>0.0</td>\n",
598
  " <td>0.0</td>\n",
599
  " <td>0.0</td>\n",
600
+ " <td>3.0</td>\n",
601
+ " <td>96.0</td>\n",
602
+ " <td>2.5</td>\n",
603
+ " <td>4.3</td>\n",
604
  " </tr>\n",
605
  " </tbody>\n",
606
  "</table>\n",
 
615
  "3 1714964400000 2024-05-06 03:00:00 2024-05-06 3 9.5 \n",
616
  "4 1714968000000 2024-05-06 04:00:00 2024-05-06 4 9.6 \n",
617
  ".. ... ... ... ... ... \n",
618
+ "115 1715367600000 2024-05-10 19:00:00 2024-05-10 19 11.5 \n",
619
+ "116 1715371200000 2024-05-10 20:00:00 2024-05-10 20 10.5 \n",
620
+ "117 1715374800000 2024-05-10 21:00:00 2024-05-10 21 9.5 \n",
621
+ "118 1715378400000 2024-05-10 22:00:00 2024-05-10 22 8.6 \n",
622
+ "119 1715382000000 2024-05-10 23:00:00 2024-05-10 23 7.8 \n",
623
  "\n",
624
  " relative_humidity_2m precipitation rain snowfall weather_code \\\n",
625
  "0 93.0 0.2 0.2 0.0 51.0 \n",
 
628
  "3 91.0 0.0 0.0 0.0 3.0 \n",
629
  "4 92.0 0.0 0.0 0.0 3.0 \n",
630
  ".. ... ... ... ... ... \n",
631
+ "115 68.0 0.0 0.0 0.0 3.0 \n",
632
+ "116 71.0 0.0 0.0 0.0 3.0 \n",
633
+ "117 74.0 0.0 0.0 0.0 3.0 \n",
634
+ "118 78.0 0.0 0.0 0.0 3.0 \n",
635
+ "119 81.0 0.0 0.0 0.0 3.0 \n",
636
  "\n",
637
  " cloud_cover wind_speed_10m wind_gusts_10m \n",
638
  "0 100.0 14.4 24.8 \n",
 
641
  "3 100.0 13.0 23.4 \n",
642
  "4 100.0 14.0 24.1 \n",
643
  ".. ... ... ... \n",
644
+ "115 89.0 5.2 13.0 \n",
645
+ "116 88.0 3.4 8.6 \n",
646
+ "117 87.0 2.5 4.3 \n",
647
+ "118 91.0 2.6 4.3 \n",
648
+ "119 96.0 2.5 4.3 \n",
649
  "\n",
650
  "[120 rows x 13 columns]"
651
  ]
 
671
  },
672
  {
673
  "cell_type": "code",
674
+ "execution_count": 7,
675
  "metadata": {},
676
+ "outputs": [
677
+ {
678
+ "name": "stdout",
679
+ "output_type": "stream",
680
+ "text": [
681
+ "Connected. Call `.close()` to terminate connection gracefully.\n",
682
+ "\n",
683
+ "Logged in to project, explore it here https://c.app.hopsworks.ai:443/p/550040\n",
684
+ "Connected. Call `.close()` to terminate connection gracefully.\n"
685
+ ]
686
+ }
687
+ ],
688
  "source": [
689
  "# Importing the hopsworks module for interacting with the Hopsworks platform\n",
690
  "import hopsworks\n",
 
698
  },
699
  {
700
  "cell_type": "code",
701
+ "execution_count": 8,
702
  "metadata": {},
703
  "outputs": [],
704
  "source": [
 
724
  },
725
  {
726
  "cell_type": "code",
727
+ "execution_count": 9,
728
  "metadata": {},
729
+ "outputs": [
730
+ {
731
+ "name": "stderr",
732
+ "output_type": "stream",
733
+ "text": [
734
+ "Uploading Dataframe: 100.00% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| Rows 24/24 | Elapsed Time: 00:06 | Remaining Time: 00:00\n"
735
+ ]
736
+ },
737
+ {
738
+ "name": "stdout",
739
+ "output_type": "stream",
740
+ "text": [
741
+ "Launching job: electricity_prices_1_offline_fg_materialization\n",
742
+ "Job started successfully, you can follow the progress at \n",
743
+ "https://c.app.hopsworks.ai/p/550040/jobs/named/electricity_prices_1_offline_fg_materialization/executions\n"
744
+ ]
745
+ },
746
+ {
747
+ "data": {
748
+ "text/plain": [
749
+ "(<hsfs.core.job.Job at 0x13aea7b90>, None)"
750
+ ]
751
+ },
752
+ "execution_count": 9,
753
+ "metadata": {},
754
+ "output_type": "execute_result"
755
+ }
756
+ ],
757
  "source": [
758
  "# Inserting the electricity_df into the feature group named electricity_fg\n",
759
  "electricity_fg.insert(electricity_df, \n",
 
762
  },
763
  {
764
  "cell_type": "code",
765
+ "execution_count": 10,
766
  "metadata": {},
767
+ "outputs": [
768
+ {
769
+ "name": "stderr",
770
+ "output_type": "stream",
771
+ "text": [
772
+ "Uploading Dataframe: 100.00% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| Rows 120/120 | Elapsed Time: 00:06 | Remaining Time: 00:00\n"
773
+ ]
774
+ },
775
+ {
776
+ "name": "stdout",
777
+ "output_type": "stream",
778
+ "text": [
779
+ "Launching job: weather_measurements_1_offline_fg_materialization\n",
780
+ "Job started successfully, you can follow the progress at \n",
781
+ "https://c.app.hopsworks.ai/p/550040/jobs/named/weather_measurements_1_offline_fg_materialization/executions\n"
782
+ ]
783
+ },
784
+ {
785
+ "data": {
786
+ "text/plain": [
787
+ "(<hsfs.core.job.Job at 0x13aea7d50>, None)"
788
+ ]
789
+ },
790
+ "execution_count": 10,
791
+ "metadata": {},
792
+ "output_type": "execute_result"
793
+ }
794
+ ],
795
  "source": [
796
  "# Inserting the weather_df into the feature group named weather_fg\n",
797
  "weather_fg.insert(weather_forecast_df, \n",
 
825
  "name": "python",
826
  "nbconvert_exporter": "python",
827
  "pygments_lexer": "ipython3",
828
+ "version": "3.11.9"
829
  },
830
  "orig_nbformat": 4
831
  },
notebooks/3_training_pipeline.ipynb CHANGED
The diff for this file is too large to render. See raw diff
 
notebooks/4_batch_inference.ipynb CHANGED
The diff for this file is too large to render. See raw diff
 
notebooks/model/dk_electricity_model.pkl CHANGED
Binary files a/notebooks/model/dk_electricity_model.pkl and b/notebooks/model/dk_electricity_model.pkl differ