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

Cookiecutting - mod files 1 #12

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 29 additions & 5 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,34 @@
# show coverage in CI status, not as a comment.
comment: off
# codecov can find this file anywhere in the repo, so we don't need to clutter
# the root folder.
#comment: false

codecov:
notify:
require_ci_to_pass: no

coverage:
status:
project:
default:
target: auto
patch:
default:
target: '70'
if_no_uploads: error
if_not_found: success
if_ci_failed: failure
project:
default: false
library:
target: auto
if_no_uploads: error
if_not_found: success
if_ci_failed: error
paths: '!*/tests/.*'

tests:
target: 97.9%
paths: '*/tests/.*'
if_not_found: success

flags:
tests:
paths:
- tests/
2 changes: 1 addition & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[run]
source =
fourigui
diffpy.fourigui
[report]
omit =
*/python?.?/*
Expand Down
2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1 @@
fourigui/_version.py export-subst
diffpy.fourigui/_version.py export-subst
27 changes: 22 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ venv/
*.egg-info/
.installed.cfg
*.egg
bin/
temp/
tags/
errors.err

# PyInstaller
# Usually these files are written by a python script from a template
Expand All @@ -34,6 +38,7 @@ venv/
# Installer logs
pip-log.txt
pip-delete-this-directory.txt
MANIFEST

# Unit test / coverage reports
htmlcov/
Expand All @@ -50,6 +55,11 @@ coverage.xml
*.mo
*.pot

# Mr Developer
.mr.developer.cfg
.project
.pydevproject

# Django stuff:
*.log

Expand All @@ -64,19 +74,26 @@ docs/source/generated/
target/

# Editor files
#mac
# mac
.DS_Store
*~

#vim
# vim
*.swp
*.swo

#pycharm
# pycharm
.idea/

#VSCode
# VSCode
.vscode/

#Ipython Notebook
# Ipython Notebook
.ipynb_checkpoints

# version information
setup.cfg
/src/diffpy/*/version.cfg

# Rever
rever/
17 changes: 7 additions & 10 deletions AUTHORS.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
Authors
=======

The main contributors to the diffpy.fourigui software is:

Sani Harouna-Mayer

Billinge Group and community contributors.

This project was much improved by testing, feedback and suggestions
from the Billinge-group members at the Applied Physics and Applied
Mathematics Department of the Columbia University in New York and
Expand All @@ -11,23 +15,16 @@ at the Brookhaven National Laboratory.

For more information about diffpy.fourigui email [email protected].


=======
Credits
=======

- Zach Thatcher
- Connor Bracy
- Silvio Achilles
- Ludwig Hendl

=======

Maintainer
----------

* diffpy <[email protected]>

Contributors
------------

None yet. Why not be the first? See: CONTRIBUTING.rst
For a list of contributors, visit
https://github.com/{{ cookiecutter.github_org }}/{{ cookiecutter.repo_name }}/graphs/contributors
161 changes: 100 additions & 61 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,100 +1,139 @@
========
diffpy.fourigui
========
|Icon| |title|_
===============

.. image:: https://img.shields.io/travis/sbillinge/fourigui.svg
:target: https://travis-ci.org/sbillinge/fourigui
.. |title| replace:: diffpy.fourigui
.. _title: https://diffpy.github.io/fourigui

.. image:: https://img.shields.io/pypi/v/fourigui.svg
:target: https://pypi.python.org/pypi/fourigui
.. |Icon| image:: https://avatars.githubusercontent.com/diffpy
:target: https://diffpy.github.io/fourigui
:height: 100px

|PyPi| |Forge| |PythonVersion| |PR|

* Free software: 3-clause BSD license
* Documentation: (COMING SOON!) https://sbillinge.github.io/fourigui.
|CI| |Codecov| |Black| |Tracking|

========================================================================
#TODO insert desciptions
{{Fourigui is an interactive visualization tool with an embedded Fourier transformation functionality, designed to process 3D reciprocal space scattering volumes to 3D atomic pair distribution functions (3D PDFs).}}
.. |Black| image:: https://img.shields.io/badge/code_style-black-black
:target: https://github.com/psf/black

