Skip to content

Commit 7b3e47d

Browse files
authored
Prepare v0.6.0 (#648)
* Bump version to 0.6.0 * Write v0.6.0 release notes * Fix bug with plot_diagram on empty diagrams
1 parent 7576eb9 commit 7b3e47d

File tree

7 files changed

+60
-6
lines changed

7 files changed

+60
-6
lines changed

CODE_AUTHORS.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Where component authors are known, add them here.
77
| Lewis Tunstall, [email protected]
88
| Matteo Caorsi, [email protected]
99
| Philippe Nguyen, [email protected]
10-
| Julian Burella Pérez, [email protected]
10+
| Julián Burella Pérez, [email protected]
1111
| Alessio Ghiraldello, [email protected]
1212
| Adélie Garin, [email protected]
1313
| Anibal Medina-Mardones, [email protected]

doc/library.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -124,5 +124,5 @@ What's new
124124

125125
.. include::
126126
release.rst
127-
:start-after: Release 0.5.1
128-
:end-before: Release 0.5.0
127+
:start-after: Release 0.6.0
128+
:end-before: Release 0.5.1

doc/release.rst

+35
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,41 @@ Release Notes
44

55
.. _stable:
66

7+
*************
8+
Release 0.6.0
9+
*************
10+
11+
This is a major release including a new local homology subpackage, a new backend for computing Vietoris–Rips barcodes, wheels for Python 3.10 and Apple Silicon systems, and end of support for Python 3.6.
12+
13+
Major Features and Improvements
14+
===============================
15+
16+
- A new ``local_homology`` subpackage containing ``scikit-learn``–compatible transformers for the extraction of local homology features has been added (`#602 <https://github.com/giotto-ai/giotto-tda/pull/602>`_). A `tutorial <https://giotto-ai.github.io/gtda-docs/0.6.0/notebooks/local_homology.html>`_ and an `example <https://giotto-ai.github.io/gtda-docs/0.6.0/notebooks/local_hom_NLP_disambiguation.html>`_ notebooks explain it.
17+
- Wheels for Python 3.10 are now available (`#644 <https://github.com/giotto-ai/giotto-tda/pull/644>`_ and `#646 <https://github.com/giotto-ai/giotto-tda/pull/646>`_).
18+
- Wheels for Apple Silicon systems are now available for Python versions 3.8, 3.9 and 3.10 (`#646 <https://github.com/giotto-ai/giotto-tda/pull/646>`_).
19+
- ``giotto-ph`` is now the backend for the computation of Vietoris–Rips barcodes, replacing ``ripser.py`` (`#614 <https://github.com/giotto-ai/giotto-tda/pull/614>`_).
20+
- The documentation has been improved (`#609 <https://github.com/giotto-ai/giotto-tda/pull/609>`_).
21+
22+
Bug Fixes
23+
=========
24+
25+
- A bug involving tests for the ``mapper`` subpackage has been fixed (`#638 <https://github.com/giotto-ai/giotto-tda/pull/638>`_).
26+
27+
Backwards-Incompatible Changes
28+
==============================
29+
30+
- Python 3.6 is no longer supported, and the manylinux standard has been bumped from ``manylinux2010`` to ``manylinux2014`` (`#644 <https://github.com/giotto-ai/giotto-tda/pull/644>`_ and `#646 <https://github.com/giotto-ai/giotto-tda/pull/646>`_).
31+
- The ``python-igraph`` requirement has been replaced with ``igraph >= 0.9.8`` (`#616 <https://github.com/giotto-ai/giotto-tda/pull/616>`_).
32+
33+
Thanks to our Contributors
34+
==========================
35+
36+
This release contains contributions from:
37+
38+
Umberto Lupo, Jacob Bamberger, Wojciech Reise, Julián Burella Pérez, and Anibal Medina-Mardones
39+
40+
We are also grateful to all who filed issues or helped resolve them, asked and answered questions, and were part of inspiring discussions.
41+
742
*************
843
Release 0.5.1
944
*************

doc/versions

+1
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,5 @@
66
./0.4.0
77
./0.5.0
88
./0.5.1
9+
./0.6.0
910
./latest

gtda/_version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919
# 'X.Y.dev0' is the canonical version of 'X.Y.dev'
2020
#
2121

22-
__version__ = "0.5.1"
22+
__version__ = "0.6.0"

gtda/plotting/persistence_diagrams.py

+7-2
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,13 @@ def plot_diagram(diagram, homology_dimensions=None, plotly_params=None):
4040
diagram_no_dims = diagram[:, :2]
4141
posinfinite_mask = np.isposinf(diagram_no_dims)
4242
neginfinite_mask = np.isneginf(diagram_no_dims)
43-
max_val = np.max(np.where(posinfinite_mask, -np.inf, diagram_no_dims))
44-
min_val = np.min(np.where(neginfinite_mask, np.inf, diagram_no_dims))
43+
if diagram_no_dims.size:
44+
max_val = np.max(np.where(posinfinite_mask, -np.inf, diagram_no_dims))
45+
min_val = np.min(np.where(neginfinite_mask, np.inf, diagram_no_dims))
46+
else:
47+
# Dummy values if diagram is empty
48+
max_val = 1
49+
min_val = 0
4550
parameter_range = max_val - min_val
4651
extra_space_factor = 0.02
4752
has_posinfinite_death = np.any(posinfinite_mask[:, 1])
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
"""Testing for plot_diagram."""
2+
# License: GNU AGPLv3
3+
4+
import numpy as np
5+
6+
from gtda.plotting import plot_diagram
7+
8+
9+
def test_plot_diagram_empty():
10+
"""Test that plot_diagram does not crash on a diagram with no non-trivial
11+
points."""
12+
plot_diagram(np.array([[0., 0., 0.],
13+
[0., 0., 1.]]))

0 commit comments

Comments
 (0)