Larch: Applications and Python Library for Data Analysis of X-ray Absorption Spectroscopy (XAS, XANES, XAFS, EXAFS), X-ray Fluorescence (XRF) Spectroscopy and Imaging

Overview

Larch: Data Analysis Tools for X-ray Spectroscopy and More

Larch is an open-source library and set of applications for processing and analyzing X-ray absorption and fluorescence spectroscopy data and X-ray fluorescence and diffraction image data from synchrotron beamlines. It is especially focussed on X-ray absorption fine-structure spectroscopy (XAFS) including X-ray absorption near-edge spectroscopy (XANES) and extended X-ray absorption fine-structure spectroscopy (EXAFS). It also supports visualization and analysis tools for X-ray fluorescence (XRF) spectra and XRF and X-ray diffraction (XRD) images as collected at scanning X-ray microprobe beamlines.

Larch is written in Python, making heavy use of the excellent scientific python libraries (numpy, scipy, h5py, matplotlib,and many more). Larch can be used as a Python library for processing and analyzing X-ray spectroscopy and imaging data. In addition, the applications built with it also use a built-in Python-like macro language for interactive and batch processing. This domain-specific language is intended to be very easy to use for novices while also being complete enough to automate data processing and analysis and to encourage and facilitate a gentle transition to transition from GUI-only analyses to scripted and programmatic analysis of larger data sets. This macro language also allows Larch to be run as a service, interacting with other processes or languages via XML-RPC, and so be used by the popular Demeter XAFS application suite.

Larch is distributed under an open-source license that is nearly identical to the BSD license. It is under active and open development centered at the GeoScoilEnviroCARS sector of Center for Advanced Radiation Sources at the University of Chicago has been supported by the US National Science Foundation - Earth Sciences (EAR-1128799), and Department of Energy GeoSciences (DE-FG02-94ER14466). In addition, funding specifically for Larch was granted by the National Science Foundation - Advanced CyberInfrastructure (ACI-1450468).

The best citable reference for Larch is M. Newville, Larch: An Analysis Package For XAFS And Related Spectroscopies. Journal of Physics: Conference Series, 430:012007 (2013).

Larch Applications

These applications installed with Larch, in addition to a basic Python library. Here, GUI = Graphical User Interface, CLI = Command Line Interface, and beta indicates a work in progress.

