Skip to main content

fastSparse

Introduction

fastSparseGAMs is a Python package that offers an efficient framework for solving L0-regularized learning problems in sparse generalized additive models (GAMs). Leveraging the L0Learn package, this package introduces two novel algorithms, namely quadratic cuts and dynamic feature ordering, to deliver faster computational speed. Additionally, it comes with a new loss function (exponential loss) for classification.

Package Installation

The latest version can be installed from pip as follows:

pip install fastsparsegams

Documentation

An example on how to use fastSparseGAMs is provided at this tutorial page.

fastSparseGAMs is developed upon the framework of L0Learn, featuring faster and novel algorithms implemented internally. We do not alter the external Python interface functions. Therefore, please see L0Learn's python documentation available here for the detailed API documentation. The external function usage is almost idential to L0Learn's API except replacing the module name l0learn with fastsparsegams.

Source Code and Installing from Source

Alternatively, fastSparseGAMs can be build from source

git clone --recurse-submodules https://github.com/tynanseltzer/L0Learn.git
cd python

To install, ensure the proper packages are installed from pyproject.toml build from source with the following:

pip install ".[test]"

To test, run the following command:

python -m pytest

Citing fastSparseGAMs

If you find fastSparseGAMs useful in your research, please consider citing the following papers.

Paper 1:

@inproceedings{liu2022fast,
  title={Fast Sparse Classification for Generalized Linear and Additive Models},
  author={Liu, Jiachang and Zhong, Chudi and Seltzer, Margo and Rudin, Cynthia},
  booktitle={International Conference on Artificial Intelligence and Statistics},
  pages={9304--9333},
  year={2022},
  organization={PMLR}
}

Paper 2:

