Skip to content

Releases: xraypy/xraylarch

2026.2.2

Choose a tag to compare

@newville newville released this 17 Jun 20:53

[2026.2.2 - 2026-06-17]

Larix

  • xasnorm: fix "Copy to Selected Goups" buttons to not copy too many
    parameters from the currently displayed group.

Other GUIs

  • gsemap viewer: several small fixes for map building from rawmap folders.

Exampes/Docs:

  • work in progress to update docs to more modern Sphinx extension,
    notably for 'subfigures' in the docs.

Distribution/Install/General:

  • update macOS installer link
  • fix fetching of "nightly build"

2026.2.0

Choose a tag to compare

@newville newville released this 22 May 20:09

[2026.2.0 - 2026-05-22]

xraylarch library

  • move everything related to larch.xrd.struct2xas to larixite (in
    view of future separate development)
  • some refactoring to better force numpy scalars to plain python
    numeric types
  • feffit: update defaut feffit param bounds
  • feffit: add more per-path 'magic values' (nleg, degen, vfermi, etc)
    in addtion to reff in the code setup, tweak start param values
  • feffit: more checks for saving/copying feffit fit parameters
  • feffit: delay of asteval-expression evaluation for constraints
  • feffit: fix feffit 13-path example to have more robust handling for
    how parameters and constrainte are defined
  • hdf5 handling: better decoding of scalar-like byte data.
  • fix use of numpy.trapezoid for numpy 2.
  • fix passing style in bokeh plots, and add style option for
    its multi_plot

Larix

  • xasnorm: add user-named settings for configurations of XAS
    Normalization Paramters. That is, the user can save and reload (in
    later sessions) chosen parameters for differ data categories, with
    examples for 'S XANES' and 'Theoretical Calculations'.

  • xasnorm: energy_calib can now auto_align a set of selected groups,
    better handling of large-ish differences in e0 values

  • xasnorm: some improvements in auto_nnorm and copying the 'show_*'
    options

  • exafs: add user-named settings for configurations of EXAFS
    Parameters, as for XAS Normalization.

  • io: fix import bug in specfile_writer.py

  • io: fix exporting CSV files.

  • exafs: add save/load of users EXAFS parameters to named config

  • exafs: default bkgclamp values as ints, not floats

  • xydata: cleanup for reading and using xydata

  • feffit: better creation of Parameters for feffit, including earlier
    loading of builtin Path values (reff, etc) and function (sigma2_*,
    etc)

  • using latest wxutils dark-mode detection: good on macOS, "forcing
    to Light mode for now" on Windows, poor on Linux.

  • better handling of out-of-bounds Plot cursor values.

XRF Fitting

  • fitting GUI tweaks
  • fitting: better checking for setting values for Choice boxes
  • fitting: use timestamp as fit label for XRF fits
  • fitting: Font/Color simplification

Other GUIs

  • gsemap viewer: use auto_reverse, cleanups
  • gsemap_viewer: fix for importing and using XRF fit result.
  • xrf epics control: command-line arguments improved, with
  • xrf epics control: many cleanups, improved support for single MCAs,
    and enable set calibration for single MCA/Ketek.

Exampes/Docs:

  • update Feff_ZnSe ipython examples
  • update CIF/Feff Jupyter example #1
  • add Jupyter example of using amcsd database to extract CIFs and run
    Feff

Distribution/Install/General:

  • update dependencies (larixite, silx, wxutils)
  • use machine architecture in GetLarch.sh, now defaulting to arm64
    for most macOS machines
  • update github actions to properly activate conda environment

2026.1.2

Choose a tag to compare

@newville newville released this 10 Mar 23:57

Overview:

  • fixes to painful installation woes on MacOS with spglib (part of pymatgen).
  • Much better (maybe even "good") support for Dark vs Light Mode on MacOS and Windows. The.GUI applications, notably Larix, should be usable in both Dark and Light system modes and automatically switch if the mode changes while the program is running. There may be some lingering challenges, but the basically unusable cases of light text on a light background or dark text on a dark background should all be fixed. GUI applications other than Larix are less well-tested. And, almost no testing has been done on Linux with Dark mode.
  • several bug fixes.