Application Name GUI/CLI Description
larch CLI simple shell command-line interface
Larch GUI GUI enhanced command-line interface with data browser
XAS Viewer GUI XAFS Processing and Analysis: XANES pre-edge peak fitting, linear analysis, PCA/LASSO, EXAFS processing, Running Feff, fitting EXAFS data to Feff paths.
GSE Map Viewer GUI XRF Map Viewer for GSECARS X-ray microprobe data.
XRF Display GUI Display and analyze XRF Spectra.
feff6l CLI Feff 6 EXAFS calculations
feff8l CLI Feff 8 EXAFS calculations (no XANES)
qtrixs GUI beta Display RIXS planes, take profiles
1D XRD Viewer GUI beta Display and work with 1-D XRD patterns
2D XRD Viewer GUI beta Display XRD images
Comments
  • Plugin to read SPEC files

    Plugin to read SPEC files

    I gave a try to Larch plugin system and I enjoyed its simplicity. Here a first version of a simple plugin to read SPEC files:

    https://gist.github.com/maurov/5284508

    I plan to improve the class by adding more methods, but first I would validate if I'm going in the right direction for implementing new plugins.

    Regarding the Python class to read SPEC files, I have evaluated:

    (1) specfilewrapper in PyMca (rewritten in Python from the 'specfile' C class developed at ESRF) (2) pyspec (http://pythonhosted.org/pyspec/) (3) specparser (https://github.com/tpikonen/specparser) (4) the one included in TDL

    To my opinion, (1) is the best choice for simplicity, versatility and maintenance. (2) is a nice project too but cannot handle motors names that include a dot, as 'Mono.Energy'.

    plugins 
    opened by maurov 18
  • symbol problems with the larch server

    symbol problems with the larch server

    After a fit, this is a symbol: fit.datasets[0].epsilon_k.

    If I ask the larch server for that symbol via the get_data command, nothing is returned (the XMLRPC version of an empty response).

    If, however, I do this right after the fit: foo = fit.datasets[0], then ask the server for foo.epsilon_k, I get the expected return value (a list of epsilon values for each k-weight).

    Thus, the problem seems to be with the [0].

    This isn't an immediate problem for Demeter -- Demeter gives another name to each of the fit.datasets[N]. However, it's either a bug or I am misunderstanding the syntax of using the server for that kind of symbol.

    opened by bruceravel 15
  • `--root=

    `--root="${pkgdir}"` ignored at some places in `setup.py install`

    The packaging step of xraylarch fails on archlinux since version 0.9.38 (0.9.37 worked fine, 0.9.39 still fails) with:

    running install_scripts
    Traceback (most recent call last):
      File "setup.py", line 311, in <module>
        shutil.copy(src, dest)
      File "/usr/lib/python2.7/shutil.py", line 133, in copy
        copyfile(src, dst)
      File "/usr/lib/python2.7/shutil.py", line 97, in copyfile
        with open(dst, 'wb') as fdst:
    IOError: [Errno 13] Permission denied: '/usr/bin/larch_server'
    ==> ERROR: A failure occurred in package().
    

    The command executed (as non-root) is:

    python2 setup.py install --skip-build --root="${pkgdir}" --prefix=/usr
    

    My guess is, that --root=... is not honored in all places, thus /usr/bin/larch_server gets touched instead of ${pkgdir}/usr/bin/larch_server

    regards, Erich

    opened by deep-42-thought 14
  • autobk parameter XAFS plugins  are lost after function execution?

    autobk parameter XAFS plugins are lost after function execution?

    Hi I was wondering why the data group add attributes: pre1 pre2 norm1 norm2 after pre_edge() while kmin, kmax , kweight are not stored. Maybe will be nice make a dictionary with the parameter of EXAFS extraction in the group. What do you think about?

    question 
    opened by Prestipino 14
  • [xas_viewer] current group highlight does not stay persistent

    [xas_viewer] current group highlight does not stay persistent

    @newville I have observed an annoying behavior on xas_viewer (master on Linux) that seems a bug to me:

    • click on a group -> it gets highlighted in the left panel
    • push the plot button -> the highlight disappears

    Can you reproduce this misbehavior from your side?

    bug 
    opened by maurov 11
  • display(), a more feature full variation of show()

    display(), a more feature full variation of show()

    I find myself dissatisfied with show(), particularly for a group with a lot of members. This stab at an "improvement" adds flags for color, truncating lengthy lists and tuples, and suppressing bound methods. All this together makes it a bit easier -- at least for me -- to examine the group's contents.

    Note that

    display(group, truncate=False, with_color=False, with_methods=True)
    

    behaves just like show(group).

    I put this in plugins/local/ and in the _local group. It's not clear to me quite what the purpose of "local" is. plugins/std might have been more appropriate, but I did not want to put this in _builtin.

    opened by bruceravel 11
  • Atoms plugin in Larch?

    Atoms plugin in Larch?

    Does anybody is planning to port "atoms" to Larch? If not, I could probably invest some time in this. I never went through the source code of atoms itself, so the ideas I have in mind on how to implement it could result not compatible with Demeter then...

    The Larch plugin I have in mind should simply do: 1) read a CIF file and some keyword parameters; 2) based on this, it will return a FEFF* or FDMNES input file.

    For the templates, I think is enough the 'string.Template' included in the Python standard library (there are tons of powerful template systems available, but this will avoid to include a further dependence in Larch).

    For the CIF parsing, well, I think we are obliged to include a dependence on an external library. Do you have any preference for this? I'm evaluating some of them and at the moment the one I like the most is in ASE (https://wiki.fysik.dtu.dk/ase/index.html)... well, this is using a sledgehammer to crack a nut.

    Anyway, your feedback is welcome.

    plugins 
    opened by maurov 11
  • adding example: Fe K-edge treatment in a Jupyter notebook

    adding example: Fe K-edge treatment in a Jupyter notebook

    Following issue #324 :

    Jupyter notebook example using xraylarch and lmfit in Python to treat spectra at the Fe K-edge.

    Let me know if it's good for you!

    opened by charlesll 10
  • wx import issue in both bash and conda installs: solved by installing wxpython

    wx import issue in both bash and conda installs: solved by installing wxpython

    Hi,

    I tried installing Larch using miniconda as well as the bash script on Linux x86-64. In both case I end with an error message related to wx when trying to import larch:

    >>> import larch
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/home/charles/xraylarch/lib/python3.6/site-packages/larch/__init__.py", line 28, in <module>
        from .shell import shell
      File "/home/charles/xraylarch/lib/python3.6/site-packages/larch/shell.py", line 10, in <module>
        from .interpreter import Interpreter
      File "/home/charles/xraylarch/lib/python3.6/site-packages/larch/interpreter.py", line 18, in <module>
        from . import builtins
      File "/home/charles/xraylarch/lib/python3.6/site-packages/larch/builtins.py", line 22, in <module>
        from . import fitting
      File "/home/charles/xraylarch/lib/python3.6/site-packages/larch/fitting/__init__.py", line 6, in <module>
        import wx
      File "/home/charles/xraylarch/lib/python3.6/site-packages/wx/__init__.py", line 12, in <module>
        __version__ = wx.__version__.VERSION_STRING
    AttributeError: module 'wx' has no attribute '__version__'
    

    This issue is solved by installing wxpython with conda.

    Should wxpython be added as a dependency?

    opened by charlesll 10
  • possible problem with order of plugin import

    possible problem with order of plugin import

    Hi Matt,

    This morning, with a freshly git pull-ed larch, I am unable to start the larch interpreter.

    Below is the traceback along with the output of these print statements

                    print "\n", mod, filelist
                    for fname in filelist:
                        print fname, fname[:-3]
    

    at this location: https://github.com/xraypy/xraylarch/blob/master/lib/builtins.py#L393

    /home/bruce/.larch/plugins/wx ['scanviewer.py', 'periodictable.py', 'gui_utils.py', 'xrfdisplay_fitpeaks.py', 'plotter.py', 'xrfdisplay.py', 'mapviewer.py', '__init__.py', 'gse_dtcorrect.py', 'xrfdisplay_utils.py', 'parameter.py', 'mapimageframe.py']
    scanviewer.py scanviewer
    periodictable.py periodictable
    gui_utils.py gui_utils
    xrfdisplay_fitpeaks.py xrfdisplay_fitpeaks
      File "/usr/local/lib/python2.7/dist-packages/larch/builtins.py", line 411, in _plugin_file
        out = imp.load_module(plugin, fh, modpath, desc)
      File "/home/bruce/.larch/plugins/wx/xrfdisplay_fitpeaks.py", line 24, in <module>
        from parameter import ParameterPanel
      File "/usr/local/lib/python2.7/dist-packages/larch/builtins.py", line 397, in _plugin_file
        ret =  _plugin_file(fname[:-3], path=[mod])
      File "/usr/local/lib/python2.7/dist-packages/larch/builtins.py", line 419, in _plugin_file
        write(traceback.print_tb(tback))
    Traceback (most recent call last):
      File "/usr/local/bin/larch", line 99, in <module>
        shell = larch.shell(banner_msg=BANNER, quiet=options.quiet)
      File "/usr/local/lib/python2.7/dist-packages/larch/shell.py", line 53, in __init__
        self.larch  = Interpreter()
      File "/usr/local/lib/python2.7/dist-packages/larch/interpreter.py", line 142, in __init__
        builtins._addplugin(pdir, _larch=self)
      File "/usr/local/lib/python2.7/dist-packages/larch/builtins.py", line 443, in _addplugin
        return _plugin_file(plugin)
      File "/usr/local/lib/python2.7/dist-packages/larch/builtins.py", line 400, in _plugin_file
        write(traceback.print_tb(tback))
    TypeError: expected a character buffer object
    

    The location of the beginning of the traceback seems to be the line in plugins/wx/xrfdisplay_fitpeaks.py that says

    from parameter import ParameterPanel
    

    and the problem seems to be that parameter.py has not been imported yet (it comes later in filelist).

    I can make larch finish startup by manually prepending parameter.py to filelist.

    Do you need to maintain a dependence tree so that plugins are imported in the right order?

    opened by bruceravel 10
  • Cannot open project

    Cannot open project

    Hi Matt @newville , I'm using Larch for some time. Everything worked fine until this weekend. I can use XASviewer to process data however I can't open any of the saved projects. When I try to open the saved project, I got error message in the terminal (see below) and the project has not been opened. I also tried to load new data and saved as a new project - l also couldn't open it. Any ideas how to fix it?

    run in conda environment "base":

    c:\users\annaw\xraylarch\Scripts\xas_viewer.exe

    Traceback (most recent call last): File "c:\users\annaw\xraylarch\lib\site-packages\larch\wxxas\xasgui.py", line 799, in onReadDialog self.onRead(path) File "c:\users\annaw\xraylarch\lib\site-packages\larch\wxxas\xasgui.py", line 809, in onRead self.show_subframe('athena_import', AthenaImporter, File "c:\users\annaw\xraylarch\lib\site-packages\larch\wxxas\xasgui.py", line 754, in show_subframe self.subframes[name] = frameclass(self, **opts) File "c:\users\annaw\xraylarch\lib\site-packages\larch\wxlib\athena_importer.py", line 83, in init self.a_project = read_athena(self.filename, do_bkg=False, do_fft=False, File "c:\users\annaw\xraylarch\lib\site-packages\larch\io\athena_project.py", line 915, in read_athena aprj.read(filename, match=match, do_preedge=do_preedge, do_bkg=do_bkg, File "c:\users\annaw\xraylarch\lib\site-packages\larch\io\athena_project.py", line 780, in read data = parse_perlathena(text, self.filename) File "c:\users\annaw\xraylarch\lib\site-packages\larch\io\athena_project.py", line 353, in parse_perlathena raw[key] = np.array([float(x) for x in aeval(text2list(t))]) File "c:\users\annaw\xraylarch\lib\site-packages\asteval\asteval.py", line 314, in call return self.eval(expr, **kw) File "c:\users\annaw\xraylarch\lib\site-packages\asteval\asteval.py", line 324, in eval raise ValueError(msg) ValueError: length of text exceeds 50000 characters[] issue

    Best, Anna

    opened by AnnaDragonfly 9
  • Issue plotting the result when using DiffKK

    Issue plotting the result when using DiffKK

    Hi there. In section 13.9 of the Larch Github manual, it refers to computing the f' and f" values as in Cross et al. (1998). I have managed to install the relevant modules and import the relevant libraries. However, I cannot work out how to plot the results. It is described in the example as:

    ''' newplot(dkk.energy, dkk.f2, label='f2', xlabel='Energy (eV)', ylabel='scattering factors', show_legend=True, legend_loc='lr') plot(dkk.energy, dkk.fpp, label='f"(E)') plot(dkk.energy, dkk.f1, label='f1') plot(dkk.energy, dkk.fp, label='f'(E)') '''

    However this does not work. I have tried matplotlib.pyplot and also wxmplot but neither work. I don't think the wxpython library is compatible with my Spyder IDE, as Python crashes whenever I try to use Wxpython to load this result. Does anybody have a solution?

    opened by Ayrtonb1 1
  • [xas_viewer] plot window -> keep custom zoom

    [xas_viewer] plot window -> keep custom zoom

    @newville a feature request I get usually from the users is to have the possibility to keep the selected zoom in an plot window when replotting. This would be something like the following:

    • plot something (in plot window: plot_N)
    • with the mouse zoom a region in plot_N
    • when replotting in plot_N (current group or selected) keep the XY region as selected before
    • to reset the plot region either right click on the plot window or select one of the standard ranges given in the combo box

    What do you think?

    enhancement 
    opened by maurov 4
  • [xas_viewer] energy_shift

    [xas_viewer] energy_shift

    @newville this is a follow-up of #357 . I have tried to fix it by myself, but I got lost in the Wx GUI stuff. If you could help with this soon, it would be great. The users at the beamline still find difficult to adjust the energy shifts with Larch. As a consequence, they go back using Athena...

    The following are checked on the latest master version (xraylarch-0.9.65.post133+g5c834772)

    1. bug in copying energy reference groups
      • load two data groups (group1, group2), plus an energy reference one (group_eref)
      • select group1 and group2
      • click on group1 and set group_eref as energy reference
      • click copy in the energy reference
      • click on group2 -> BUG the energy reference is not group_eref (expected) but group2
    2. energy_shift is not kept
      • click on group1
      • put 1 in "energy shift from original" and press enter (just in case)
      • click on group2
      • click back on group1 -> BUG energy shift from original is 0
    3. energy_shift is not applied
      • click on group1
      • right click to copy group1 into group1_1
      • select group1 and group1_1
      • plot selected groups in dmu/dE -> are identical
      • click on group1_1 and put 1 into energy shift from original
      • replot selected groups -> BUG the two groups are not shifted
    4. applying energy_shift to reference does not propagate to groups linked to it
      • click on group1, put energy_shift to 0 and select group_eref as energy reference
      • click on group_eref and add 1 to energy_shift
      • click group1 -> BUG energy_shift is still at 0

    The workaround to fix bugs 2 and 3 and get the expected behavior is to deselect plus select again the "auto?" next to E0 selection. I do not understand why this solves bug 2. For bug 3, we may apply directly the energy_shift value also to E0, or even better, E0 should simply refer to group.energy not to group.energy_orig.

    Please, just to clarify my understanding of the energy_shift behavior in the GUI, could you check that the following is correct?

    • read a group (g=Group()) -> g.energy = g.energy_orig + energy_shift, energy_shift = 0
    • when setting energy_shift to a value: g.energy = g.energy_orig + energy_shift
    • everything else (E0, plots, exports, whatever) uses g.energy
    • when read energy reference group (g_ref = Group()) -> g.energy_ref = g_ref or g.energy_ref = g_ref.name

    I hope this is clear, if not, please, let me know.

    opened by maurov 2
  • error in plot_chifit: PyNoAppError: The wx.App object must be created first!

    error in plot_chifit: PyNoAppError: The wx.App object must be created first!

    Dear @newville

    I have been trying to use python (in Spyder) for path fitting. I just encountered a new (it worked yesterday) error that I could not see the plots of fitting results, but the fitting itself worked out with a ".out" file: " plot_chifit(dset, title='Ti66_fitting', rmax=6)

    File "C:\ProgramData\xrayLarch\lib\site-packages\larch\wxlib\xafsplots.py", line 683, in plot_chifit _plot(dataset.data.k, data_chik+offset, xmin=kmin, xmax=kmax,

    File "C:\ProgramData\xrayLarch\lib\site-packages\larch\wxlib\plotter.py", line 486, in _plot plotter = _getDisplay(wxparent=wxparent, win=win, size=size,

    File "C:\ProgramData\xrayLarch\lib\site-packages\larch\wxlib\plotter.py", line 339, in _getDisplay display, isnew = _get_disp(symname, creator, win, display_dict, wxparent,

    File "C:\ProgramData\xrayLarch\lib\site-packages\larch\wxlib\plotter.py", line 327, in _get_disp display = creator(window=win, wxparent=wxparent,

    File "C:\ProgramData\xrayLarch\lib\site-packages\larch\wxlib\plotter.py", line 114, in init PlotFrame.init(self, parent=None, size=size,

    File "C:\ProgramData\xrayLarch\lib\site-packages\wxmplot\plotframe.py", line 18, in init BaseFrame.init(self, parent=parent, title=title,

    File "C:\ProgramData\xrayLarch\lib\site-packages\wxmplot\baseframe.py", line 58, in init wx.Frame.init(self, parent, -1, title, **kws)

    PyNoAppError: The wx.App object must be created first!"

    Could you please help me with this?
    Thank you in advance, Best regards

    opened by duoduoss 1
  • Larch controller independent of Wx GUI + _data in _larch.symtable

    Larch controller independent of Wx GUI + _data in _larch.symtable

    @newville

    In view of having Larch more independent from the Wx GUI, and have the possibility to build more Jupyter friendly examples (or applications) I would propose the following actions:

    • [ ] create a new module larch.controller
    • [ ] move all the non-Wx part from larch.wxxas.xas_controller.XASController to larch.controller.LarchController
    • [ ] XASController will inherit from LarchController
    • [ ] assign _larch.symtable as model for LarchController
    • [ ] dedicate _larch.symtable._data as the main data container for all data groups created during a session
    • [ ] add in LarchController all the logic for handling data exchange from the model to the view (= GUI)

    Does this sounds good to you?

    enhancement 
    opened by maurov 3
Releases(0.9.65)
  • 0.9.65(Jul 5, 2022)

    [0.9.65 - 2022-07-05]

    Changed

    • LCF: eliminate combinations with very low weight (#387)
    • XAS Viewer: Add "Clear Session" menu item

    Fixed

    • XAS_Viewer/normalization: fix Y offset (#389)
    • XAS_Viewer/normalization: avoid plotting errors for "Plot Selected" with >100 Spectra selected.
    • XAS_Viewer/exafs: Make sure that E0 and Rbkg are correctly copied to other group
    • XAS_Viewer/exafs: "copy to selected" now forces re-processing of selected groups.
    • XAS_VIewer/session file: Importing of only selected groups from Session file now works properly.
    • XAS_VIewer/session file: better merging of top-level data, especially feff cache on import.
    • XAS_Viewer/Linux: better checks to avoid initialiing wx objects with 0 size.
    • better docstrings for some data/io functions, starting to use autodoc in docs.
    • doc: fix Angstrom rendering in HTML
    • doc: work toward better XAS Viewer doc.
    Source code(tar.gz)
    Source code(zip)
  • 0.9.64(Jun 22, 2022)

  • 0.9.63(Jun 20, 2022)

  • 0.9.62(Jun 8, 2022)

    bugfixes:

    • XAS_Viewer: Feff-fitting paths (and so also parameters) are refreshed for each fit (#377, #374)
    • XAS_Viewer: most main windows are now resizable (#372)
    • better checking and auto-pip-installing of wxutls and wxmplot (#376)
    Source code(tar.gz)
    Source code(zip)
  • 0.9.61(May 27, 2022)

    [0.9.61 - 2022-05-26]

    Added

    • XAS Viewer: Entries for the fit histories of pre-edge peak fitting and Feff fitting can now be erased.

    Fixed

    • XAS Viewer: the merging of groups now works ;).
    • XAS Viewer: setting and energy shift for a group will copy that shift to other groups with the same energy reference. There is a preference setting to turn off this automated copying of energy shifts.
    • XAS Viewer: fixed very slow plotting -- now just back to normal "not fast".
    • XAS Viewer: dialogs have generally better sizes.
    • XAS Viewer: fixes for plotting of Pre-edge peak fits.
    • XAS Viewer: improvements in Journal entries for some processed groups.
    • XAS Viewer: fixes for combining default and per-group configuration.
    Source code(tar.gz)
    Source code(zip)
  • 0.9.60(May 23, 2022)

    [0.9.60 - 2022-05-23]

    Release announcement

    Added

    • each Group of XAFS data will have a Journal - a list of entries with (label, value, timestamp) that will be used to record processing steps. The XAFS processing functions will write the parameters they were called with to this Journal. Users can add notes as Journal entries too.

    • XAS Viewer allows editing of program-wide Preferences, that set the default values and settings for the various analysis steps and program behavior.

    • In many windows showing analysis results, XAS Viewer supports setting the plot window number (1 through 9) so that more than one or two plot windows can be shown at a time.

    • Session-wide Project files (.larix extension) can now be saved and reloaded. These files contain essentially all the arrays for each Group of data, including Journals, processing results, and fit histories. The "processing workspaces" for pre-edge peak fitting, PCA, Linear Combinations, Regressions, and Feff fitting. These Session files can be saved/loaded by plain Python commands. When loading these into XAS Viewer, the fit histories and workspaces will be available. To allow better debugging and tracking of provenance, these Session Files include "configuration" data about the Session (python, larch version, etc) and a complete set of Larch commands for the session, though session commands are not "restored". The files are compressed and use a customized JSON encoding.

    • These Session files are now auto-saved by XAS Viewer periodically (every 15 minutes of activity, by default, and rotated so that a small number (3, by default) of the most recent auto-saved files are kept. On startup, "restore the last session" is available (Ctrl-I).

    Fixed

    • XAS Viewer PCA fixed.
    • XAS Viewer now displays how each Group was created, for example "-log(i1/i0)".
    • XAS Viewer panels have more uniform energy range settings, relative to E0, per group.
    • XAS Viewer has more consistent coloring and font sizes.
    • XAS Viewer Quit dialog now lists the last saved Session file.
    • XAS Viewer now works even harder to keep _xasgroups correct.
    • pycifrw added as a dependency from conda-forge
    • copying parameters from one group to another is much improved.
    • rebinning of EXAFS data better avoids duplicate energies.
    • a few bugs with the handling of some CIFs were improved
    • Feff calculations now default to L3 edge for Z>= 60.
    • Python 3.10 is better supported, Python 3.7 seems to still work.
    Source code(tar.gz)
    Source code(zip)
  • 0.9.59(Apr 1, 2022)

    [0.9.59 - 2022-04-01]

    Release announcement

    Added

    • Reading files from FDMNES.
    • XAS Viewer allows reading in a reference spectrum from the same file as a spectrum.
    • XAS_Viewer better supports each spectrum having an "energy reference spectrum". This can be set on reading spectra, or afterward. Recalibrating energies can propagate calibrations to spectra that share a reference.
    • XAS Viewer better supports an "energy shift" for each spectrum -- this can be copied to other spectra or "undone" to go back to the original (as read-in) data.
    • XAS Viewer: data can be deglitched while plotting in "k" space"
    • XAS Viewer: "flattened" spectra can be used for linear analysis in more places.
    • Example using Jupyter and Fe pre-edge peaks.

    Changed

    • XAS Viewer: the action of the "pin icon" for selecting points from a plot has now changed. Previously hitting the pin icon meant "use most recently clicked point on plot". Now, hitting the pin icon starts a timer which will look for mouse clicks after hitting the pin icon: a) if there are new mouse clicks on the plot, wait at least 3 seconds, and return the most recent position. b) if there are no mouse clicks after 15 seconds, return the most recent position (even before clicking on the pin)

    Fixed

    • Reading columns names from one-line header, and for files that announce as XDI but break XDI specs (say, by having >128 columns).
    • Better handling of CIFs with partial occupancy when generating feff.inp.
    • NLEG is set to 6 by default when generating feff.inp.
    • By default, hydrogen atoms are removed when generating feff.inp (XAS Viewer and cif2feff)
    • Athena project files with very long journals are better supported.
    • Some permission problems for the installation of Applications on MacOS have been avoided.
    • "get current working directory" is now tested uniformly for permission errors.
    • MapViewer: more robust and flexible search for tomographic rotation axis.
    • Fix for spec/HDF5 files with broken "scan" link.
    • XRF Display spectral fitting: faster, better guesses for parameter scales, and show filled eigenvectors (wxmplot 0.9.49)
    • MapViewer / XRF Display: much improved ADD ROIs, including pushing XRF ROIs added in XRF Display back to the list in Mapviewer.
    • MapViewer: The order of ROIs added is now preserved, including for work arrays and Abundances from XRF analysis.

    Removed

    • Plugins are now completely removed
    • 32-bit Windows is no longer supported: libraries and executables have been removed.
    • Cromer-Libermann is more deprecated and hidden (but not completely gone, yet)
    Source code(tar.gz)
    Source code(zip)
  • 0.9.58(Jan 16, 2022)

  • 0.9.57(Dec 2, 2021)

    [0.9.57 - 2021-12-02]

    Added

    • Read RIXS files from BM16 at ESRF.
    • Option --devel in GetLarch.sh to install from source.
    • xas_viewer
      • File->Save as

    Changed

    • Module rixsdata moved from larch.qtrixs to larch.io
    • Force UTF8 encoding in read_ascii
    • xas_viewer
      • File->Save overwrites by default.
      • Better deglitching dialog, including viewing data as chi(E).
      • Loading a Peak Model is now allowed at any time.
      • Default Project filenames are taken from timestamp.

    Fixed

    • Problem with yaml load in GetLarch.sh
    • Problem in interpolation with nearly repeated x values
    • Messages reporting progress when processing XRF Maps
    • Reading Athena Project files with non-ASCII characters
    Source code(tar.gz)
    Source code(zip)
  • 0.9.56(Oct 20, 2021)

  • 0.9.53(Jul 2, 2021)

    [0.9.53 - 2021-07-02]

    Fixed

    • XAS viewer
      • fixed various bugs in Spec/BLISS files importer -- silx version 0.15.2 is now required.
      • "GetLarch.sh" and "GetLarch.bat" scripts now use "miniforge", should provide faster downloads and installs.
      • fixed (hopefully) random Text controls events on startup on Windows.
      • several small improvement feffpath and feffit functions for better managing Path Parameters with lmfit

    Added

    • XAS viewer
      • Add GUI Browser for CIF Files from American Mineralogist Crystal Structure Database
      • Code for converting CIF files to feff6/8 input files, GUI form to run Feff, organize results in users .larch/feff folder
      • Feff Path Browser for import Feff.dat files from .larch/feff
      • Feffit Tab added to XAS Viewer for (1 data set) Feff Fitting, with history of fits, saving of fit script.
      • EXAFS Panel can show chi(q) data.
    Source code(tar.gz)
    Source code(zip)
  • 0.9.53rc1(Jul 2, 2021)

  • 0.9.44rc1(May 8, 2019)

  • 0.9.43rc1(Apr 28, 2019)

  • 0.9.41rc2(Jan 24, 2019)

  • 0.9.41rc1(Jan 23, 2019)

  • 0.9.41rc0000(Jan 23, 2019)

small package with utility functions for analyzing (fly) calcium imaging data

fly2p Tools for analyzing two-photon (2p) imaging data collected with Vidrio Scanimage software and micromanger. Loading scanimage data relies on scan

Hannah Haberkern 3 Dec 14, 2022
A Python Tools to imaging the shallow seismic structure

ShallowSeismicImaging Tools to imaging the shallow seismic structure, above 10 km, based on the ZH ratio measured from the ambient seismic noise, and

Xiao Xiao 9 Aug 9, 2022
Statistical Analysis 📈 focused on statistical analysis and exploration used on various data sets for personal and professional projects.

Statistical Analysis ?? This repository focuses on statistical analysis and the exploration used on various data sets for personal and professional pr

Andy Pham 1 Sep 3, 2022
DaDRA (day-druh) is a Python library for Data-Driven Reachability Analysis.

DaDRA (day-druh) is a Python library for Data-Driven Reachability Analysis. The main goal of the package is to accelerate the process of computing estimates of forward reachable sets for nonlinear dynamical systems.

null 2 Nov 8, 2021
Spaghetti: an open-source Python library for the analysis of network-based spatial data

pysal/spaghetti SPAtial GrapHs: nETworks, Topology, & Inference Spaghetti is an open-source Python library for the analysis of network-based spatial d

Python Spatial Analysis Library 203 Jan 3, 2023
🧪 Panel-Chemistry - exploratory data analysis and build powerful data and viz tools within the domain of Chemistry using Python and HoloViz Panel.

???? ??. The purpose of the panel-chemistry project is to make it really easy for you to do DATA ANALYSIS and build powerful DATA AND VIZ APPLICATIONS within the domain of Chemistry using using Python and HoloViz Panel.

Marc Skov Madsen 97 Dec 8, 2022
Python data processing, analysis, visualization, and data operations

Python This is a Python data processing, analysis, visualization and data operations of the source code warehouse, book ISBN: 9787115527592 Descriptio

FangWei 1 Jan 16, 2022
A library to create multi-page Streamlit applications with ease.

A library to create multi-page Streamlit applications with ease.

Jackson Storm 107 Jan 4, 2023
Data Intelligence Applications - Online Product Advertising and Pricing with Context Generation

Data Intelligence Applications - Online Product Advertising and Pricing with Context Generation Overview Consider the scenario in which advertisement

Manuel Bressan 2 Nov 18, 2021
A set of functions and analysis classes for solvation structure analysis

SolvationAnalysis The macroscopic behavior of a liquid is determined by its microscopic structure. For ionic systems, like batteries and many enzymes,

MDAnalysis 19 Nov 24, 2022
Sensitivity Analysis Library in Python (Numpy). Contains Sobol, Morris, Fractional Factorial and FAST methods.

Sensitivity Analysis Library (SALib) Python implementations of commonly used sensitivity analysis methods. Useful in systems modeling to calculate the

SALib 663 Jan 5, 2023
PCAfold is an open-source Python library for generating, analyzing and improving low-dimensional manifolds obtained via Principal Component Analysis (PCA).

PCAfold is an open-source Python library for generating, analyzing and improving low-dimensional manifolds obtained via Principal Component Analysis (PCA).

Burn Research 4 Oct 13, 2022
HyperSpy is an open source Python library for the interactive analysis of multidimensional datasets

HyperSpy is an open source Python library for the interactive analysis of multidimensional datasets that can be described as multidimensional arrays o

HyperSpy 411 Dec 27, 2022
Tablexplore is an application for data analysis and plotting built in Python using the PySide2/Qt toolkit.

Tablexplore is an application for data analysis and plotting built in Python using the PySide2/Qt toolkit.

Damien Farrell 81 Dec 26, 2022
A data analysis using python and pandas to showcase trends in school performance.

A data analysis using python and pandas to showcase trends in school performance. A data analysis to showcase trends in school performance using Panda

Jimmy Faccioli 0 Sep 7, 2021
A collection of learning outcomes data analysis using Python and SQL, from DQLab.

Data Analyst with PYTHON Data Analyst berperan dalam menghasilkan analisa data serta mempresentasikan insight untuk membantu proses pengambilan keputu

null 6 Oct 11, 2022
Driver Analysis with Factors and Forests: An Automated Data Science Tool using Python

Driver Analysis with Factors and Forests: An Automated Data Science Tool using Python ??

Thomas 2 May 26, 2022
Project: Netflix Data Analysis and Visualization with Python

Project: Netflix Data Analysis and Visualization with Python Table of Contents General Info Installation Demo Usage and Main Functionalities Contribut

Kathrin Hälbich 2 Feb 13, 2022