@article{doi:10.1287/opre.2019.1919,
author = {Hazimeh, Hussein and Mazumder, Rahul},
title = {Fast Best Subset Selection: Coordinate Descent and Local Combinatorial Optimization Algorithms},
journal = {Operations Research},
volume = {68},
number = {5},
pages = {1517-1537},
year = {2020},
doi = {10.1287/opre.2019.1919},
URL = {https://doi.org/10.1287/opre.2019.1919},
eprint = {https://doi.org/10.1287/opre.2019.1919}
}

Paper 3:

@article{JMLR:v22:19-1049,
  author  = {Antoine Dedieu and Hussein Hazimeh and Rahul Mazumder},
  title   = {Learning Sparse Classifiers: Continuous and Mixed Integer Optimization Perspectives},
  journal = {Journal of Machine Learning Research},
  year    = {2021},
  volume  = {22},
  number  = {135},
  pages   = {1-47},
  url     = {http://jmlr.org/papers/v22/19-1049.html}
}

Paper 4:

@article{hazimeh2022l0learn,
      title={L0Learn: A Scalable Package for Sparse Learning using L0 Regularization},
      author={Hussein Hazimeh and Rahul Mazumder and Tim Nonet},
      year={2022},
      eprint={2202.04820},
      archivePrefix={arXiv},
      primaryClass={cs.LG}
}

Metadata

Release files for fastsparsegams 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for fastsparsegams 0.2.0
File
fastsparsegams-0.2.0-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
fastsparsegams-0.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details
fastsparsegams-0.2.0-cp312-cp312-macosx_11_0_arm64.whl CPython 3.12 CPython 3.12 macOS 11.0+ ARM64 Details
fastsparsegams-0.2.0-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
fastsparsegams-0.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
fastsparsegams-0.2.0-cp311-cp311-macosx_11_0_arm64.whl CPython 3.11 CPython 3.11 macOS 11.0+ ARM64 Details
fastsparsegams-0.2.0-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
fastsparsegams-0.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
fastsparsegams-0.2.0-cp310-cp310-macosx_11_0_arm64.whl CPython 3.10 CPython 3.10 macOS 11.0+ ARM64 Details
fastsparsegams-0.2.0-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
fastsparsegams-0.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details
fastsparsegams-0.2.0-cp39-cp39-macosx_11_0_arm64.whl CPython 3.9 CPython 3.9 macOS 11.0+ ARM64 Details
fastsparsegams-0.2.0-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details
fastsparsegams-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.17+ x86-64 Details
fastsparsegams-0.2.0-cp38-cp38-macosx_11_0_arm64.whl CPython 3.8 CPython 3.8 macOS 11.0+ ARM64 Details

Total release size: 89.6 MB

Release files / fastsparsegams-0.2.0-cp312-cp312-win_amd64.whl

Download URL fastsparsegams-0.2.0-cp312-cp312-win_amd64.whl
Size 1.5 MB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
85b1ceb695b9bfb57a2b1d7ac9e8573bf9a2eaea33c050e30c7114f368b8549b
BLAKE2b-256 checksum
How to use checksums
8c68141098ccc59826f417e2e0002084e7146c77d431eb464326bf615cbc0053
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL fastsparsegams-0.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.9 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
c6f9ea724acc2de8bf6f8a4f2fe900ca31e8e0af4d40d73cd9bbbd1705c803da
BLAKE2b-256 checksum
How to use checksums
9fd5275419765b26670e4635fffc1957e2371eb40a220a899ac910ec0fbae654
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp312-cp312-macosx_11_0_arm64.whl

Download URL fastsparsegams-0.2.0-cp312-cp312-macosx_11_0_arm64.whl
Size 1.5 MB
Tags CPython 3.12 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
af7206a5b05fbe751076fc174c8f09ffafb0a78fad566fa9e9edcd9773f2e087
BLAKE2b-256 checksum
How to use checksums
a9b5fa5e1266cb3e554553f5c66d64e659b799190eba3806e4405cd6103ed81e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp311-cp311-win_amd64.whl

Download URL fastsparsegams-0.2.0-cp311-cp311-win_amd64.whl
Size 1.5 MB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
c830be2612ddef1288616af6177265055e331eb0b2efb473badb41a6b7741a94
BLAKE2b-256 checksum
How to use checksums
b20ce3b1c350a07ceaba55a0e020f7a2364e620df66abe77aef4b9fc7054618f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL fastsparsegams-0.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.9 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
44842b27ba6f205002e71deb69b69b35bd1ece7ca25602ab031de21f5d0058a1
BLAKE2b-256 checksum
How to use checksums
15d01a1086e377efd944a62f11d5aee9e74723ee892397bdd95da28c0ba9716b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp311-cp311-macosx_11_0_arm64.whl

Download URL fastsparsegams-0.2.0-cp311-cp311-macosx_11_0_arm64.whl
Size 1.5 MB
Tags CPython 3.11 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
89e1225de1a4c573f8da62b1c6064c19088fbad92ec2fdfecb94f10538062a36
BLAKE2b-256 checksum
How to use checksums
d84dae700f2707cdeabdb7a20b54cf3b8fff4b2b1528c65e8ac44272c3bf4f50
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp310-cp310-win_amd64.whl

Download URL fastsparsegams-0.2.0-cp310-cp310-win_amd64.whl
Size 1.5 MB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
bea864d86a3b268b7efce3908dd2c34f53c7d4e085d4785f4b9a8f60342c2544
BLAKE2b-256 checksum
How to use checksums
e6194290798767e37c7fd54c3c4ac4a3038486477089d497b307ed55f267a3f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL fastsparsegams-0.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.9 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
1f4cc1db2babd14e9682bc791f8e099cbc125e3e43b8c7d93283fbd111d07da3
BLAKE2b-256 checksum
How to use checksums
3efa78a236de85dc3a329cf724b3e9a858e95bd9c2a42c15020d04f272e5070b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp310-cp310-macosx_11_0_arm64.whl

Download URL fastsparsegams-0.2.0-cp310-cp310-macosx_11_0_arm64.whl
Size 1.5 MB
Tags CPython 3.10 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
c73d64b876a2c45492f41f0d9f03741248298b236a36a13d2c8f43c812822e3f
BLAKE2b-256 checksum
How to use checksums
e472f141ec00290195e3bdf926a9c74d333a83580f4ae5635593cd06272e1b43
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp39-cp39-win_amd64.whl

Download URL fastsparsegams-0.2.0-cp39-cp39-win_amd64.whl
Size 1.5 MB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
e671d51c4d52a6ad3c707eefb6d9aa1338edad1a3e6081a65ded13c718cec4b5
BLAKE2b-256 checksum
How to use checksums
54246e7dde7744d85c0bea763e723a9e6b5937bb456d91ee31f013f3eb8bd765
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL fastsparsegams-0.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.9 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
ed2e53586efbbdeb8fdcbb013e6cc8180bccb3a3eaa37a11492203da0af79c5a
BLAKE2b-256 checksum
How to use checksums
e20b1bb4737ff6caac90c5dcf248c82ccef57fe8dd5ced18a66e69288a48332f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp39-cp39-macosx_11_0_arm64.whl

Download URL fastsparsegams-0.2.0-cp39-cp39-macosx_11_0_arm64.whl
Size 1.5 MB
Tags CPython 3.9 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
08cf1abc6ec82b1879debfdcddfce3cd6474286fc53ec0f7b5fdecca2084e745
BLAKE2b-256 checksum
How to use checksums
c6fa67fa914acd03d8d518a056749fed2ff8ba7c9d3b4f782700e311bfb36697
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp38-cp38-win_amd64.whl

Download URL fastsparsegams-0.2.0-cp38-cp38-win_amd64.whl
Size 1.5 MB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
738dae75060f29faa69d64472b4ae0ec4aa40e8fe4c1c3d28e0cb196ad002ba2
BLAKE2b-256 checksum
How to use checksums
22523c97cead03c1068b8a7c5f73d27a2dfaf4024c13c4e479220b9303341e67
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL fastsparsegams-0.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 14.9 MB
Tags CPython 3.8 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
dbc8a69c9a986aa18c971c2df002e75cb81abfdef7c7a99b4db3aba0bd85b508
BLAKE2b-256 checksum
How to use checksums
727efb2f42ce2943b565aea728f6289db1e5c53492ef220754a72ba9d5d7fba5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / fastsparsegams-0.2.0-cp38-cp38-macosx_11_0_arm64.whl

Download URL fastsparsegams-0.2.0-cp38-cp38-macosx_11_0_arm64.whl
Size 1.5 MB
Tags CPython 3.8 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
b562a42c586c2903f51ddd756548c65732896e32498bd909fed835245b2d4b7a
BLAKE2b-256 checksum
How to use checksums
34fe739506570d48105cb5c95fd1712797be88e40d08cff9225be3cb31f904a9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release history Release notifications | RSS feed

This release

0.2.0 This release

15 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page