https://github.com/ivanvigor/local-fusion-dynamic-weighted-ensemble

This repository contains an implementation for the Dynamic Weighted Ensemble (DWE) - Local Fusion method. Local Fusion is an ensemble techinque that could be used to improve predictions by weighing appropriately the single models contribution.

https://github.com/ivanvigor/local-fusion-dynamic-weighted-ensemble

Science Score: 10.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
    Links to: sciencedirect.com, ieee.org
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (15.7%) to scientific vocabulary

Keywords

anomaly-detection ensemble-machine-learning nuclear python regression-algorithms time-series wind
Last synced: 5 months ago · JSON representation

Repository

This repository contains an implementation for the Dynamic Weighted Ensemble (DWE) - Local Fusion method. Local Fusion is an ensemble techinque that could be used to improve predictions by weighing appropriately the single models contribution.

Basic Info
  • Host: GitHub
  • Owner: IvanVigor
  • License: mit
  • Language: Python
  • Default Branch: master
  • Homepage:
  • Size: 131 KB
Statistics
  • Stars: 8
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Topics
anomaly-detection ensemble-machine-learning nuclear python regression-algorithms time-series wind
Created over 3 years ago · Last pushed over 1 year ago
Metadata Files
Readme License

README.md

Dynamic Weighted Ensemble - Local Fusion

This repository contains an implementation for the Dynamic Weighted Ensemble (DWE) - Local Fusion method. Find the paper in this ref on IEEE.

Local Fusion is an ensemble techinque that could be used to improve predictions by weighing appropriately the single models contribution.

imgs

Installation

Pypi

```{r setup, include=FALSE}

pip install ensemblem

```

Docs - ReadTheDocs (UnderReview)

Usage

First of all, you need to define the KWEnsembler class. Next, it's required to provide the search-space (it could be the validation set / neighbours-set) in which the ensembler will find the nearest elements to the generic test sample.

{r setup, include=FALSE} from ensemblem.model import KWEnsembler ensemble = KWEnsembler(5) ensemble.fit(X_validation, y_validation)

Finally, calling the prediction method the class will produce the forecasts.

{r setup, include=FALSE} ensemble.predict(X_test, features_space, other_model_prediction_columns)

The class returns predictions in the same order in which they are provided. It supports one or multiple samples to forecasts. In this library, we refers to the neighbours-set as the space in which the ensembler will find the nearest elements to the generic test sample.

Example of using the KWEnsembler class

You can find a detailed tutorial in the readthedocs webpage.

  1. Load data
  2. Split data into train, neighbours-set and test sets
  3. Train multiple expert models on the train data
  4. Generate predictions for the test data
  5. Train the ensembler on neighbours-set
  6. Generate predictions for the test dataset using ensembler
  7. Compare the predictions from the ensembler with the predictions from the expert models

Results & Benchmarks

| | Model | MAPE | MAE | RMSE | RMSLE | |---:|:--------|---------:|---------:|----------:|---------:| | 0 | Ensemble | 0.304129 | 0.499381 | 0.0016118 | 0.211999 | | 1 | Tree 1 | 0.370919 | 0.593606 | 0.00755926 | 0.249373 | | 2 | Tree 2 | 0.319638 | 0.511249 | 0.00224047 | 0.225012 | | 3 | RidgeCV | 0.31537 | 0.531177 | 0.0131216 | 0.238018 |

Changelog

15-05-2023 [Fix] Renamed wrong paths

Credits

Algorithm Applications

  • A dynamic weighting ensemble approach for wind energy production prediction IEEE

  • An ensemble approach to sensor fault detection and signal reconstruction for nuclear system control Elsevier

Possible Improvements

  • [Code] Clean-code

  • [Engineering] When dealing with features coming with magnitude and different meaning, it's relevant to normalize values appropriately.

  • [Engineering] Additional measures to the simple euclidean-space

Licence

The code is provided with a MIT licence.

License: MIT

Owner

  • Name: Ivan Vigorito
  • Login: IvanVigor
  • Kind: user
  • Location: Milan, Italy

Data Scientist and Software Engineer. Creativity++

GitHub Events

Total
  • Delete event: 3
Last Year
  • Delete event: 3

Committers

Last synced: about 2 years ago

All Time
  • Total Commits: 95
  • Total Committers: 4
  • Avg Commits per committer: 23.75
  • Development Distribution Score (DDS): 0.347
Past Year
  • Commits: 95
  • Committers: 4
  • Avg Commits per committer: 23.75
  • Development Distribution Score (DDS): 0.347
Top Committers
Name Email Commits
IvanVigor i****4@g****m 62
Ivan Vigorito i****o@I****t 20
Ivan Vigorito i****t@g****m 12
Ivan Vigorito i****o@I****l 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 8 months ago

All Time
  • Total issues: 0
  • Total pull requests: 13
  • Average time to close issues: N/A
  • Average time to close pull requests: 1 minute
  • Total issue authors: 0
  • Total pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 12
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
  • IvanVigor (14)
Top Labels
Issue Labels
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 27 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 12
  • Total maintainers: 1
pypi.org: ensemblem

Dynamic Weighted Ensemble - Local Fusion

  • Versions: 12
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 27 Last month
Rankings
Dependent packages count: 6.6%
Average: 18.6%
Dependent repos count: 30.6%
Maintainers (1)
Last synced: 7 months ago

Dependencies

requirements.txt pypi
  • numpy ==1.23.3
  • pandas ==1.5.0
  • scikit_learn ==1.1.2
setup.py pypi