Larix:

  • calculate emin, emax after initialising e0 in rebin_xafs (#610, patrick-austin)
  • make sure un-built feffit model is built (and so restored) before replacing the displayed model, as for a new group (George Sterbinsky)
  • Structur2XAS: add configurable PRINT card values to Struct2XAS.make_input_feff (#606, Helen Engelhardt)
  • update FEFF header parsing to avoid false matches in author and title lines (#604, liqunkang)
  • feffit panel: add copy-parameer-expression buttons, with dialog to copy Feffit Path Parameters from one path to others (Shelly Kelly)
  • better informing analysis panels to fill_form() with a newly installed group
  • prefer column names from Column label over label line when reading column files.
  • better test for energy in array label to identify xas data
  • many small fixes for better support of Dark Mode and switching Dark/Light modea

Larch library:

  • fix reading bytes/string values from hdf5 files in h5group (#608, patrick-austin)
  • many fixes to common wx widgets (including Larch Buffer) for dark mode.
  • many fixes for using updated wxutils, especially with darkmode detection, and new model for widget colors.

Other GUIS:

  • XRF_Map: put adding of highlights to maps in try/except clauses
  • XRF Maps: better fix for ways to identify xspress3 hdf5 file
  • XRF Epics Control: many additions to show more controls for Xspress3 Epics interface
  • XRF Display: many fixes for dark mode
  • XRD1D: tweaks to layout, background subtraction, color modes

Distribution/Install/General:

  • add pymatgen from conda-forge to constructor script
  • update wxmplot and wxutils versions, for beter dark mode
  • add dioptas as optional install package
  • build matplotlib font cache on (build icons) to reduce startup time for first exe launch
  • update versions and formatting for GetLarch scripts, add explicit spglib from conda-forge
  • update constructor package list

2026.1.1

Choose a tag to compare

@newville newville released this 23 Jan 04:32
  • fix reading Python XDI files into "proper" larch Group
  • fix bug with Windows installer that installed a broken numpy
  • fix Larix doing background-subtraction with very finely spaced QXAFS data

2026.1.0

Choose a tag to compare

@newville newville released this 19 Jan 22:20

[2026.1.0 - 2026-01-19]

xralyarch library:

  • move wxmplot plotting tools to larch/plot module, to make more consistent with boken and plotly plotting options
  • many fixes and use of common utilities to plotting functions for all of wxmplot, bokeh, and plotly
  • better detection if wxmplot is running with a Jupyter environment for more interactive plots there.
  • read_xdi() now uses a pure-Python XDI reader. This allows detecting the encoding before the file is read,
    which avoids some oddities for various encodings. It allows is slightly more tolerant of non-XAS data, and
    preserves more comment lines.
  • some updates to beamline reader code to better guess array labels.
  • slowly but progressing on removing many leading underscores for function names,
  • better handling of param_group with Feffit in Python.
  • fix Feff Paths to use and report the full path of the filename, and use that in the Path geometry label,
    to allow identical paths to be used as separate paths.
  • fix reported path degeneracy in Feff Path report (thanks Chris Joseph)
  • add better numpy-json encoder using b64 encoding, and use by default (still supporting older versions!).
  • add geometry, with angles, to feffpath object.
  • fix boxcar averaging to be simpler

Larix:

  • in all of Feffit, Pre-edge Peak Fitting, and General Curve Fitting, the "current fit" is now properly
    recognized for each group, so that switching groups may completely replace the model shown in the main panels
  • normalization: fix use of vertical offset in normalization plots.
  • normalization: fix remembering explicit setting of edge_step when changing groups
  • normalization: copying a group retains energy reference by default.
  • normalization: even better "copy parameters" behavior.
  • normalization: fix auto_step and also copy_parameter not always resetting parameters for current group
  • normalization: better inheritance of e0 and 'auto_e0' from Athena group
  • pre-edge peaks: fix recognizing 'background components' when loading pre-edge peak from saved session
  • pre-edge peaks: fix exporting fit result
  • pre-edge peaks: fix exporting table of components (thanks, Christion Dewey).
  • pre-edge peaks: fix setting 'form' when reloading fit using step function (thanks, Christion Dewey).
  • curvefit: improve consistency with prepeaks_panel
  • curvefit: fix adding model component not always working.
  • feffit: fix reading and plotting Feff calculations without data.
  • feffit: each Feff Path shows a small table of geometry data, including leg lengths and angles.
  • rebin dialog: fix to setting name of the output group and set "boxcar" as the default method.
  • deglitch dialog: fixes to masking data
  • smoothing dialog: set boxcar smoothing to default.
  • when starting up with locked session files, allow marking all session lock files as 'delete'

Other GUIs

  • Viewer/Controller overhauled to change from "foreground/background" MCA to support unlimited multiple spectra,
    and have a "spectra browser" to choose which one or many to show, with a familiar ListBrowser selector. Also,
    several of the options for how to display data are not active check-boxes above the plot.
  • Mapviewer updated to use this new XRF display, with each XRF Map per session having a list of spectra that
    can be displayed with the spectra browser.
  • Mapviewer replaces unused "area stats" to showing legend of positions drawn on the map, with simple numerical
    labels shown on the map.
  • fixes to better support single-element MCA XRF detector, including supporting energy calibration from ndarray.
  • many small fixes for XRF fitting GUI with new XRFDisplay
  • improve pileup auto-scaling, relying on incident energy being known or guessable
  • better peak_finder function
  • add PV for incident energy (and units) so that the MCA can have incident energy set
  • make sure epics mca is fully updated (for better roi drawing)
  • support XRD masks with values > 1
  • in XRD 1D Viewer: XRD files are exported to XY with X being 2theta in degrees.

development and maintenance:

  • add shortcut/app to run Jupyter Notebook in the Python environment installed with xraylarch
  • add conda init to GetLarch shell installer
  • attempted but abandoned trying to get macos miniconda environment to work in GitHub Actions.
  • allow using XRAYLARCH_NO_PLOT environment variable to effectively disable plotting for testing
  • install pytest-xvfb only on linux
  • add pymatgen as a conda dependency for testing
  • update minimal versions for many dependencies
  • update constructor config and GetLarch scripts

docs docs and examples:

  • converted many examples from 'larch scripts' to Python scripts
  • add many examples using Jupyter, including using wxmplot plotting.

2025.3.0

Choose a tag to compare

@newville newville released this 10 Sep 18:01

[2025.3.0 - 2025-09-10]

Larix improvements and bugfixes:

  • the FileList in Larix and many related Windows (to import data, etc), has a richer set of options with Right Mouse Button. These also have "keyboard shortcuts" or "accelerators" (Ctrl- / Alt- keys) that do most actions to move and select groups. This allows much faster and easier manipulation of the list of datasets.

  • Saving Session Files is now more robust against certain classes of errors. It will also happen in a background thread to avoid hanging Larix for large projects.

  • Loading Session Files now shows a more complete list of "non XAS Data groups" that can be imported.

  • on startup, Larix defines a "Session ID" (almost random) used for autosaving sessions, but now uses a separate "Session Name" that will be used for an explicitly Saved Session. This will be set from the name of the first loaded dataset, but can be changed if using "Save Session As".

  • on startup, a Lock File using the Session ID will be created, and removed only when Larix is shutdown cleanly.

  • on startup, any existing Lock Files -- which might signal a Session that crashed or is running in another process -- and their corresponding auto-saved Session will be shown in a Dialog as available for Import or for having the Lock File removed.

  • the "Session Name" above will be shown in the Larix Title Bar.

  • Plot Windows will have Title Bars that include the Session Name and the Analysis Panel (or the Data Processing Window) that generated the plot.

  • Configuration of plotting options such as linewidths, colors, themes, and so forth is now both easier and more robust. Many of the plotting routines have had "hardcoded" values for such plot attributes removed. The "plot" tab is "Edit Preferences" now has only a "Save Plot Configuration" to save the configuration of the current Plot Window #1 to ".larch/wxmplot.yaml". This allows the configuration to be set from the Plot Window Configuration frame. This configuration file (which could be edited) will be loaded on startup and used for all plots.

  • The pre_edge range shown for XAS Normalization is more accurately displayed.

  • Very short pre-edge ranges better sets the backgroud form to "Constant".

  • More fixes so the EXAFS processing is re-done when groups are copied.

  • The XY Data Analysis Panel now allows settings which X and Y arrays to use for a Group.

  • Some simplifications in CurveFit Layout.

  • Fix for proper normalization of data in Pre-edge Panel.

  • Several fixes for showing Feffit Results.

  • A general attempt to have better and more consistent Fond sizes.

xraylarch library:

  • better allow out-of-order constraint expressions in feffit Parameters
  • fixes to propagating uncertainties to Path Parameters
  • Make sure energy data is monotonically increasing in "rebin_xafs"
  • Fix reading edge_step in autobk.
  • many improvements to json-serialization for Session files, and avoiding some recursion errors and problems saving some numpy arrays. Add serialization of uncertainties ufloats.
  • improvements and simplification of saving session files.
  • load_session() now obeys the order of groups supplied in xasgroups argument.
  • many improvements to xafsplots functions to use wmplot.yaml theme, and to better use relative z-order values.
  • plotting chi(E) now better includes the edge-step.

Other GUIs:

  • XRF Display: avoid flashing of ROI label

General development and maintenance:

  • update the minimum version of several required packages.
  • several updates to dependencies.
  • support for Python 3.9 is dropped.
  • remove IPython InteractiveShell calls
  • allow writing TOML file with tomli_w, but preferring yaml over toml.

2025.2.2

Choose a tag to compare

@newville newville released this 29 Jul 12:27

Larix improvements and bugfixes:

  • allow adding feff paths without data
  • cleanups for XAS auto-normalization, and avoiding overprocessing
  • revert to using read_gsexdi for 'epics stepscan' data, cleanups
  • exafs_panel: avoid reproccessing all groups with form
    values/setting for current group.
  • move data processing tasks to separate module, and to use the file
    list from main window
  • add register/run callbacks from controller for when the Larix
    Groupname changes -- used for data proceesing tasks
  • fix bad_channels when reading in multi-element detector data
  • editing plot preferences will push to current plot displays
  • exafs_panel: better separation of plotting and processing parameters
  • exafs_panel: better isolation of group processing parameters, and
    copy of parameters.
  • lincombo: fix fits in k-space (thanks AJ Kropf), and LCF can now
    use chi*k**3
  • lincombo: add popup warning when asking to fit data in k-space
    when chi(k) is not yet available
  • feffit: add csv_path_report() method to FeffitDataset, use
    tabulate if installed.

xraylarch library:

  • fix a bug in mback_norm method (tj-eldridge <thomas.eldridge@esrf.frr)
  • tolerate very short pre-edge and normalization ranges, reducing
    npre and nnorm if necessary
  • increase max size of column file
  • more uniform use of numpy asmatrix
  • general cleanups, force group to have a name attribute
  • fix support older sessions/projects
  • fix error with polyfit and very short post-edge regions
  • fix Rixs bm16 update (Mauro Rovezzi mauro.rovezzi@esrf.fr)
  • better close for SQLite databases.
  • fix correlated Debye model: force path coords to float
  • xafsplots: add scale_window to plot_chir()
  • add dict_report method to FeffPath to return plain dict of values

Other GUIs:

  • XRF Map: read dtfactor directly from HDF5 if available, otherwise
    try to compute it.
  • XRF Map: even more straightforward Read Master
  • XRF Map: remove use of scandb in read_xrm master file, skip empty rows
  • XRF Map: dont trim sinograms on XRD data
  • Larch GUI: make sure larch buffer starts showing end of output text

General development and maintenance:

  • add issue templates
  • add darkdetect to dependcies, update constructor script
  • make sure darkdetect dependency installs with plain pip install
  • update MANIFEST, using pyproject.toml, remove setup.cfg
  • update readme, change format
  • add function and larch -n CLI option to install nightly build.
  • add bash scripts to run tests with more care for temporary resources.

2025.2.0

Choose a tag to compare

@newville newville released this 25 May 21:07

[2025.2.0 - 2025-05-25]

Larix improvements and bugfixes:

  • many improvements to importing and showing XY data
  • add initial working Curve Fitting Panel for XY and XAS data.
  • add "XAS MODE" when reading XAS data, including 'calculation'
  • better reading of FEFF/FDMNES calculated XAS spectra, use "mode=calculation" when reading these files.
  • re-arrange Plotting choices for XAS Normalization Panel
  • re-arrange Plotting choices for EXAFS Panel
  • allow "Plot relative to E0" - either Group's E0 or elements nominal E0 in XAS Normalization Panel
  • allow "Plot-on-Choose Group" to be optional in XAS Normalization and EXAFS Panel
  • add colored console logger
  • add Constant+StepModel (arctan/error function) to pre-edge peak baselines, some related tweaks
  • tweak colors and how pre-edge baselines are plotted
  • fix exporting feffit results in filtered chi(k)
  • add plot theme of '<Auto>' to use system dark/light mode
  • add stderr columns to linear combination output files
  • save element/edge on selection, save in group config
  • fix identifying reference groups from Athena Project files.
  • better use of functions from xafsplots -- more reproducible plots.
  • better consistency of Panel form data and Group's config -- auto-saving when a Panel is hidden and re-exposed.
  • better saving og element/edge in XAS Normalization Panel
  • allow showing EK0 on EXAFS Panel
  • import and expand fit models from lmfit, defining step/rectangle functions by form (linear, atan, erf, ..)
  • show tracebacks but fail gracefully when trying to import broken analysis panels
  • make sure ynorm is defined before trying to plot in XY Data panel
  • setting Displayed Panels is now under Edit Preferences, and choices can be saved for future sessions.
  • fix setting energy range for linear Combo plots
  • when importing session, make sure the datatype-appropriate panel is shown
  • more consistent font weights, using Bold for all "results tables".

Other GUIs:

  • XRF Map: fix adding highlighted areas, saving points
  • XRF Map: do not rescale tomo reconstruction with mean value
  • XRF Display/Control: add ROI countrates for each detector
  • XRF Display/Control: add color warnings for ROI, OCR, deadtime
  • XRF Display/Control: make sure to read xrf calibration if needed

xraylarch library:

  • fix typos in rebin
  • more error-checking for pre-edge details
  • force polyfit to always return a list of coefficients
  • add step models to pre_edge prepeaks models
  • return smoothing default method back to "boxcar"
  • use read_ascii for epics scanfiles
  • many improvements to xafsplots functions
  • refactor xyz2struct: Use vectorized np.max for coordinate calculation
  • better error checking for encoding ndarrays
  • xafs/autobk.py: reduce impact of spline clamps by a factor of 10
  • xafs/pre_edge.py: add 'iscalc' option to set tiny pre-edge range, and pre_edge=constant for calculated XAS.
  • fix autorange for plot_bkg() with multiple traces

General development and maintenance:

  • refactoring and cleanup of some tests
  • update numpy.testing usage
  • remove support of pymca from deglitch
  • remove pandas dependencies
  • using scipy-based spike removal in place of numpy and pandas
  • more usage of pathlib where possible for Path names and removing files
  • better use of GitHub Actions on Pull Requests
  • improve tests to allow DISPLAY for some preliminary GUI testing
  • add darkdetect dependency, working toward better support for DARK v LIGHT mode
  • allow numpy>2 and Python 3.13, using Python 3.13 by default.
  • update license and pointers to license

2025.1.1

Choose a tag to compare

@newville newville released this 13 Jan 00:19
  • bugfix for generating and running Feff for XAFS calculations -- fixed PRINT flag
  • more error checking in find_e0 for coercing to numpy arrays.
  • add spline interpolation option for XAFS re-binning
  • updated the binary Installers and GetLarch Installation scripts to use the latest conda/mamba packages.
  • some doc updates

Full Changelog:

2025.1.0...2025.1.1

2024.12.0

Choose a tag to compare

@newville newville released this 20 Dec 19:54

Main changes:

  • Saving Athena File from Larch/Larix now gives files that Athena can read
  • CIF and XRD and CIF->Feff.inp conversion has been improved and migrated to the separate larixite project.

Bug fixes:

  • make sure multi-column imports sets 'mu' array

  • multiple improvements to reading data lines, including respecting allow_dates, allowing semicolon- or tab-delimited lines.kk

  • avoid system bell on invalid floats for parameter widgets

  • add R^2 to fit stats for pre-edge peak fitting

  • add spline option for rebinning xafs (now set as default)

  • fix bug when saving athena projects that prevented them to be read by athena.

  • make athena project writing for consistency with Athena

  • reorder pyFAI imports for Windows

  • fix pre_edge docstring

  • relax requirement for pymatgen for Py3.9

  • using utilities from pyshortcuts where possibie

  • xrd1d: fix core-dump on exit, add check for currrent CIF before calculating HKLs

  • add larixite as dependency, use dbs and code from there

  • using larixite as a separate repo for cif2feff and general CIF/XRD data

  • use epicsscan to connect to ScanDB

  • better retain datatype when reading column frame data

  • fixes for Rixs reader

  • fix saving feffit result chi in all spaces

  • more dependency version updates, drop Python 3.8

  • change license to MIT for consistency with other projects, update requirements

  • update to BLISS/HDF5 files

  • only set shell wx if LarchWxApp is imported, for whatever reaseon

  • fix storing of port for larch_server

  • Bug fix for using feff6l and feff8l

  • update to Struct2xas v2407 (before refactoring)

  • better mapping of unique xtal sites to feff input formatting tweaks

  • better saving of chi(q) outputs

  • feffit_panel: make sure FT params are used on data

  • add support for XAFS pre-edge that is a constant value

  • remove dups (and nans) when merging groups

  • remove duplicate energies when reading athena projects

  • some more fixes for CIF processing

  • remove pycifrw from dependencies and github workflows

  • github actions now use conda, no longer needing mamba