Skip to content

Commit

Permalink
Merge pull request #659 from hakonanes/release-0.9.0
Browse files Browse the repository at this point in the history
Prepare release of version 0.9.0
  • Loading branch information
hakonanes committed Nov 3, 2023
2 parents b7aa2eb + 977887d commit 9b76c65
Show file tree
Hide file tree
Showing 80 changed files with 2,826 additions and 4,192 deletions.
21 changes: 20 additions & 1 deletion .all-contributorsrc
Expand Up @@ -65,7 +65,8 @@
"profile": "https://github.com/ericpre",
"contributions": [
"code",
"maintenance"
"maintenance",
"bug"
]
},
{
Expand Down Expand Up @@ -97,6 +98,24 @@
"contributions": [
"bug"
]
},
{
"login": "AndreasBugten",
"name": "AndreasBugten",
"avatar_url": "https://avatars.githubusercontent.com/u/106192446?v=4",
"profile": "https://github.com/AndreasBugten",
"contributions": [
"doc"
]
},
{
"login": "CSSFrancis",
"name": "Carter Francis",
"avatar_url": "https://avatars.githubusercontent.com/u/41125831?v=4",
"profile": "https://github.com/CSSFrancis",
"contributions": [
"doc"
]
}
]
}
4 changes: 2 additions & 2 deletions .github/pull_request_template.md
Expand Up @@ -3,9 +3,9 @@


