Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changelog and version number updates #499

Merged
merged 14 commits into from
Dec 19, 2024
64 changes: 61 additions & 3 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,71 @@ and this project adheres to
.. ^^^^^^^^^^^


[v2.3.0-b] - 2024-12-06
~~~~~~~~~~~~~~~~~~~~~~~~~
[v2.3.0] - 2024-12-17
~~~~~~~~~~~~~~~~~~~~~

Summary
^^^^^^^

* Updates done during the 2024 hack week. Including making X-PSI Cython3 compatible.
* This release includes updates done during the hack week in December 2024, for example, making X-PSI Cython3 compatible, UltraNest sampling examples, Simulation-Based Inference examples, reading data and instrument files that are in fits-format, and removing deprecated features.

Fixed
^^^^^

* Fixed Python3.12 related syntax warnings when installing X-PSI were fixed by adding 'r' in front of strings that contain a back slash.

* Default value for ``image_order_limit`` in the module generator was set to match what is said in the docstring (i.e. the default being ``None``).

Added
^^^^^

* Added UltraNest as an example to the modelling tutorial and installation instructions.

* Added some docstrings to ``mesh_tools.pyx`` and ``effective_gravity_universal.pyx``.

* Added new optional plots for clustering of residuals.

* Added the possibility to print a user-defined credible level.

* Data (event list or spectrum) and responses (RMF, ARF, RSP) can now be loaded from FITS file.

* Added Simulation-Based Inference examples in the documentation, and wrapper class in the utilities.

* Added a new option ``star_shape`` for the Spacetime class to allow pulse calculation and inference with a spherical star (instead of an oblate spheroid).

* Added background, convergence, and "P-P" plots in the Post-processing tutorial.

* Multi-mode plotting was made possible in the corner plots (different modes from a MultiNest run done with ``multimodal=True`` can be now plotted separately).

* Added bolometric pulse and blurring of the residuals options in ``xpsi/PostProcessing/_residual.py``.\

* Added a possibility to use a parameter vector instead of random set of samples in all post-processing functions.

* Added a chi-squared calculation property to the Signal class.

Changed
^^^^^^^

* X-PSI was upgraded to support Cython3 by updating the syntax and the structure of all the Cython files. Installation instructions were also updated. Using Cython3 is now recommended, but the code still also works with Cython version 0.29.

* Residual plotting was updated to fix issues when using logarithmic scale and including channel 0.

* Updated the installation instructions for Helios and the example job script.

* The desired precision of credible intervals can now be defined already when loading the runs.

* The Photosphere class atmosphere setter can now load by default atmosphere table files similar those of NSX model used in NICER analyses (without need for writing a CustomPhotosphere for this).

* Future plans, publications, etc. were updated in the documentation.

Removed
^^^^^^^

* X-PSI Python 2 documentation (v1.x and earlier) was retired from the main online documentation (but can still be accessed via the GitHub).

* Removed the deprecated ``is_secondary`` argument from the HotRegion class. **Note that setting ``is_secondary=True`` has now no effect, and will lead to wrong likelihood values if not replacing it with is_antiphased=True**.

* Removed the ``TwoHotRegions`` class that nobody was known to be using.

Attribution
^^^^^^^^^^^
Expand Down
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
# The short X.Y version.
version = '2.3-b'
# The full version, including alpha/beta/rc tags.
release = '2.3.0-b'
release = '2.3.0'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ def EXTENSION(modname):

setup(
name = 'xpsi',
version = '2.3.0-b',
version = '2.3.0',
author = 'The X-PSI Core Team',
author_email = 'A.L.Watts@uva.nl',
url = 'https://github.com/xpsi-group/xpsi',
Expand Down
2 changes: 1 addition & 1 deletion xpsi/PostProcessing/_residual.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ def add_pulses( self ):
double_pulse_model = _np.concatenate( (pulse_model , pulse_model) )

# Compute the chi squared
chi2 = self._signal.chi2
chi2 = _np.sum( (pulse_data - pulse_model)**2 / pulse_model )

# Plot pulse
self._ax_pulse.errorbar(x=doubles_phases,
Expand Down
9 changes: 2 additions & 7 deletions xpsi/Signal.py
Original file line number Diff line number Diff line change
Expand Up @@ -747,13 +747,8 @@ def synthesise(self, phase_shifts, directory, **kwargs):
raise NotImplementedError('Cannot synthesise data.')

@property
def chi2( self ):
""" Return the chi2 value for the current likelihood value or a given parameter vector if required.

:param list p:
Parameter vector, optional.

"""
def bolometric_chi2( self ):
""" Return the bolometric chi2 value for the current likelihood value. """

# Get the pulse of data and model
pulse_data = self.data.counts.sum( axis = 0 )
Expand Down
2 changes: 1 addition & 1 deletion xpsi/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

"""

__version__ = "2.3.0-b"
__version__ = "2.3.0"
__author__ = "The X-PSI Core Team"

try:
Expand Down
Loading