|
4 | 4 |
|
5 | 5 | from pathlib import Path |
6 | 6 |
|
7 | | -from ._utils import load_dataset_files, load_simple_dataset |
| 7 | +from ._utils import download_dataset, load_dataset_files, load_simple_dataset |
8 | 8 |
|
9 | 9 |
|
10 | 10 | def fetch_employee_salaries(data_home=None, split="all"): |
@@ -606,3 +606,44 @@ def fetch_california_housing(data_home=None): |
606 | 606 | The path to the california housing CSV file. |
607 | 607 | """ |
608 | 608 | return load_simple_dataset("california_housing", data_home) |
| 609 | + |
| 610 | + |
| 611 | +def fetch_electricity_forecasting(data_home=None): |
| 612 | + """Fetches the electricity usage dataset (forecasting), available at \ |
| 613 | + https://github.com/skrub-data/skrub-data-files |
| 614 | +
|
| 615 | + Description of the dataset: |
| 616 | + This dataset was generated from data obtained from the |
| 617 | + ENTSOE Open Data portal under the open source license (CC-BY 4.0): |
| 618 | + https://transparencyplatform.zendesk.com/hc/article_attachments/40921869376401 |
| 619 | +
|
| 620 | + and the Open Meteo Historical Weather API: |
| 621 | + https://open-meteo.com/en/docs/historical-forecast-api |
| 622 | + in accordance with the licence described: |
| 623 | + https://open-meteo.com/en/licence |
| 624 | +
|
| 625 | + This is a time-series forecasting use case. This dataset gives the total |
| 626 | + electricity load in MW in France, covering a time range from |
| 627 | + March 23, 2021 to May 31, 2025. In addition, the dataset contains |
| 628 | + weather data for several cities within France. |
| 629 | +
|
| 630 | + It can be downloaded/loaded using the |
| 631 | + sklearn.datasets.fetch_electricity_forecasting function. |
| 632 | + Size on disk: 26MB. |
| 633 | +
|
| 634 | + Parameters |
| 635 | + ---------- |
| 636 | + data_home: str or path, default=None |
| 637 | + The directory where to download and unzip the files. |
| 638 | +
|
| 639 | + Returns |
| 640 | + ------- |
| 641 | + Path : PosixPath |
| 642 | + The path to the electricity usage CSV files |
| 643 | +
|
| 644 | + References |
| 645 | + ---------- |
| 646 | + .. [1] For more detailed instructions on how to use this dataset, please refer |
| 647 | + to the example here: `EuroSciPy2025 <https://github.com/skrub-data/EuroSciPy2025>`_ |
| 648 | + """ |
| 649 | + return download_dataset("electricity_forecasting", data_home=data_home) |
0 commit comments