#### Progress of the PR
- [ ] [Docstrings for all functions](https://github.com/numpy/numpy/blob/master/doc/example.py)
- [ ] [Docstrings for all functions](https://numpydoc.readthedocs.io/en/latest/example.html)
- [ ] Unit tests with pytest for all lines
- [ ] Clean code style by [running black via pre-commit](https://kikuchipy.org/en/latest/contributing.html#code-style)
- [ ] Clean code style by [running black via pre-commit](https://kikuchipy.org/en/latest/dev/code_style.html)

#### Minimal example of the bug fix or new feature
```python
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/perhaps_make_tagged_release_draft.py
Expand Up @@ -47,7 +47,7 @@
changelog_end = i - 1
with open("release_part_in_changelog.rst", mode="w") as f:
f.write(
"kikuchipy is an open-source Python library for processing and analysis of electron backscatter diffraction (EBSD) patterns.\n\n"
"kikuchipy is an open-source Python library for processing, simulating and indexing of electron backscatter diffraction (EBSD) patterns.\n\n"
f"See below, the `changelog <https://kikuchipy.org/en/stable/changelog.html>`_ or the `GitHub changelog <https://github.com/pyxem/kikuchipy/compare/v{pypi_version}...v{branch_version}>`_ for all updates from the previous release.\n\n"
)
for line in content[changelog_start:changelog_end]:
Expand Down
25 changes: 16 additions & 9 deletions .github/workflows/perhaps_make_tagged_release_draft.yml
Expand Up @@ -14,35 +14,42 @@ jobs:
make-tagged-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: r-lib/actions/setup-pandoc@v1
- uses: actions/checkout@v3

- uses: r-lib/actions/setup-pandoc@v2

- name: Set up Python ${{ runner.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install outdated
- name: Check whether a tagged release draft should be made
run: |
cd .github/workflows
eval x=($(python perhaps_make_tagged_release_draft.py))
echo "MAKE_RELEASE=${x[0]}" >> $GITHUB_ENV
echo "PYPI_VERSION=${x[1]}" >> $GITHUB_ENV
echo "BRANCH_VERSION=${x[2]}" >> $GITHUB_ENV
- name: Make tagged release draft body from changelog
if: ${{ env.MAKE_RELEASE == 'true' }}
run: pandoc .github/workflows/release_part_in_changelog.rst -f rst -t markdown -o release_part_in_changelog.md --wrap=none
run: |
pandoc .github/workflows/release_part_in_changelog.rst -f rst -t markdown -o release_part_in_changelog.md --wrap=none
- name: Make tagged release draft
if: ${{ env.MAKE_RELEASE == 'true' }}
uses: actions/create-release@v1
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
draft: true
tag_name: v${{ env.BRANCH_VERSION }}
release_name: kikuchipy ${{ env.BRANCH_VERSION }}
commitish: main
body_path: release_part_in_changelog.md
draft: true
prerelease: false
name: kikuchipy ${{ env.BRANCH_VERSION }}
tag_name: v${{ env.BRANCH_VERSION }}
target_commitish: main
16 changes: 7 additions & 9 deletions .github/workflows/publish.yml
Expand Up @@ -20,11 +20,14 @@ on:
jobs:
upload:
runs-on: ubuntu-latest
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.x'

Expand All @@ -38,15 +41,10 @@ jobs:
python -m build
- name: Publish package to TestPyPI
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
uses: pypa/gh-action-pypi-publish@release/v1
continue-on-error: true
with:
user: __token__
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/

- name: Publish package to PyPI
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
uses: pypa/gh-action-pypi-publish@release/v1
28 changes: 15 additions & 13 deletions .github/workflows/test_documentation_notebooks.yml
Expand Up @@ -6,30 +6,32 @@ on:
workflow_dispatch:
workflow: "*"

env:
MPLBACKEND: agg

jobs:
test-documentation-notebooks:
runs-on: ubuntu-latest
timeout-minutes: 30
env:
MPLBACKEND: agg
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Set up Python 3.9
uses: actions/setup-python@v2
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Display versions
run: |
python -V
pip -V
python-version: '3.11'

- name: Install package and dependencies
shell: bash
run: |
pip install -U -e .'[doc,tests,viz]'
pip install nbval
pip install -U -e .'[doc,tests,all]'
pip install -U nbval pyopencl
- name: Display Python, pip and package versions
run: |
python -V
pip -V
pip list
- name: Test documentation notebooks
run: |
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/tests.yml
Expand Up @@ -10,9 +10,6 @@ on:
workflow_dispatch:
workflow: '*'

env:
MPLBACKEND: agg

jobs:
code:
name: code style
Expand All @@ -39,7 +36,7 @@ jobs:

- uses: actions/setup-python@v4
with:
python-version: '3.10'
python-version: '3.11'

- name: Install dependencies
run: |
Expand All @@ -53,18 +50,21 @@ jobs:
name: ${{ matrix.os }}-py${{ matrix.python-version }}${{ matrix.LABEL }}
runs-on: ${{ matrix.os }}
timeout-minutes: 15
env:
MPLBACKEND: agg
PYTEST_ARGS: --pyargs kikuchipy --reruns 2 -n 2 --cov=kikuchipy
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: [3.9, '3.10']
python-version: ['3.10', '3.11']
include:
- os: ubuntu-latest
python-version: 3.7
DEPENDENCIES: dask==2021.8.1 diffsims==0.5.0 hyperspy==1.7.3 matplotlib==3.3 numba==0.55 numpy==1.19 orix==0.11.1 scikit-image==0.16.2
DEPENDENCIES: dask==2021.8.1 diffsims==0.5.1 hyperspy==1.7.3 matplotlib==3.5 numba==0.55 numpy==1.21.6 orix==0.11.1 pooch==1.3.0 pyebsdindex==0.2 scikit-image==0.16.2
LABEL: -oldest
- os: ubuntu-latest
python-version: 3.10
python-version: 3.11
LABEL: -minimum_requirement
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -120,12 +120,12 @@ jobs:
run: |
sudo apt-get update
sudo apt-get install xvfb
xvfb-run pytest -n 2 --cov=kikuchipy --pyargs kikuchipy
xvfb-run pytest ${{ env.PYTEST_ARGS }}
- name: Run tests on Windows and macOS
- name: Run tests on Windows or macOS
if: ${{ matrix.os != 'ubuntu-latest' }}
run: |
pytest -n 2 --cov=kikuchipy --pyargs kikuchipy
pytest ${{ env.PYTEST_ARGS }}
- name: Generate line coverage
run: |
Expand Down
12 changes: 11 additions & 1 deletion .zenodo.json
Expand Up @@ -6,7 +6,7 @@
"affiliation": "Norwegian University of Science and Technology"
},
{
"name": "Lars Lervik"
"name": "Lars Andreas Hastad Lervik"
},
{
"name": "Ole Natlandsmyr"
Expand All @@ -19,6 +19,11 @@
{
"name": "Eric Prestat"
},
{
"name": "Andreas V. Bugten",
"orcid": "0000-0003-0311-8584",
"affiliation": "Norwegian University of Science and Technology"
},
{
"name": "Erlend Mikkelsen Østvold",
"affiliation": "Norwegian University of Science and Technology"
Expand All @@ -27,6 +32,11 @@
"name": "Zhou Xu",
"affiliation": "Monash Centre for Electron Microscopy"
},
{
"name": "Carter Francis",
"orcid": "0000-0003-2564-1851",
"affiliation": "University of Wisconsin Madison"
},
{
"name": "Magnus Nord",
"orcid": "0000-0001-7981-5293",
Expand Down
61 changes: 58 additions & 3 deletions CHANGELOG.rst
Expand Up @@ -13,6 +13,63 @@ its best to adhere to `Semantic Versioning <https://semver.org/spec/v2.0.0.html>
List entries are sorted in descending chronological order. Contributors to each release
were listed in alphabetical order by first name until version 0.7.0.

0.9.0 (2023-11-03)
==================

Added
-----
- Explicit support for Python 3.11.
(`#646 <https://github.com/pyxem/kikuchipy/pull/646>`_)
- Allow Hough indexing of all Laue groups with PyEBSDIndex v0.2 (not just *m-3m*, i.e.
FCC and BCC). (`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)
- Control of reflector lists in Hough indexing. One reflector list per phase in the
phase list can be passed to ``EBSDDetector.get_indexer()`` to obtain an
``EBSDIndexer`` for use in ``EBSD.hough_indexing()``.
(`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)
- Allow passing keyword arguments to ``EBSD.hough_indexing_optimize_pc()`` to control
the new particle swarm optimization algorithm in PyEBSDIndex v0.2.
(`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)
- Allow getting one projection center (PC) per pattern when optimizing PCs using the new
particle swarm optimization in PyEBSDIndex v0.2 (passing ``batch=True``).
(`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)

Changed
-------
- Parameter ``zone_axes_kwargs`` in
``GeometricalKikuchiPatternSimulation.as_collections()`` does not accept ``color``
internally to set the default color to white anymore. It accepts ``fc`` (facecolor)
instead. This change was necessary to improve handling of other keyword arguments.
(`#643 <https://github.com/pyxem/kikuchipy/pull/643>`_)
- Increase minimal versions of diffsims, NumPy, Matplotlib, and PyEBSDIndex to 0.5.1,
1.21.6, 3.5, and 0.2, respectively.
(`#646 <https://github.com/pyxem/kikuchipy/pull/646>`_,
`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)
- Remove dependency on Panel for documentation, and with that the interactive 3D
visualization of master patterns in the documentation. The plan is to reintroduce the
interactive plots with trame later on.
(`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)
- Restrict HyperSpy to below the forthcoming version 2. The plan is to remove this
restriction once kikuchipy is compatible with this version.
(`#657 <https://github.com/pyxem/kikuchipy/pull/657>`_)

Removed
-------
- ``generators`` and ``projections`` modules which were deprecated in version 0.8.
(`#612 <https://github.com/pyxem/kikuchipy/pull/612>`_)
- The deprecated PyPI selector ``viz`` is removed.
(`#643 <https://github.com/pyxem/kikuchipy/pull/643>`_)
- The data module functions ``silicon_ebsd_moving_screen_x()``, where "x" is "in",
"out5mm" or "out10mm". They were deprecated in version 0.8.
(`#656 <https://github.com/pyxem/kikuchipy/pull/656>`_)

Fixed
-----
- Conversion from EDAX TSL projection center (PC) convention for (PCy, PCz) for
rectangular detectors is corrected.
(`#652 <https://github.com/pyxem/kikuchipy/pull/652>`_)
- Downloading files in the ``data`` module to the local cache on Windows.
(`#655 <https://github.com/pyxem/kikuchipy/pull/655>`_)

0.8.7 (2023-07-24)
==================

Expand Down Expand Up @@ -187,7 +244,7 @@ Added

Changed
-------
- Minimal version of orix set to >= 0.11 and of numba set to >= 0.55.
- Minimal version of orix set to >= 0.11 and of Numba set to >= 0.55.
(`#608 <https://github.com/pyxem/kikuchipy/pull/608>`_)
- Added warnings when trying to perform adaptive histogram equalization on a signal with
data in floating type or when some of the data is NaN.
Expand All @@ -206,8 +263,6 @@ Changed
(`#588 <https://github.com/pyxem/kikuchipy/pull/588>`_)
- Minimal version of HyperSpy increased to >= 1.7.3.
(`#585 <https://github.com/pyxem/kikuchipy/pull/585>`_)
- Minimal version of Numba increased to >= 0.52.
(`#585 <https://github.com/pyxem/kikuchipy/pull/585>`_)
- When binning the navigation dimension(s) with ``EBSD.rebin()``, the class attributes
``xmap`` and ``static_background`` are set to ``None`` and ``detector.pc`` is set to
``[0.5, 0.5, 0.5]`` in the appropriate navigation shape. If the signal dimension(s)
Expand Down

0 comments on commit 9b76c65

Please sign in to comment.