epanetCPA is an open-source object-oriented MatLab toolbox for modelling the hydraulic response of water distribution systems to cyber-physical attacks. epanetCPA allows users to quickly design various attack scenarios and assess their impact via simulation with EPANET, a popular public-domain model for water network analysis.

Download (MatLab toolbox)


> Taormina, R., Galelli, S., Tippenhauer, N.O., Salomon, E., Ostfeld, A. (2017) Characterising cyber-physical attacks on water distribution systems. Journal of Water Resources Planning and Management, 143(5), 04017009. Link Video

> Taormina, R., Galelli, S., Tippenhauer, N.O., Salomon, E., Ostfeld, A, Eliades, D. … Ohar, Z. The battle of the attack detection algorithms: disclosing cyber attacks on water distribution networks. Journal of Water Resources Planning and Management, doi: 10.1061/(ASCE)WR.1943-5452.0000969.


reservoir is a R package for the analysis, design, and operation of water supply reservoirs. It features some popular techniques, such as Dynamic Programming, Stochastic Dynamic Programming and Storage-Yield-Reliability analysis.

Download (R package)


> Turner, S.W.D., Galelli, S. (2016) Water supply sensitivity to climate change: an R package for implementing reservoir storage analysis in global and regional impact studies. Environmental Modelling & Software, 76, 13-19. Link

Iterative Input variable Selection 

IIS is a variable (feature) selection algorithm developed by Stefano Galelli and Andrea Castelletti. It is based on a regression/classification method–Extremely Randomised Trees–that ensures computational efficiency and scalability to high dimensional problems.

Download (MatLab/C library)


> Galelli, S., Castelletti, A. (2013) Tree-based Iterative Input variable Selection for hydrological modelling. Water Resources Research, 49(7), 4295-4310. Link

> Galelli, S., Castelletti, A. (2013) Assessing the predictive capability of randomized tree-based ensembles in streamflow modelling. Hydrology and Earth System Sciences, 17, 2669-2684. Link

(Quasi) Equally Informative Subsets Selection 

This library implements the Wrapper for Quasi Equally Informative Subset Selection (W-QEISS) algorithm–developed by Gulsah Karakaya, Stefano Galelli, Selin Ahipasaoglu and Riccardo Taormina. The algorithm solves variable selection problems (for both classification and regression) and returns multiple subsets having similar predictive performance.

Download (MatLab library)


> Taormina, R., Galelli, S., Karakaya, G., Ahipasaoglu, S.D. (2016) An information theoretic approach to select alternate subsets of predictors for data-driven hydrological models. Journal of Hydrology, 542, 18-34. Link

> Karakaya, G., Galelli, S., Ahipasaoglu, S.D., Taormina, R. (2016) Identifying (quasi) equally informative subsets in feature selection problems for classication: a max-relevance min-redundancy approach. Cybernetics, IEEE Transactions on, 46(6), 1424-1437. Link

Input Variable Selection framework

The IVS framework was developed by Stefano Galelli, Greer Humphrey, Holger Maier, Andrea Castelletti and Graeme Dandy. It features a wide range of datasets and performance metrics for testing IVS algorithms, as well as a dedicated website for sharing data, algorithms and results.

Link to IVS4EM website


> Galelli, S., Humphrey, G.B., Maier, H.R., Castelletti, A., Dandy, G.C., Gibbs, M.S. (2014) An evaluation framework for input variable selection algorithms for environmental data-driven models (2014). Environmental Modelling & Software, 62, 33-51. Link


scenario is a R package to construct a (inflow) scenario tree for use in multi-stage stochastic programming applications.

Download (R package)

Sparse PCA 

spca_am is a MatLab toolbox for Sparse Principal Component Analysis developed by Ahmed Alsahaf. The toolbox implements 8 different optimization formulations of Sparse PCA introduced by Richtarik et al. (2012).

Download (MatLab library)