Hyperspy

Latest version: v2.1.0

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

Scan your dependencies

Page 3 of 8

1.6.3

===================

Bug Fixes
---------

- Fix ROI snapping regression (`2720 <https://github.com/hyperspy/hyperspy/issues/2720>`_)
- Fix :py:meth:`~.api.signals.Signal1D.shift1D`, :py:meth:`~.api.signals.Signal1D.align1D` and ``hyperspy._signals.eels.EELSSpectrum.align_zero_loss_peak`` regression with navigation dimension larger than one (`2729 <https://github.com/hyperspy/hyperspy/issues/2729>`_)
- Fix disconnecting events when closing figure and :py:meth:`~.api.signals.Signal1D.remove_background` is active (`2734 <https://github.com/hyperspy/hyperspy/issues/2734>`_)
- Fix :py:meth:`~.api.signals.BaseSignal.map` regression of lazy signal with navigation chunks of size of 1 (`2748 <https://github.com/hyperspy/hyperspy/issues/2748>`_)
- Fix unclear error message when reading a hspy file saved using blosc compression and ``hdf5plugin`` hasn't been imported previously (`2760 <https://github.com/hyperspy/hyperspy/issues/2760>`_)
- Fix saving ``navigator`` of lazy signal (`2763 <https://github.com/hyperspy/hyperspy/issues/2763>`_)


Enhancements
------------

- Use ``importlib_metadata`` instead of ``pkg_resources`` for extensions
registration to speed up the import process and making it possible to install
extensions and use them without restarting the python session (`2709 <https://github.com/hyperspy/hyperspy/issues/2709>`_)
- Don't import hyperspy extensions when registering extensions (`2711 <https://github.com/hyperspy/hyperspy/issues/2711>`_)
- Improve docstrings of various fitting methods (`2724 <https://github.com/hyperspy/hyperspy/issues/2724>`_)
- Improve speed of :py:meth:`~.api.signals.Signal1D.shift1D` (`2750 <https://github.com/hyperspy/hyperspy/issues/2750>`_)
- Add support for recent EMPAD file; scanning size wasn't parsed. (`2757 <https://github.com/hyperspy/hyperspy/issues/2757>`_)


Maintenance
-----------

- Add drone CI to test arm64 platform (`2713 <https://github.com/hyperspy/hyperspy/issues/2713>`_)
- Fix latex doc build on github actions (`2714 <https://github.com/hyperspy/hyperspy/issues/2714>`_)
- Use towncrier to generate changelog automatically (`2717 <https://github.com/hyperspy/hyperspy/issues/2717>`_)
- Fix test suite to support dask 2021.4.1 (`2722 <https://github.com/hyperspy/hyperspy/issues/2722>`_)
- Generate changelog when building doc to keep the changelog of the development doc up to date on https://hyperspy.readthedocs.io/en/latest (`#2758 <https://github.com/hyperspy/hyperspy/issues/2758>`_)
- Use mamba and conda-forge channel on azure pipeline (`2759 <https://github.com/hyperspy/hyperspy/issues/2759>`_)


.. _changes_1.6.2:

1.6.2

===================

This is a maintenance release that adds support for python 3.9 and includes
numerous bug fixes and enhancements.
See `the issue tracker
<https://github.com/hyperspy/hyperspy/milestone/42?closed=1>`__
for details.

Bug Fixes
---------

