Sparse

Latest version: v0.15.5

Safety actively analyzes 714875 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 3

0.11.1

-------------------

* Fix [`ValueError`][] on [`sparse.dot`][] with extremely small values. (Issue [398](https://github.com/pydata/sparse/issues/398), PR [#399](https://github.com/pydata/sparse/pull/399))

0.11.0

-------------------

* Improve the performance of [`sparse.dot`][]. (Issue [331](https://github.com/pydata/sparse/issues/331), PR [#389](https://github.com/pydata/sparse/pull/389), thanks [daletovar](https://github.com/daletovar))
* Added the [`sparse.COO.swapaxes`][] method. (PR [344](https://github.com/pydata/sparse/pull/344), thanks [lueckem](https://github.com/lueckem))
* Added multi-axis 1-D indexing support. (PR [343](https://github.com/pydata/sparse/pull/343), thanks [mikeymezher](https://github.com/mikeymezher))
* Fix `outer` for arrays that weren't one-dimensional. (Issue [346](https://github.com/pydata/sparse/issues/346), PR [#347](https://github.com/pydata/sparse/pull/347))
* Add `casting` kwarg to [`sparse.COO.astype`][]. (Issue [391](https://github.com/pydata/sparse/issues/391), PR [#392](https://github.com/pydata/sparse/pull/392))
* Fix for [`sparse.COO`][] constructor accepting invalid inputs. (Issue [385](https://github.com/pydata/sparse/issues/385), PR [#386](https://github.com/pydata/sparse/pull/386))

0.10.0

-------------------

* Fixed a bug where converting an empty DOK array to COO leads
to an incorrect dtype. (Issue [314](https://github.com/pydata/sparse/issues/314), PR [#315](https://github.com/pydata/sparse/pull/315))
* Change code formatter to black. (PR [284](https://github.com/pydata/sparse/pull/284))
* Add [`sparse.COO.flatten`] and `outer`. (Issue [316](https://github.com/pydata/sparse/issues/316), PR [#317](https://github.com/pydata/sparse/pull/317)).
* Remove broadcasting restriction between sparse arrays and dense arrays.
(Issue [306](https://github.com/pydata/sparse/issues/306), PR [#318](https://github.com/pydata/sparse/pull/318))
* Implement deterministic dask tokenization. (Issue [300](https://github.com/pydata/sparse/issues/300), PR [#320](https://github.com/pydata/sparse/pull/320), thanks
[danielballan](https://github.com/danielballan))
* Improve testing around densification (PR [321](https://github.com/pydata/sparse/pull/321), thanks
[danielballan](https://github.com/danielballan))
* Simplify Numba extension. (PR [324](https://github.com/pydata/sparse/pull/324), thanks [eric-wieser](https://github.com/eric-wieser)).
* Respect ``copy=False`` in ``astype`` (PR [328](https://github.com/pydata/sparse/pull/328), thanks [eric-wieser](https://github.com/eric-wieser)).
* Replace linear_loc with ravel_multi_index, which is 3x faster. (PR [330](https://github.com/pydata/sparse/pull/330),
thanks [eric-wieser](https://github.com/eric-wieser)).
* Add error msg to tensordot operation when ``ndim==0`` (Issue [332](https://github.com/pydata/sparse/issues/332),
PR [333](https://github.com/pydata/sparse/pull/333), thanks [guilhermeleobas](https://github.com/guilhermeleobas)).
* Maintainence fixes for Sphinx 3.0 and Numba 0.49, and dropping support for
Python 3.5. (PR [337](https://github.com/pydata/sparse/pull/337)).
* Fixed signature for [numpy.clip][].

0.9.1

------------------

* Fixed a bug where indexing with an empty list could lead
to issues. (Issue [281](https://github.com/pydata/sparse/issues/281), PR [#282](https://github.com/pydata/sparse/pull/282))
* Change code formatter to black. (PR [284](https://github.com/pydata/sparse/pull/284))
* Add the [`sparse.diagonal`][] and [`sparse.diagonalize`][] functions.
(Issue [288](https://github.com/pydata/sparse/issues/288), PR [#289](https://github.com/pydata/sparse/pull/289), thanks [pettni](https://github.com/pettni))
* Add HTML repr for notebooks. (PR [283](https://github.com/pydata/sparse/pull/283), thanks [daletovar](https://github.com/daletovar))
* Avoid making copy of ``coords`` when making a new [`sparse.COO`][]
array.
* Add stack and concatenate for GCXS. (Issue [301](https://github.com/pydata/sparse/issues/301), PR [#303](https://github.com/pydata/sparse/pull/303), thanks
[daletovar](https://github.com/daletovar)).
* Fix issue where functions dispatching to an attribute access wouldn't
work with ``__array_function__``. (Issue [308](https://github.com/pydata/sparse/issues/308), PR [#309](https://github.com/pydata/sparse/pull/309)).
* Add partial support for constructing and mirroring [`sparse.COO`][] objects to
Numba.

0.8.0

------------------

This release switches to Numba's new typed lists, a lot of
back-end work with the CI infrastructure, so Linux, macOS
and Windows are officially tested. It also includes bug fixes.

It also adds in-progress, not yet public support for the GCXS
format, which is a generalisation of CSR/CSC. (huge thanks to
[daletovar](https://github.com/daletovar))

* Fixed a bug where an array with size == 1 and nnz == 0
could not be broadcast. (Issue [242](https://github.com/pydata/sparse/issues/242), PR [#243](https://github.com/pydata/sparse/pull/243))
* Add ``std`` and ``var``. (PR [244](https://github.com/pydata/sparse/pull/244))
* Move to Azure Pipelines with CI for Windows, macOS and
Linux. (PR [245](https://github.com/pydata/sparse/pull/245), PR [#246](https://github.com/pydata/sparse/pull/246), PR [#247](https://github.com/pydata/sparse/pull/247), PR [#248](https://github.com/pydata/sparse/pull/248))
* Add ``resize``, and change ``reshape`` so it raises a
``ValueError`` on shapes that don't correspond to the
same size. (Issue [241](https://github.com/pydata/sparse/issues/241), Issue [#250](https://github.com/pydata/sparse/issues/250), PR [#256](https://github.com/pydata/sparse/pull/256)
thanks, [daletovar](https://github.com/daletovar))
* Add ``isposinf`` and ``isneginf``. (Issue [252](https://github.com/pydata/sparse/issues/252), PR [#253](https://github.com/pydata/sparse/pull/253))
* Fix ``tensordot`` when nnz = 0. (Issue [255](https://github.com/pydata/sparse/issues/255), PR [#256](https://github.com/pydata/sparse/pull/256))
* Modifications to ``__array_function__`` to allow for sparse
XArrays. (PR [261](https://github.com/pydata/sparse/pull/261), thanks [nvictus](https://github.com/nvictus))
* Add not-yet-public support for GCXS. (PR [258](https://github.com/pydata/sparse/pull/258), thanks [daletovar](https://github.com/daletovar))
* Improvements to ``__array_function__``. (PR [267](https://github.com/pydata/sparse/pull/267), PR [#272](https://github.com/pydata/sparse/pull/272), thanks
[crusaderky](https://github.com/crusaderky))
* Convert all Numba lists to typed lists. (PR [264](https://github.com/pydata/sparse/pull/264))
* Why write code when it exists elsewhere? (PR [277](https://github.com/pydata/sparse/pull/277))
* Fix some element-wise operations with scalars. (PR [278](https://github.com/pydata/sparse/pull/278))
* Private modules should be private, and tests should be in the package.
(PR [280](https://github.com/pydata/sparse/pull/280))

0.7.0

------------------

This is a release that adds compatibility with NumPy's new
``__array_function__`` protocol, for details refer to
`NEP-18 <http://www.numpy.org/neps/nep-0018-array-function-protocol.html#coercion-to-a-numpy-array-as-a-catch-all-fallback>`_.

The other big change is that we dropped compatibility with
Python 2. Users on Python 2 should use version 0.6.0.

There are also some bug-fixes relating to fill-values.

This was mainly a contributor-driven release.

The full list of changes can be found below:

* Fixed a bug where going between [`sparse.DOK`][] and
[`sparse.COO`][] caused fill-values to be lost.
(Issue [225](https://github.com/pydata/sparse/issues/225), PR [#226](https://github.com/pydata/sparse/pull/226)).
* Fixed warning for a matrix that was incorrectly considered
too dense. (Issue [228](https://github.com/pydata/sparse/issues/228), PR [#229](https://github.com/pydata/sparse/pull/229))
* Fixed some warnings in Python 3.7, the fix was needed.
in preparation for Python 3.8. (PR [233](https://github.com/pydata/sparse/pull/233), thanks [nils-werner](https://github.com/nils-werner))
* Drop support for Python 2.7 (Issue [234](https://github.com/pydata/sparse/issues/234), PR [#235](https://github.com/pydata/sparse/pull/235), thanks
[hugovk](https://github.com/hugovk))
* Clearer error messages (Issue [230](https://github.com/pydata/sparse/issues/230), Issue [#231](https://github.com/pydata/sparse/issues/231), PR [#232](https://github.com/pydata/sparse/pull/232))
* Restructure requirements.txt files. (PR [236](https://github.com/pydata/sparse/pull/236))
* Support fill-value in reductions in specific cases. (Issue [237](https://github.com/pydata/sparse/issues/237), PR [#238](https://github.com/pydata/sparse/pull/238))
* Add ``__array_function__`` support. (PR [239](https://github.com/pydata/sparse/pull/239), thanks, [pentschev](https://github.com/pentschev))
* Cleaner code! (PR [240](https://github.com/pydata/sparse/pull/240))

Page 2 of 3

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.