Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
37 changed files
with
10,508 additions
and
4,599 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,3 +14,5 @@ __pycache__/ | |
/xrdfit/test.py | ||
/xrdfit.egg-info | ||
/example_data/example_data_large/ | ||
/build | ||
/dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Contributing | ||
|
||
We welcome bug reports, feature requests and suggestions for improvement made to this package. Below are some guidelines to keep in mind when requesting or making changes. | ||
|
||
## Reporting Issues | ||
|
||
If you encounter a problem with the code, please open an issue on the project's GitHub issue board: https://github.com/LightForm-group/xrdfit/issues | ||
|
||
You should include details about what version of ``xrdfit`` you are using, what you are attempting to do, details of the error you encountered and if possible a [minimal working example](https://en.wikipedia.org/wiki/Minimal_working_example) that shows the problem. | ||
|
||
## Coding style | ||
|
||
This project uses the PEP8 standard for formatting Python code with the exception that the maximum line length is 120 characters. | ||
|
||
Docstrings are formatted in the reStructuredText format. These are automatically harvested by the Sphinx autodoc extension and form the API documentation at Read The Docs: (https://xrdfit.readthedocs.io/en/latest/) | ||
|
||
## Release guidelines | ||
|
||
Releases follow the [semver](https://semver.org/) numbering scheme. | ||
|
||
When releasing a new version the following need to be updated: | ||
* Update version number in setup.py | ||
* Update version number in docs/config.py | ||
* Add tag to git repo of the version number prefixed by the letter “v” | ||
* Draft release on GitHub for that tag with a list of changes since the last version | ||
* Upload new version to PyPi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,45 @@ | ||
[![PyPI version](https://badge.fury.io/py/xrdfit.svg)](https://badge.fury.io/py/xrdfit) | ||
[![Documentation Status](https://readthedocs.org/projects/xrdfit/badge/?version=latest)](https://xrdfit.readthedocs.io/en/latest/?badge=latest) | ||
[![DOI](https://zenodo.org/badge/203145007.svg)](https://zenodo.org/badge/latestdoi/203145007) | ||
|
||
Introduction | ||
-------------- | ||
|
||
xrdfit is a Python module for fitting the peaks found in shallow x-ray diffraction spectra. It is designed to be an easy to use tool for quick analysis of spectra. Features are included for automating fitting over many spectra to enable tracking of peaks as they shift through the experiment. xrdfit uses the Python module lmfit for the underlying fitting. xrdfit is designed to be accessible for all researchers who need to process SXRD spectra and so does not require a detailed knowledge of programming or fitting. | ||
|
||
Installation | ||
------------- | ||
|
||
To install as a Python module, type | ||
|
||
`python -m pip install .` | ||
`python -m pip install xrdfit` | ||
|
||
from the root directory. | ||
For developers, you should install in linked .egg mode using | ||
|
||
`python -m pip install -e .` | ||
|
||
If you are using a Python virtual environment, you should activate this first before using the above commands. | ||
If you are using a Python virtual environment, you should activate this first before using the above commands. | ||
|
||
Documentation | ||
--------------- | ||
Documentation including an API reference is provided at: https://xrdfit.readthedocs.io/en/latest/ | ||
|
||
The majority of the documentation is provided as example driven interactive Jupyter notebooks. These are included along with the source code in the "tutorial notebooks" folder. | ||
If this package was downloaded from pip, the source can be found on GitHub: https://github.com/LightForm-group/xrdfit | ||
|
||
|
||
Required libraries | ||
-------------------- | ||
|
||
This module uses the Python libraries: | ||
* NumPy (https://numpy.org/) | ||
* matplotlib (https://matplotlib.org/) | ||
* pandas (https://pandas.pydata.org/) | ||
* dill (https://pypi.org/project/dill/) | ||
* tqdm (https://tqdm.github.io/) | ||
* SciPy (https://www.scipy.org/) | ||
* lmfit (https://lmfit.github.io/lmfit-py/) | ||
|
||
The following libraries are required to use the tutorial documentation workbooks: | ||
* Jupyter (https://jupyter.org/) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,53 @@ | ||
.. xrdfit documentation master file, created by | ||
sphinx-quickstart on Mon Dec 16 15:47:29 2019. | ||
You can adapt this file completely to your liking, but it should at least | ||
contain the root `toctree` directive. | ||
xrdfit documentation | ||
====================== | ||
|
||
Welcome to xrdfit's documentation! | ||
================================== | ||
``xrdfit`` is a Python package for fitting the diffraction peaks in synchrotron X-ray diffraction (SXRD) and XRD spectra. It is intended as an easy to use tool for the quick analysis of individual and overlapping lattice plane peaks, to quantify the peak positions and profiles. ``xrdfit`` uses the Python package `lmfit <https://lmfit.github.io/lmfit-py/>`_ for the underlying fitting. Features are included for selecting different 'cakes' of data and automating fitting over many spectra, to enable tracking of peaks as they shift throughout the experiment. ``xrdfit`` is designed to be used by experimental researchers who need to process SXRD spectra but do not have a detailed knowledge of programming or fitting. | ||
|
||
|
||
Installation | ||
============== | ||
|
||
``xrdfit`` is compatible with Python 3.6+. | ||
|
||
Use :command:`pip` to install the latest stable version of ``xrdfit``: | ||
|
||
.. code-block:: console | ||
pip install xrdfit | ||
The current development version is available on `github | ||
<https://github.com/LightForm-group/xrdfit>`__. To install use: | ||
|
||
.. code-block:: console | ||
git clone --branch develop https://github.com/LightForm-group/xrdfit | ||
cd xrdfit | ||
python -m pip install . | ||
.. toctree:: | ||
:maxdepth: 2 | ||
:caption: Contents: | ||
Getting started | ||
================ | ||
|
||
This documentation is primarily an API reference, auto-generated from the docstrings in the source code. | ||
|
||
Indices and tables | ||
================== | ||
The primary source of documentation for new users is a series of tutorial Jupyter Notebooks which are included with the source code. | ||
|
||
The source and notebooks are available on the project’s GitHub page: `<https://github.com/LightForm-group/xrdfit>`_ | ||
|
||
|
||
Acknowledgements | ||
================= | ||
|
||
This project was developed at the `University of Manchester <https://www.manchester.ac.uk/>`_ with funding from the UK's Engineering and Physical Sciences Research Council (EPSRC) `LightForm <https://lightform.org.uk/>`_ grant: `(EP/R001715/1) <https://gow.epsrc.ukri.org/NGBOViewGrant.aspx?GrantRef=EP/R001715/1>`_. | ||
|
||
|
||
API Reference | ||
=============== | ||
|
||
.. toctree:: | ||
:maxdepth: 3 | ||
|
||
modules | ||
|
||
* :ref:`genindex` | ||
* :ref:`modindex` | ||
* :ref:`search` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.