* Fix disconnect event when closing navigator only plot (fixes `996 <https://github.com/hyperspy/hyperspy/issues/996>`_), (`#2631 <https://github.com/hyperspy/hyperspy/pull/2631>`_)
* Fix incorrect chunksize when saving EMD NCEM file and specifying chunks (`2629 <https://github.com/hyperspy/hyperspy/pull/2629>`_)
* Fix :py:meth:`~.api.signals.Signal2D.find_peaks` GUIs call with laplacian/difference of gaussian methods (`2622 <https://github.com/hyperspy/hyperspy/issues/2622>`_ and `#2647 <https://github.com/hyperspy/hyperspy/pull/2647>`_)
* Fix various bugs with ``CircleWidget`` and ``Line2DWidget`` (`2625 <https://github.com/hyperspy/hyperspy/pull/2625>`_)
* Fix setting signal range of model with negative axis scales (`2656 <https://github.com/hyperspy/hyperspy/pull/2656>`_)
* Fix and improve mask handling in lazy decomposition; Close `2605 <https://github.com/hyperspy/hyperspy/issues/2605>`_ (`#2657 <https://github.com/hyperspy/hyperspy/pull/2657>`_)
* Plot scalebar when the axis scales have different sign, fixes `2557 <https://github.com/hyperspy/hyperspy/issues/2557>`_ (`#2657 <https://github.com/hyperspy/hyperspy/pull/2657>`_)
* Fix :py:meth:`~.api.signals.Signal1D.align1D` returning zeros shifts (`2675 <https://github.com/hyperspy/hyperspy/pull/2675>`_)
* Fix finding dataset path for EMD NCEM file containing more than one dataset in a group (`2673 <https://github.com/hyperspy/hyperspy/pull/2673>`_)
* Fix squeeze function for multiple zero-dimensional entries, improved docstring, added to user guide. (`2676 <https://github.com/hyperspy/hyperspy/pull/2676>`_)
* Fix error in Cliff-Lorimer quantification using absorption correction (`2681 <https://github.com/hyperspy/hyperspy/pull/2681>`_)
* Fix ``navigation_mask`` bug in decomposition when provided as numpy array (`2679 <https://github.com/hyperspy/hyperspy/pull/2679>`_)
* Fix closing image contrast tool and setting vmin/vmax values (`2684 <https://github.com/hyperspy/hyperspy/pull/2684>`_)
* Fix range widget with matplotlib 3.4 (`2684 <https://github.com/hyperspy/hyperspy/pull/2684>`_)
* Fix bug in :py:func:`~.api.interactive` with function returning `None`. Improve user guide example. (`2686 <https://github.com/hyperspy/hyperspy/pull/2686>`_)
* Fix broken events when changing signal type `2683 <https://github.com/hyperspy/hyperspy/pull/2683>`_
* Fix setting offset in rebin: the offset was changed in the wrong axis (`2690 <https://github.com/hyperspy/hyperspy/pull/2690>`_)
* Fix reading XRF bruker file, close `2689 <https://github.com/hyperspy/hyperspy/issues/2689>`_ (`#2694 <https://github.com/hyperspy/hyperspy/pull/2694>`_)


Enhancements
------------