{{Fourigui is a tool to visualize and process 3D data sets written with the python programming language. Fourigui always displays one slice perpendicular to one axis and allows scrolling through the 3D data set along the given axis with a slider. It shows feedback values such as global and local maxima, minima or NAN ratios. The matplotlib panel e.g. for zooming and saving figures is featured.
Fourigui is designed for the processing of 3D atomic pair distribution functions (PDFs). One can load a 3D reciprocal space scattering volume which can be Fourier transformed to the 3D PDF. Thereby, one can apply cut off frequencies beyond and below given Q values, compare the results and switch between the scattering volume in reciprocal space and 3D PDF in real space.
}}
#TODO add docs to website?
To learn more about diffpy.{{cookiecutter.package_name}} library see the
user manual at http://diffpy.github.io/diffpy.{{cookiecutter.package_name}}.
.. |CI| image:: https://github.com/diffpy/fourigui/actions/workflows/main.yml/badge.svg
:target: https://github.com/diffpy/fourigui/actions/workflows/main.yml

REQUIREMENTS
------------------------------------------------------------------------
.. |Codecov| image:: https://codecov.io/gh/diffpy/fourigui/branch/main/graph/badge.svg
:target: https://codecov.io/gh/diffpy/fourigui

The diffpy.fourigui package requires Python 3.5 or later or 2.7 and
.. |Forge| image:: https://img.shields.io/conda/vn/conda-forge/diffpy.fourigui
:target: https://anaconda.org/conda-forge/diffpy.fourigui

.. |PR| image:: https://img.shields.io/badge/PR-Welcome-29ab47ff

.. |PyPi| image:: https://img.shields.io/pypi/v/diffpy.fourigui
:target: https://pypi.org/project/diffpy.fourigui/

.. |PythonVersion| image:: https://img.shields.io/pypi/pyversions/diffpy.fourigui
:target: https://pypi.org/project/diffpy.fourigui/

.. |Tracking| image:: https://img.shields.io/badge/issue_tracking-github-blue
:target: https://github.com/diffpy/fourigui/issues

Tool for visualizing 3D diffraction and PDF Images

Fourigui is an interactive visualization tool with an embedded Fourier transformation functionality, designed to
process 3D reciprocal space scattering volumes to 3D atomic pair distribution functions (3D PDFs).

Fourigui is a tool to visualize and process 3D data sets written with the python programming language. Fourigui always
displays one slice perpendicular to one axis and allows scrolling through the 3D data set along the given axis with a
slider. It shows feedback values such as global and local maxima, minima or NAN ratios. The matplotlib panel e.g. for
zooming and saving figures is featured. Fourigui is designed for the processing of 3D atomic pair distribution
functions (PDFs). One can load a 3D reciprocal space scattering volume which can be Fourier transformed to the 3D PDF.
Thereby, one can apply cut off frequencies beyond and below given Q values, compare the results and switch between the
scattering volume in reciprocal space and 3D PDF in real space.


For more information about the diffpy.fourigui library, please consult our `online documentation <https://diffpy.github.io/fourigui>`_.

Citation
--------
If you use diffpy.fourigui in a scientific publication, we would like you to cite this package as

diffpy.fourigui Package, https://github.com/diffpy/fourigui

Installation
------------
The diffpy.fourigui package requires Python 3.10 or later and
the following software:

* ``matplotlib`` - graphing tool
* ``Scipy`` - scientific computing tool for python
* ``h5py`` - pythonic interface to the HDF5 binary data format

The preferred method is to use `Miniconda Python
<https://docs.conda.io/projects/miniconda/en/latest/miniconda-install.html>`_
and install from the "conda-forge" channel of Conda packages.

We recommend to use `Anaconda Python <https://www.anaconda.com/download>`_
as it allows to install all software dependencies together with
diffpy.fourigui. For other Python distributions it is necessary to
install the required software separately. As an example on Ubuntu
Linux the required software can be installed with ::
To add "conda-forge" to the conda channels, run the following in a terminal. ::

sudo get-apt install python3-matplotlib python3-Scipy python3-h5py
conda config --add channels conda-forge

