v1.4.0
This release includes some significant modernisation and maintenance,
as well as new features and performance enhancements.
-
Requirements
-
Python 3.8, 3.9 is no longer supported
-
Python 3.12 is supported
-
importlib_resources backport is no longer required
-
toolz <https://toolz.readthedocs.io/en/latest/index.html>
_ is
a new requirement -
Some other dependency requirements have been increased in order
to simplify maintenance and testing:-
Minimum version of numpy increased from 1.19.3 to 1.24.0
-
Minimum version of matplotlib increased from 3.2 to 3.8
-
Minimum version of Pint increased from 0.19 to 0.22
-
Minimum version of PyYAML increased from 3.13 to 6.0
-
Minimum version of h5py increaased from 2.10 to 3.6
-
Minimum version of threadpoolctl increased from 1.0 to 3.0.
-
-
-
Improvements
-
A "reciprocal_spectroscopy" Pint context is made available in the
unit registry for tricky conversions between reciprocal
frequency/energy units. It is not active by default but can be
enabled with e.g.(10 * ureg("1 / meV")).to("cm", "reciprocal_spectroscopy")
This can also help to avoid divide-by-zero issues when performing
energy <-> wavenumber conversions. -
A Spectrum2DCollection class has been added to euphonic.spectra,
which shares many features with Spectrum1DCollection- In particular, the
iter_metadata
method is recommended when
one needs to iterate over the collection metadata without
copying the spectral data to new objects.
- In particular, the
-
Both Spectrum1DCollection and Spectrum2DCollection have a
.from_spectra()
constructor with an "unsafe" option which
bypasses some consistency checks on the component data. This
should only be used when confident that these will be consistent,
such as when iterating over an existing collection. -
Performance optimisations have been made to the "item getter" for
Spectrum1DCollection (and Spectrum2DCollection); it should now be
significantly faster to access and iterate over the contained
spectra. -
A
euphonic.writers.phonon_website
module has been added with a
function to export QpointPhononModes to appropriate JSON for use
with the phonon visualisation website
http://henriquemiranda.github.io/phononwebsite/From the command-line, this can be accessed with a
--save-web-json
argument to theeuphonic-dispersion
tool.
-
-
Bug fixes
-
Metadata strings from Castep-imported PDOS data are now converted
from numpy strings to native Python strings. -
Spectra from CASTEP .phonon_dos files are now imported with units
of reciprocal energy (e.g. 1/meV)
-
-
Maintenance
-
Cleared up unit-conversion-related warnings, de-cluttering the
expected test suite output. -
The Spectrum1DCollection class was significantly refactored to
support addition of Spectrum2DCollection and improve
maintainability. -
Entire build system rework, migrating to
pyproject.toml
form
withmeson-python
,cibuildwheel
and removing
versioneer
to simplify future development and maintenance.
-