Metadata-Version: 2.4
Name: less-learn
Version: 0.5.0
Summary: Learning with Subset Stacking
Home-page: https://github.com/sibirbil/LESS
Author-email: Ilker Birbil <sibirbil@gmail.com>, Samet Copur <sametcopur@yahoo.com>
Maintainer: Ilker Birbil, Samet Çopur
Maintainer-email: s.i.birbil@uva.nl, sametcopur@yahoo.com
License: MIT License
Project-URL: Repository, https://github.com/sibirbil/LESS
Project-URL: Tracker, https://github.com/sibirbil/LESS/issues
Keywords: python,optimization,adaptive-random-search,hyperparameter-tuning,hyperparameter-optimization,mixed-parameter-space,categorical-parameters,machine-learning,data-science,metaheuristics
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Science/Research
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Mathematics
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Software Development
Classifier: Topic :: Software Development :: Libraries
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy
Requires-Dist: scipy
Requires-Dist: scikit-learn
Requires-Dist: xgboost
Dynamic: home-page
Dynamic: license-file
Dynamic: maintainer
Dynamic: maintainer-email
Dynamic: requires-python

# Learning with Subset Stacking (LESS)

LESS is a supervised learning algorithm that is based on training many local estimators on subsets of a given dataset, and then passing their predictions to a global estimator. You can find the details about LESS in our [manuscript](https://arxiv.org/abs/2112.06251).

![LESS](./docs/source/_static/LESS1Level.png)

## Installation
Install `LESS` from PyPI:
```bash
pip install less-learn
```

## Getting Started

Below is a simplified example of how to use `LESS`


```python
from sklearn.datasets import make_regression
from sklearn.model_selection import train_test_split
from sklearn.metrics import mean_squared_error
from less import LESSBRegressor

# Generate a synthetic regression dataset
X, y = make_regression(n_samples=1000, n_features=20, random_state=42)

# Split into training and testing sets
X_train, X_test, y_train, y_test = train_test_split(
    X, y, test_size=0.3, random_state=42
)

# Initialize and train the LESS model
less_model = LESSBRegressor(random_state=42)
less_model.fit(X_train, y_train)

# Make predictions and evaluate performance
y_pred = less_model.predict(X_test)
mse = mean_squared_error(y_test, y_pred)
print(f"Test MSE of LESS: {mse:.2f}")
```


> **Note:**
> LESS employs Euclidean distances combined with a radial basis function (RBF) kernel by default.
> It is therefore *highly recommended* to scale or normalize input features prior to model training to ensure optimal performance.


## Citation
Our software can be cited as:
````
  @misc{LESS,
    author = "Ilker Birbil and Samet Copur",
    title = "LESS: Learning with Subset Stacking",
    year = 2025,
    url = "https://github.com/sibirbil/LESS/"
  }
````