We want to install our packages in a suitable conda environment.
The following creates and activates a new environment named ``diffpy.fourigui_env`` ::

INSTALLATION
------------------------------------------------------------------------
conda create -n diffpy.fourigui_env python=3
conda activate diffpy.fourigui_env

The preferred method is to use Anaconda Python and install from the
"conda-forge" channel of Anaconda packages ::
Then, to fully install ``diffpy.fourigui`` in our active environment, run ::

conda config --add channels conda-forge
conda install diffpy.fourigui
conda install diffpy.fourigui

Another installation option is to use ``easy_install`` to download and
install the latest release from
`Python Package Index <https://pypi.python.org>`_ ::
Another option is to use ``pip`` to download and install the latest release from
`Python Package Index <https://pypi.python.org>`_.
To install using ``pip`` into your ``diffpy.fourigui_env`` environment, we will also have to install dependencies ::

pip install diffpy.fourigui
pip install -r https://raw.githubusercontent.com/diffpy/fourigui/main/requirements/run.txt

If you prefer to install from sources, navigate to the source archive
directory and run ::
and then install the package ::

python setup.py install
pip install diffpy.fourigui

You may need to use ``sudo`` with system Python so it is allowed to
copy files to system directories. If sudo is not available, check
the usage info from ``python setup.py install --help`` for options to
install to user-writable locations.
If you prefer to install from sources, after installing the dependencies, obtain the source archive from
`GitHub <https://github.com/diffpy/fourigui/>`_. Once installed, ``cd`` into your ``fourigui`` directory
and run the following ::

pip install .

DEVELOPMENT
------------------------------------------------------------------------

Support and Contribute
----------------------
diffpy.fourigui is an open-source software developed as a part of the
DiffPy-CMI complex modeling initiative at the Brookhaven National
Laboratory. The diffpy.{{cookiecutter.package_name}} sources are hosted at
https://github.com/diffpy/diffpy.fourigui.
Laboratory.

`Diffpy user group <https://groups.google.com/g/diffpy-users>`_ is the discussion forum for general questions and discussions about the use of diffpy.fourigui. Please join the diffpy.fourigui users community by joining the Google group. The diffpy.fourigui project welcomes your expertise and enthusiasm!

If you see a bug or want to request a feature, please `report it as an issue <https://github.com/diffpy/fourigui/issues>`_ and/or `submit a fix as a PR <https://github.com/diffpy/fourigui/pulls>`_. You can also post it to the `Diffpy user group <https://groups.google.com/g/diffpy-users>`_.

Feel free to fork the project and contribute. To install diffpy.structure
in a development mode, where the sources are directly used by Python
rather than copied to a system directory, use ::
Feel free to fork the project and contribute. To install diffpy.fourigui
in a development mode, with its sources being directly used by Python
rather than copied to a package directory, use the following in the root
directory ::

python setup.py develop --user
pip install -e .

To ensure code quality and to prevent accidental commits into the default branch, please set up the use of our pre-commit
hooks.

ACKNOWLEDGEMENT
------------------------------------------------------------------------
1. Install pre-commit in your working environment by running ``conda install pre-commit``.

{{cookiecutter.acknowledgements}}
2. Initialize pre-commit (one time only) ``pre-commit install``.

Thereafter your code will be linted by black and isort and checked against flake8 before you can commit.
If it fails by black or isort, just rerun and it should pass (black and isort will modify the files so should
pass after they are modified). If the flake8 test fails please see the error messages and fix them manually before
trying to commit again.

CONTACTS
------------------------------------------------------------------------
Improvements and fixes are always appreciated.

For more information on diffpy.structure please visit the project web-page
Before contribuing, please read our `Code of Conduct <https://github.com/diffpy/fourigui/blob/main/CODE_OF_CONDUCT.rst>`_.

http://www.diffpy.org/
Contact
-------

or email Prof. Simon Billinge at [email protected].
For more information on diffpy.fourigui please visit the project `web-page <https://diffpy.github.io/>`_ or email Prof. Simon Billinge at [email protected].
Loading