* Widgets plotting improvement and add ``pick_tolerance`` to plot preferences (`2615 <https://github.com/hyperspy/hyperspy/pull/2615>`_)
* Pass keyword argument to the image IO plugins (`2627 <https://github.com/hyperspy/hyperspy/pull/2627>`_)
* Improve error message when file not found (`2597 <https://github.com/hyperspy/hyperspy/pull/2597>`_)
* Add update instructions to user guide (`2621 <https://github.com/hyperspy/hyperspy/pull/2621>`_)
* Improve plotting navigator of lazy signals, add ``navigator`` setter to lazy signals (`2631 <https://github.com/hyperspy/hyperspy/pull/2631>`_)
* Use ``'dask_auto'`` when rechunk=True in :py:meth:`~._signals.lazy.LazySignal.change_dtype` for lazy signal (`2645 <https://github.com/hyperspy/hyperspy/pull/2645>`_)
* Use dask chunking when saving lazy signal instead of rechunking and leave the user to decide what is the suitable chunking (`2629 <https://github.com/hyperspy/hyperspy/pull/2629>`_)
* Added lazy reading support for FFT and DPC datasets in FEI emd datasets (`2651 <https://github.com/hyperspy/hyperspy/pull/2651>`_).
* Improve error message when initialising SpanROI with left >= right (`2604 <https://github.com/hyperspy/hyperspy/pull/2604>`_)
* Allow running the test suite without the pytest-mpl plugin (`2624 <https://github.com/hyperspy/hyperspy/pull/2624>`_)
* Add Releasing guide (`2595 <https://github.com/hyperspy/hyperspy/pull/2595>`_)
* Add support for python 3.9, fix deprecation warning with matplotlib 3.4.0 and bump minimum requirement to numpy 1.17.1 and dask 2.1.0. (`2663 <https://github.com/hyperspy/hyperspy/pull/2663>`_)
* Use native endianess in numba jitted functions. (`2678 <https://github.com/hyperspy/hyperspy/pull/2678>`_)
* Add option not to snap ROI when calling the :py:meth:`~.roi.BaseInteractiveROI.interactive` method of a ROI (`2686 <https://github.com/hyperspy/hyperspy/pull/2686>`_)
* Make :py:class:`~.misc.utils.DictionaryTreeBrowser` lazy by default - see `368 <https://github.com/hyperspy/hyperspy/issues/368>`_ (`#2623 <https://github.com/hyperspy/hyperspy/pull/2623>`_)
* Speed up setting CI on azure pipeline (`2694 <https://github.com/hyperspy/hyperspy/pull/2694>`_)
* Improve performance issue with the map method of lazy signal (`2617 <https://github.com/hyperspy/hyperspy/pull/2617>`_)
* Add option to copy/load original metadata in ``hs.stack`` and ``hs.load`` to avoid large ``original_metadata`` which can slowdown processing. Close `1398 <https://github.com/hyperspy/hyperspy/issues/1398>`_, `#2045 <https://github.com/hyperspy/hyperspy/issues/2045>`_, `#2536 <https://github.com/hyperspy/hyperspy/issues/2536>`_ and `#1568 <https://github.com/hyperspy/hyperspy/issues/1568>`_. (`#2691 <https://github.com/hyperspy/hyperspy/pull/2691>`_)


Maintenance
-----------

* Fix warnings when building documentation (`2596 <https://github.com/hyperspy/hyperspy/pull/2596>`_)
* Drop support for numpy<1.16, in line with NEP 29 and fix protochip reader for numpy 1.20 (`2616 <https://github.com/hyperspy/hyperspy/pull/2616>`_)
* Run test suite against upstream dependencies (numpy, scipy, scikit-learn and scikit-image) (`2616 <https://github.com/hyperspy/hyperspy/pull/2616>`_)
* Update external links in the loading data section of the user guide (`2627 <https://github.com/hyperspy/hyperspy/pull/2627>`_)
* Fix various future and deprecation warnings from numpy and scikit-learn (`2646 <https://github.com/hyperspy/hyperspy/pull/2646>`_)
* Fix ``iterpath`` VisibleDeprecationWarning when using :py:meth:`~.models.model1d.Model1D.fit_component` (`2654 <https://github.com/hyperspy/hyperspy/pull/2654>`_)
* Add integration test suite documentation in the developer guide. (`2663 <https://github.com/hyperspy/hyperspy/pull/2663>`_)
* Fix SkewNormal component compatibility with sympy 1.8 (`2701 <https://github.com/hyperspy/hyperspy/pull/2701>`_)

.. _changes_1.6.1:

1.6.1

===================

This is a maintenance release that adds compatibility with h5py 3.0 and includes
numerous bug fixes and enhancements.
See `the issue tracker
<https://github.com/hyperspy/hyperspy/milestone/41?closed=1>`__
for details.


.. _changes_1.6:

1.6.0

===================

NEW
---

* Support for the following file formats:

* :external+rsciio:ref:`digitalsurf-format`
* :external+rsciio:ref:`elid-format`
* :external+rsciio:ref:`nexus-format`
* :external+rsciio:ref:`usid-format`
* :external+rsciio:ref:`empad-format`
* Prismatic EMD format, see :external+rsciio:ref:`emd-format`
* ``hyperspy._signals.eels.EELSSpectrum.print_edges_near_energy`` method
that, if the `hyperspy-gui-ipywidgets package
<https://github.com/hyperspy/hyperspy_gui_ipywidgets>`_
is installed, includes an
awesome interactive mode. See :external+exspy:ref:`eels_elemental_composition-label`.
* Model asymmetric line shape components:

* :py:class:`~._components.doniach.Doniach`
* :py:class:`~._components.split_voigt.SplitVoigt`
* :external+exspy:ref:`EDS absorption correction <eds_absorption-label>`.
* :ref:`Argand diagram for complex signals <complex.argand>`.
* :ref:`Multiple peak finding algorithms for 2D signals <peak_finding-label>`.
* :ref:`cluster_analysis-label`.

Enhancements
------------

* The :py:meth:`~.api.signals.BaseSignal.get_histogram` now uses numpy's
`np.histogram_bin_edges()
<https://numpy.org/doc/stable/reference/generated/numpy.histogram_bin_edges.html>`_
and supports all of its ``bins`` keyword values.
* Further improvements to the contrast adjustment tool.
Test it by pressing the ``h`` key on any image.
* The following components have been rewritten using
:py:class:`~._components.expression.Expression`, boosting their
speeds among other benefits.

* :py:class:`~._components.arctan.Arctan`
* :py:class:`~._components.voigt.Voigt`
* :py:class:`~._components.heaviside.HeavisideStep`
* The model fitting :py:meth:`~hyperspy.model.BaseModel.fit` and
:py:meth:`~hyperspy.model.BaseModel.multifit` methods have been vastly improved. See
:ref:`model.fitting` and the API changes section below.
* New serpentine iteration path for multi-dimensional fitting.
See :ref:`model.multidimensional-label`.
* The :py:func:`~.api.plot.plot_spectra` function now listens to
events to update the figure automatically.
See :ref:`this example <sphx_glr_auto_examples_region_of_interest_ExtractLineProfile.py>`.
* Improve thread-based parallelism. Add ``max_workers`` argument to the
:py:meth:`~.api.signals.BaseSignal.map` method, such that the user can directly
control how many threads they launch.
* Many improvements to the :py:meth:`~.api.signals.BaseSignal.decomposition` and
:py:meth:`~.api.signals.BaseSignal.blind_source_separation` methods, including support for
scikit-learn like algorithms, better API and much improved documentation.
See :ref:`ml-label` and the API changes section below.
* Add option to calculate the absolute thickness to the EELS
``hyperspy._signals.eels.EELSSpectrum.estimate_thickness`` method.
See :external+exspy:ref:`eels_thickness-label`.
* Vastly improved performance and memory footprint of the
:py:meth:`~.api.signals.Signal2D.estimate_shift2D` method.
* The :py:meth:`~.api.signals.Signal1D.remove_background` method can
now remove Doniach, exponential, Lorentzian, skew normal,
split Voigt and Voigt functions. Furthermore, it can return the background
model that includes an estimation of the reduced chi-squared.
* The performance of the maximum-likelihood PCA method was greatly improved.
* All ROIs now have a ``__getitem__`` method, enabling e.g. using them with the
unpack ``*`` operator. See :ref:`roi-slice-label` for an example.
* New syntax to set the contrast when plotting images. In particular, the
``vmin`` and ``vmax`` keywords now take values like ``vmin="30th"`` to
clip the minimum value to the 30th percentile. See :ref:`signal.fft`
for an example.
* The :py:meth:`~.api.signals.Signal1D.plot` and
:py:meth:`~.api.signals.Signal2D.plot` methods take a new keyword
argument ``autoscale``. See :ref:`plot.customize_images` for details.
* The contrast editor and the decomposition methods can now operate on
complex signals.
* The default colormap can now be set in
:ref:`preferences <configuring-hyperspy-label>`.


API changes
-----------

* The :py:meth:`~.api.signals.Signal2D.plot` keyword argument
``saturated_pixels`` is deprecated. Please use
``vmin`` and/or ``vmax`` instead.
* The :py:func:`~.api.load` keyword argument ``dataset_name`` has been
renamed to ``dataset_path``.
* The :py:meth:`~.api.signals.BaseSignal.set_signal_type` method no longer takes
``None``. Use the empty string ``""`` instead.
* The :py:meth:`~.api.signals.BaseSignal.get_histogram` ``bins`` keyword values
have been renamed as follows for consistency with numpy:

* ``"scotts"`` -> ``"scott"``,
* ``"freedman"`` -> ``"fd"``
* Multiple changes to the syntax of the :py:meth:`~hyperspy.model.BaseModel.fit`
and :py:meth:`~hyperspy.model.BaseModel.multifit` methods:

* The ``fitter`` keyword has been renamed to ``optimizer``.
* The values that the ``optimizer`` keyword take have been renamed
for consistency with scipy:

* ``"fmin"`` -> ``"Nelder-Mead"``,
* ``"fmin_cg"`` -> ``"CG"``,
* ``"fmin_ncg"`` -> ``"Newton-CG"``,
* ``"fmin_bfgs"`` -> ``"BFGS"``,
* ``"fmin_l_bfgs_b"`` -> ``"L-BFGS-B"``,
* ``"fmin_tnc"`` -> ``"TNC"``,
* ``"fmin_powell"`` -> ``"Powell"``,
* ``"mpfit"`` -> ``"lm"`` (in combination with ``"bounded=True"``),
* ``"leastsq"`` -> ``"lm"``,

* Passing integer arguments to ``parallel`` to select the number of
workers is now deprecated. Use ``parallel=True, max_workers={value}``
instead.
* The ``method`` keyword has been renamed to ``loss_function``.
* The ``loss_function`` value ``"ml"`` has been renamed to ``"ML-poisson"``.
* The ``grad`` keyword no longer takes boolean values. It takes the
following values instead: ``"fd"``, ``"analytical"``, callable or ``None``.
* The ``ext_bounding`` keyword has been deprecated and will be removed. Use
``bounded=True`` instead.
* The ``min_function`` keyword argument has been deprecated and will
be removed. Use ``loss_function`` instead.,
* The ``min_function_grad`` keyword arguments has been deprecated and will be
removed. Use ``grad`` instead.
* The ``iterpath`` default will change from ``'flyback'`` to
``'serpentine'`` in HyperSpy version 2.0.

* The following :py:class:`~hyperspy.model.BaseModel` methods are now private:

* ``hyperspy.model.BaseModel.set_boundaries``
* ``hyperspy.model.BaseModel.set_mpfit_parameters_info``

* The ``comp_label`` keyword of the machine learning plotting functions
has been renamed to ``title``.
* The :py:class:`~hyperspy.learn.rpca.orpca` constructor's ``learning_rate``
keyword has been renamed to ``subspace_learning_rate``
* The :py:class:`~hyperspy.learn.rpca.orpca` constructor's ``momentum``
keyword has been renamed to ``subspace_momentum``
* The :py:class:`~hyperspy.learn.svd_pca.svd_pca` constructor's ``centre`` keyword
values have been renamed as follows:

* ``"trials"`` -> ``"navigation"``
* ``"variables"`` -> ``"signal"``
* The ``bounds`` keyword argument of the
:py:meth:`~._signals.lazy.LazySignal.decomposition` is deprecated and will be removed.
* Several syntax changes in the :py:meth:`~.api.signals.BaseSignal.decomposition` method:

* Several ``algorithm`` keyword values have been renamed as follows:

* ``"svd"``: ``"SVD"``,
* ``"fast_svd"``: ``"SVD"``,
* ``"nmf"``: ``"NMF"``,
* ``"fast_mlpca"``: ``"MLPCA"``,
* ``"mlpca"``: ``"MLPCA"``,
* ``"RPCA_GoDec"``: ``"RPCA"``,
* The ``polyfit`` argument has been deprecated and will be removed.
Use ``var_func`` instead.


.. _changes_1.5.2:

1.5.2

===================

This is a maintenance release that adds compatibility with Numpy 1.17 and Dask

1.5.1

===================

This is a maintenance release that fixes some regressions introduced in v1.5.
Follow the following links for details on all the `bugs fixed
<https://github.com/hyperspy/hyperspy/issues?q=label%3A"type%3A+bug"+is%3Aclosed+milestone%3Av1.5.1>`__.


.. _changes_1.5:

Page 3 of 8

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.