napari-aft 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- napari_aft-0.1.0/.github/ISSUE_TEMPLATE/bug_report.yml +87 -0
- napari_aft-0.1.0/.github/ISSUE_TEMPLATE/documentation.md +11 -0
- napari_aft-0.1.0/.github/ISSUE_TEMPLATE/feature_request.md +27 -0
- napari_aft-0.1.0/.github/ISSUE_TEMPLATE/task.md +11 -0
- napari_aft-0.1.0/.github/PULL_REQUEST_TEMPLATE.md +12 -0
- napari_aft-0.1.0/.github/dependabot.yml +17 -0
- napari_aft-0.1.0/.github/workflows/test_and_deploy.yml +102 -0
- napari_aft-0.1.0/.gitignore +93 -0
- napari_aft-0.1.0/.pre-commit-config.yaml +20 -0
- napari_aft-0.1.0/CITATION.cff +13 -0
- napari_aft-0.1.0/LICENSE +58 -0
- napari_aft-0.1.0/PKG-INFO +140 -0
- napari_aft-0.1.0/README.md +92 -0
- napari_aft-0.1.0/docs/img/overview.png +0 -0
- napari_aft-0.1.0/docs/img/scan.png +0 -0
- napari_aft-0.1.0/docs/make_screenshots.py +92 -0
- napari_aft-0.1.0/docs/usage.md +361 -0
- napari_aft-0.1.0/docs/video/actin_live_frame90.png +0 -0
- napari_aft-0.1.0/docs/video/common.py +182 -0
- napari_aft-0.1.0/docs/video/explainer_vtt.py +48 -0
- napari_aft-0.1.0/docs/video/make_video.py +58 -0
- napari_aft-0.1.0/docs/video/scene_closing.py +22 -0
- napari_aft-0.1.0/docs/video/scene_direction.py +111 -0
- napari_aft-0.1.0/docs/video/scene_fourier.py +343 -0
- napari_aft-0.1.0/docs/video/scene_grid.py +149 -0
- napari_aft-0.1.0/docs/video/scene_intro.py +133 -0
- napari_aft-0.1.0/docs/video/scene_order.py +173 -0
- napari_aft-0.1.0/docs/video/voiceover.py +128 -0
- napari_aft-0.1.0/docs/video/walkthrough.py +538 -0
- napari_aft-0.1.0/pyproject.toml +160 -0
- napari_aft-0.1.0/setup.cfg +4 -0
- napari_aft-0.1.0/src/napari_aft/__init__.py +12 -0
- napari_aft-0.1.0/src/napari_aft/_layers.py +450 -0
- napari_aft-0.1.0/src/napari_aft/_sample_data.py +90 -0
- napari_aft-0.1.0/src/napari_aft/_version.py +24 -0
- napari_aft-0.1.0/src/napari_aft/_viewport.py +61 -0
- napari_aft-0.1.0/src/napari_aft/_widget/__init__.py +18 -0
- napari_aft-0.1.0/src/napari_aft/_widget/batch.py +339 -0
- napari_aft-0.1.0/src/napari_aft/_widget/events.py +49 -0
- napari_aft-0.1.0/src/napari_aft/_widget/form.py +341 -0
- napari_aft-0.1.0/src/napari_aft/_widget/input.py +311 -0
- napari_aft-0.1.0/src/napari_aft/_widget/parameters.py +413 -0
- napari_aft-0.1.0/src/napari_aft/_widget/plots.py +148 -0
- napari_aft-0.1.0/src/napari_aft/_widget/preview.py +179 -0
- napari_aft-0.1.0/src/napari_aft/_widget/run.py +199 -0
- napari_aft-0.1.0/src/napari_aft/_widget/scan.py +160 -0
- napari_aft-0.1.0/src/napari_aft/_widget/shared.py +75 -0
- napari_aft-0.1.0/src/napari_aft/_widget/tables.py +83 -0
- napari_aft-0.1.0/src/napari_aft/_widget/tasks.py +91 -0
- napari_aft-0.1.0/src/napari_aft/_widget/widget.py +187 -0
- napari_aft-0.1.0/src/napari_aft/core/__init__.py +51 -0
- napari_aft-0.1.0/src/napari_aft/core/aft.py +430 -0
- napari_aft-0.1.0/src/napari_aft/core/batch.py +289 -0
- napari_aft-0.1.0/src/napari_aft/core/cells.py +339 -0
- napari_aft-0.1.0/src/napari_aft/core/coorient.py +158 -0
- napari_aft-0.1.0/src/napari_aft/core/export.py +105 -0
- napari_aft-0.1.0/src/napari_aft/core/pairing.py +238 -0
- napari_aft-0.1.0/src/napari_aft/core/params_yaml.py +293 -0
- napari_aft-0.1.0/src/napari_aft/core/pixel_size.py +303 -0
- napari_aft-0.1.0/src/napari_aft/core/progress.py +38 -0
- napari_aft-0.1.0/src/napari_aft/core/reading.py +190 -0
- napari_aft-0.1.0/src/napari_aft/core/run.py +306 -0
- napari_aft-0.1.0/src/napari_aft/core/scan.py +282 -0
- napari_aft-0.1.0/src/napari_aft/core/vectors.py +57 -0
- napari_aft-0.1.0/src/napari_aft/data/actin_single_cell.tif +0 -0
- napari_aft-0.1.0/src/napari_aft/data/mask_actin_single_cell.tif +0 -0
- napari_aft-0.1.0/src/napari_aft/napari.yaml +26 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/PKG-INFO +140 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/SOURCES.txt +99 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/dependency_links.txt +1 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/entry_points.txt +2 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/requires.txt +20 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/scm_file_list.json +94 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/scm_version.json +8 -0
- napari_aft-0.1.0/src/napari_aft.egg-info/top_level.txt +1 -0
- napari_aft-0.1.0/tests/__init__.py +0 -0
- napari_aft-0.1.0/tests/fixtures/make_fixtures.py +154 -0
- napari_aft-0.1.0/tests/fixtures/ref_disk_masks.npz +0 -0
- napari_aft-0.1.0/tests/fixtures/ref_grating30.npz +0 -0
- napari_aft-0.1.0/tests/fixtures/ref_lines_ws35.npz +0 -0
- napari_aft-0.1.0/tests/fixtures/ref_mask_ws41.npz +0 -0
- napari_aft-0.1.0/tests/fixtures/ref_noise_ws34.npz +0 -0
- napari_aft-0.1.0/tests/test_batch.py +764 -0
- napari_aft-0.1.0/tests/test_coorient.py +254 -0
- napari_aft-0.1.0/tests/test_core.py +453 -0
- napari_aft-0.1.0/tests/test_helpers.py +37 -0
- napari_aft-0.1.0/tests/test_params_yaml.py +187 -0
- napari_aft-0.1.0/tests/test_pixel_size.py +171 -0
- napari_aft-0.1.0/tests/test_regression.py +96 -0
- napari_aft-0.1.0/tests/widget/__init__.py +0 -0
- napari_aft-0.1.0/tests/widget/conftest.py +10 -0
- napari_aft-0.1.0/tests/widget/helpers.py +47 -0
- napari_aft-0.1.0/tests/widget/test_batch.py +244 -0
- napari_aft-0.1.0/tests/widget/test_helpers.py +68 -0
- napari_aft-0.1.0/tests/widget/test_input.py +159 -0
- napari_aft-0.1.0/tests/widget/test_layout.py +214 -0
- napari_aft-0.1.0/tests/widget/test_parameters.py +259 -0
- napari_aft-0.1.0/tests/widget/test_preview.py +124 -0
- napari_aft-0.1.0/tests/widget/test_run.py +233 -0
- napari_aft-0.1.0/tests/widget/test_scan.py +105 -0
- napari_aft-0.1.0/tox.ini +33 -0
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
name: "\U0001F41B Bug Report"
|
|
2
|
+
description: Report a bug encountered while using napari-aft
|
|
3
|
+
labels:
|
|
4
|
+
- "bug"
|
|
5
|
+
|
|
6
|
+
body:
|
|
7
|
+
- type: markdown
|
|
8
|
+
attributes:
|
|
9
|
+
value: |
|
|
10
|
+
Thanks for taking the time to report this issue! 🙏🏼
|
|
11
|
+
|
|
12
|
+
Please fill out the sections below to help us reproduce the problem.
|
|
13
|
+
|
|
14
|
+
- type: textarea
|
|
15
|
+
id: bug-report
|
|
16
|
+
attributes:
|
|
17
|
+
label: "\U0001F41B Bug Report"
|
|
18
|
+
description: "Please provide a clear and concise description of the bug."
|
|
19
|
+
placeholder: "What went wrong? What did you expect to happen?"
|
|
20
|
+
validations:
|
|
21
|
+
required: true
|
|
22
|
+
|
|
23
|
+
- type: textarea
|
|
24
|
+
id: steps-to-reproduce
|
|
25
|
+
attributes:
|
|
26
|
+
label: "\U0001F4A1 Steps to Reproduce"
|
|
27
|
+
description: "Please provide a minimal code snippet or list of steps to reproduce the bug."
|
|
28
|
+
placeholder: |
|
|
29
|
+
1. Go to '...'
|
|
30
|
+
2. Click on '....'
|
|
31
|
+
3. Scroll down to '....'
|
|
32
|
+
4. See error
|
|
33
|
+
validations:
|
|
34
|
+
required: true
|
|
35
|
+
|
|
36
|
+
- type: textarea
|
|
37
|
+
id: expected-behavior
|
|
38
|
+
attributes:
|
|
39
|
+
label: "\U0001F4A1 Expected Behavior"
|
|
40
|
+
description: "Please provide a clear and concise description of what you expected to happen."
|
|
41
|
+
placeholder: "What did you expect to happen?"
|
|
42
|
+
|
|
43
|
+
- type: textarea
|
|
44
|
+
id: environment
|
|
45
|
+
attributes:
|
|
46
|
+
label: "\U0001F30E Environment"
|
|
47
|
+
description: |
|
|
48
|
+
Please provide detailed information regarding your environment. Please paste the output of `napari --info` here or copy the information from the "napari info" dialog in the napari Help menu.
|
|
49
|
+
|
|
50
|
+
Otherwise, please provide information regarding your operating system (OS), Python version, napari version, Qt backend and version, Qt platform, method of installation, and any other relevant information related to your environment.
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
placeholder: |
|
|
54
|
+
napari: 0.5.0
|
|
55
|
+
Platform: macOS-13.2.1-arm64-arm-64bit
|
|
56
|
+
System: MacOS 13.2.1
|
|
57
|
+
Python: 3.11.4 (main, Aug 7 2023, 20:34:01) [Clang 14.0.3 (clang-1403.0.22.14.1)]
|
|
58
|
+
Qt: 5.15.10
|
|
59
|
+
PyQt5: 5.15.10
|
|
60
|
+
NumPy: 1.25.1
|
|
61
|
+
SciPy: 1.11.1
|
|
62
|
+
Dask: 2023.7.1
|
|
63
|
+
VisPy: 0.13.0
|
|
64
|
+
magicgui: 0.7.2
|
|
65
|
+
superqt: 0.5.4
|
|
66
|
+
in-n-out: 0.1.8
|
|
67
|
+
app-model: 0.2.0
|
|
68
|
+
npe2: 0.7.2
|
|
69
|
+
|
|
70
|
+
OpenGL:
|
|
71
|
+
- GL version: 2.1 Metal - 83
|
|
72
|
+
- MAX_TEXTURE_SIZE: 16384
|
|
73
|
+
|
|
74
|
+
Screens:
|
|
75
|
+
- screen 1: resolution 1512x982, scale 2.0
|
|
76
|
+
|
|
77
|
+
Settings path:
|
|
78
|
+
- /Users/.../napari/napari_5c6993c40c104085444cfc0c77fa392cb5cb8f56/settings.yaml
|
|
79
|
+
validations:
|
|
80
|
+
required: true
|
|
81
|
+
|
|
82
|
+
- type: textarea
|
|
83
|
+
id: additional-context
|
|
84
|
+
attributes:
|
|
85
|
+
label: "\U0001F4A1 Additional Context"
|
|
86
|
+
description: "Please provide any additional information or context regarding the problem here."
|
|
87
|
+
placeholder: "Add any other context about the problem here."
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: "\U0001F4DA Documentation"
|
|
3
|
+
about: Report an issue with napari-aft documentation
|
|
4
|
+
title: ''
|
|
5
|
+
labels: documentation
|
|
6
|
+
assignees: ''
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## 📚 Documentation
|
|
11
|
+
<!-- A clear and concise description of the documentation that needs to be created/updated -->
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: "\U0001F680 Feature Request"
|
|
3
|
+
about: Submit a proposal/request for a new napari-aft feature
|
|
4
|
+
title: ''
|
|
5
|
+
labels: feature
|
|
6
|
+
assignees: ''
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## 🚀 Feature
|
|
11
|
+
<!-- A clear and concise description of the feature proposal -->
|
|
12
|
+
|
|
13
|
+
## Motivation
|
|
14
|
+
|
|
15
|
+
<!-- Please outline the motivation for the proposal. Is your feature request related to a problem? e.g., I'm always frustrated when [...]. If this is related to another GitHub issue, please link here too -->
|
|
16
|
+
|
|
17
|
+
## Pitch
|
|
18
|
+
|
|
19
|
+
<!-- A clear and concise description of what you want to happen. -->
|
|
20
|
+
|
|
21
|
+
## Alternatives
|
|
22
|
+
|
|
23
|
+
<!-- A clear and concise description of any alternative solutions or features you've considered, if any. -->
|
|
24
|
+
|
|
25
|
+
## Additional context
|
|
26
|
+
|
|
27
|
+
<!-- Add any other context or screenshots about the feature request here. -->
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# References and relevant issues
|
|
2
|
+
<!-- What relevant resources were used in the creation of this PR?
|
|
3
|
+
If this PR addresses an existing issue on the repo,
|
|
4
|
+
please link to that issue here as "Closes #(issue-number)"
|
|
5
|
+
If this PR depends on another PR/issue (even in another repo),
|
|
6
|
+
please link to it with "Depends on #PR-number" or "Depends on org/repo#PR-number"
|
|
7
|
+
-->
|
|
8
|
+
|
|
9
|
+
# Description
|
|
10
|
+
<!-- What does this pull request (PR) do? Is it a new feature, a bug fix,
|
|
11
|
+
an improvement, or something else? Why is it necessary? If relevant, please add
|
|
12
|
+
a screenshot or a screen capture: "An image is worth a thousand words!" -->
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Dependabot configuration
|
|
2
|
+
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuring-dependabot-version-updates#enabling-github-dependabot-version-updates
|
|
3
|
+
# https://til.simonwillison.net/github/dependabot-python-setup
|
|
4
|
+
|
|
5
|
+
version: 2
|
|
6
|
+
updates:
|
|
7
|
+
# Monitor GitHub Actions and propose updates for security and maintenance
|
|
8
|
+
- package-ecosystem: github-actions
|
|
9
|
+
directory: "/"
|
|
10
|
+
schedule:
|
|
11
|
+
interval: monthly
|
|
12
|
+
commit-message:
|
|
13
|
+
prefix: "ci"
|
|
14
|
+
groups:
|
|
15
|
+
github-actions:
|
|
16
|
+
patterns:
|
|
17
|
+
- "*"
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
# Runs the prek hooks and the tests (via tox) on push/PR. On a "v*" tag, builds the
|
|
2
|
+
# package and publishes it to PyPI via trusted publishing:
|
|
3
|
+
# https://docs.pypi.org/trusted-publishers/
|
|
4
|
+
name: tests
|
|
5
|
+
|
|
6
|
+
on:
|
|
7
|
+
push:
|
|
8
|
+
branches:
|
|
9
|
+
- main
|
|
10
|
+
tags:
|
|
11
|
+
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
|
|
12
|
+
pull_request:
|
|
13
|
+
branches:
|
|
14
|
+
- main
|
|
15
|
+
workflow_dispatch:
|
|
16
|
+
|
|
17
|
+
concurrency:
|
|
18
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
19
|
+
cancel-in-progress: true
|
|
20
|
+
|
|
21
|
+
jobs:
|
|
22
|
+
lint:
|
|
23
|
+
name: prek
|
|
24
|
+
runs-on: ubuntu-latest
|
|
25
|
+
steps:
|
|
26
|
+
- uses: actions/checkout@v7
|
|
27
|
+
- uses: astral-sh/setup-uv@v7
|
|
28
|
+
- name: Run prek hooks (ruff check, ruff format, ...)
|
|
29
|
+
run: uvx prek run --all-files --show-diff-on-failure
|
|
30
|
+
|
|
31
|
+
test:
|
|
32
|
+
name: ${{ matrix.platform }} py${{ matrix.python-version }}
|
|
33
|
+
runs-on: ${{ matrix.platform }}
|
|
34
|
+
timeout-minutes: 30
|
|
35
|
+
permissions:
|
|
36
|
+
contents: read # checkout of the private repo
|
|
37
|
+
id-token: write # needed for codecov OIDC authentication
|
|
38
|
+
strategy:
|
|
39
|
+
fail-fast: false
|
|
40
|
+
matrix:
|
|
41
|
+
platform: [ubuntu-latest]
|
|
42
|
+
python-version: ["3.11", "3.12", "3.13", "3.14"]
|
|
43
|
+
include:
|
|
44
|
+
- platform: windows-latest
|
|
45
|
+
python-version: "3.12"
|
|
46
|
+
- platform: macos-latest
|
|
47
|
+
python-version: "3.12"
|
|
48
|
+
|
|
49
|
+
steps:
|
|
50
|
+
- uses: actions/checkout@v7
|
|
51
|
+
|
|
52
|
+
- name: Setup python
|
|
53
|
+
uses: astral-sh/setup-uv@v7
|
|
54
|
+
with:
|
|
55
|
+
python-version: ${{ matrix.python-version }}
|
|
56
|
+
activate-environment: "true"
|
|
57
|
+
- name: Setup headless display
|
|
58
|
+
uses: pyvista/setup-headless-display-action@v5.2
|
|
59
|
+
with:
|
|
60
|
+
qt: true
|
|
61
|
+
wm: herbstluftwm
|
|
62
|
+
|
|
63
|
+
# this runs the platform-specific tests declared in tox.ini
|
|
64
|
+
- name: Test with tox
|
|
65
|
+
run: uvx --with tox-gh-actions tox
|
|
66
|
+
env:
|
|
67
|
+
PLATFORM: ${{ matrix.platform }}
|
|
68
|
+
|
|
69
|
+
- name: Coverage
|
|
70
|
+
uses: codecov/codecov-action@v7
|
|
71
|
+
with:
|
|
72
|
+
use_oidc: true # reliable tokenless codecov uploads
|
|
73
|
+
|
|
74
|
+
build-and-inspect-package:
|
|
75
|
+
name: Build & inspect package.
|
|
76
|
+
runs-on: ubuntu-latest
|
|
77
|
+
|
|
78
|
+
steps:
|
|
79
|
+
- uses: actions/checkout@v7
|
|
80
|
+
with:
|
|
81
|
+
fetch-depth: 0 # setuptools_scm needs the tag history for the version
|
|
82
|
+
- uses: hynek/build-and-inspect-python-package@v3.0.2
|
|
83
|
+
|
|
84
|
+
deploy:
|
|
85
|
+
# runs when a commit is tagged "v*"; uses PyPI trusted publishing (no API token)
|
|
86
|
+
name: Publish to PyPI
|
|
87
|
+
needs: [lint, test, build-and-inspect-package]
|
|
88
|
+
runs-on: ubuntu-latest
|
|
89
|
+
if: startsWith(github.ref, 'refs/tags/v')
|
|
90
|
+
environment:
|
|
91
|
+
name: pypi
|
|
92
|
+
url: https://pypi.org/p/napari-aft
|
|
93
|
+
permissions:
|
|
94
|
+
id-token: write # trusted publishing
|
|
95
|
+
steps:
|
|
96
|
+
- name: Download built artifact to dist/
|
|
97
|
+
uses: actions/download-artifact@v8
|
|
98
|
+
with:
|
|
99
|
+
name: Packages
|
|
100
|
+
path: dist
|
|
101
|
+
- name: Publish to PyPI
|
|
102
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
env/
|
|
12
|
+
build/
|
|
13
|
+
develop-eggs/
|
|
14
|
+
dist/
|
|
15
|
+
downloads/
|
|
16
|
+
eggs/
|
|
17
|
+
.eggs/
|
|
18
|
+
lib/
|
|
19
|
+
lib64/
|
|
20
|
+
parts/
|
|
21
|
+
sdist/
|
|
22
|
+
var/
|
|
23
|
+
*.egg-info/
|
|
24
|
+
.installed.cfg
|
|
25
|
+
*.egg
|
|
26
|
+
|
|
27
|
+
# PyInstaller
|
|
28
|
+
# Usually these files are written by a python script from a template
|
|
29
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
30
|
+
*.manifest
|
|
31
|
+
*.spec
|
|
32
|
+
|
|
33
|
+
# Installer logs
|
|
34
|
+
pip-log.txt
|
|
35
|
+
pip-delete-this-directory.txt
|
|
36
|
+
|
|
37
|
+
# Unit test / coverage reports
|
|
38
|
+
htmlcov/
|
|
39
|
+
.tox/
|
|
40
|
+
.coverage
|
|
41
|
+
.coverage.*
|
|
42
|
+
.cache
|
|
43
|
+
nosetests.xml
|
|
44
|
+
coverage.xml
|
|
45
|
+
*,cover
|
|
46
|
+
.hypothesis/
|
|
47
|
+
.napari_cache
|
|
48
|
+
|
|
49
|
+
# Translations
|
|
50
|
+
*.mo
|
|
51
|
+
*.pot
|
|
52
|
+
|
|
53
|
+
# Django stuff:
|
|
54
|
+
*.log
|
|
55
|
+
local_settings.py
|
|
56
|
+
|
|
57
|
+
# Flask instance folder
|
|
58
|
+
instance/
|
|
59
|
+
|
|
60
|
+
# Sphinx documentation
|
|
61
|
+
docs/_build/
|
|
62
|
+
|
|
63
|
+
# MkDocs documentation
|
|
64
|
+
/site/
|
|
65
|
+
|
|
66
|
+
# PyBuilder
|
|
67
|
+
target/
|
|
68
|
+
|
|
69
|
+
# Pycharm and VSCode
|
|
70
|
+
.idea/
|
|
71
|
+
venv/
|
|
72
|
+
.vscode/
|
|
73
|
+
|
|
74
|
+
# IPython Notebook
|
|
75
|
+
.ipynb_checkpoints
|
|
76
|
+
|
|
77
|
+
# pyenv
|
|
78
|
+
.python-version
|
|
79
|
+
|
|
80
|
+
# OS
|
|
81
|
+
.DS_Store
|
|
82
|
+
|
|
83
|
+
# written by setuptools_scm
|
|
84
|
+
**/_version.py
|
|
85
|
+
|
|
86
|
+
# Linters, test caches and virtual environments
|
|
87
|
+
.pytest_cache/
|
|
88
|
+
.ruff_cache/
|
|
89
|
+
.venv/
|
|
90
|
+
|
|
91
|
+
# exports written while trying the plugin
|
|
92
|
+
*_AFT_cells.csv
|
|
93
|
+
*_AFT_windows.csv
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
3
|
+
rev: v6.0.0
|
|
4
|
+
hooks:
|
|
5
|
+
- id: check-docstring-first
|
|
6
|
+
- id: end-of-file-fixer
|
|
7
|
+
- id: trailing-whitespace
|
|
8
|
+
- id: check-yaml # checks for correct yaml syntax for github actions ex.
|
|
9
|
+
- id: check-toml
|
|
10
|
+
- id: check-added-large-files
|
|
11
|
+
args: ["--maxkb=1024"]
|
|
12
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
13
|
+
rev: v0.17.1
|
|
14
|
+
hooks:
|
|
15
|
+
- id: ruff-check
|
|
16
|
+
- id: ruff-format
|
|
17
|
+
- repo: https://github.com/napari/napari-plugin-checks
|
|
18
|
+
rev: v0.3.0
|
|
19
|
+
hooks:
|
|
20
|
+
- id: napari-plugin-checks
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
message: If you use this software, please cite it as below.
|
|
3
|
+
type: software
|
|
4
|
+
title: napari-aft
|
|
5
|
+
abstract: AFT (Alignment by Fourier Transform) in napari, measuring local fiber orientation and the order parameter per cell or per image.
|
|
6
|
+
authors:
|
|
7
|
+
- family-names: Wagner
|
|
8
|
+
given-names: Jesko
|
|
9
|
+
orcid: https://orcid.org/0000-0001-9805-7192
|
|
10
|
+
affiliation: Danish BioImaging Infrastructure Image Analysis Core Facility (DBI-INFRA)
|
|
11
|
+
license: MIT
|
|
12
|
+
repository-code: https://github.com/DBI-INFRA/napari-aft
|
|
13
|
+
keywords: [napari, AFT, alignment, orientation, order parameter, fibers, Fourier transform, microscopy]
|
napari_aft-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Jesko Wagner
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
22
|
+
|
|
23
|
+
-------------------------------------------------------------------------------
|
|
24
|
+
|
|
25
|
+
napari-aft re-implements AFT based on published code available at
|
|
26
|
+
https://github.com/OakesLab/AFT-Alignment_by_Fourier_Transform, which is distributed under the following
|
|
27
|
+
license:
|
|
28
|
+
|
|
29
|
+
MIT License
|
|
30
|
+
|
|
31
|
+
Copyright (c) 2024 OakesLab
|
|
32
|
+
|
|
33
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
34
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
35
|
+
in the Software without restriction, including without limitation the rights
|
|
36
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
37
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
38
|
+
furnished to do so, subject to the following conditions:
|
|
39
|
+
|
|
40
|
+
The above copyright notice and this permission notice shall be included in all
|
|
41
|
+
copies or substantial portions of the Software.
|
|
42
|
+
|
|
43
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
44
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
45
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
46
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
47
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
48
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
49
|
+
SOFTWARE.
|
|
50
|
+
|
|
51
|
+
-------------------------------------------------------------------------------
|
|
52
|
+
|
|
53
|
+
The sample images in src/napari_aft/data are from the supplementary material
|
|
54
|
+
of Marcotti S, et al. (2021), A Workflow for Rapid Unbiased Quantification of
|
|
55
|
+
Fibrillar Feature Alignment in Biological Images, Front. Comput. Sci. 3:745831,
|
|
56
|
+
https://doi.org/10.6084/m9.figshare.15326472. They are licensed under the
|
|
57
|
+
Creative Commons Attribution 4.0 International license (CC BY 4.0),
|
|
58
|
+
https://creativecommons.org/licenses/by/4.0/.
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: napari-aft
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: AFT (Alignment by Fourier Transform) in napari: local fiber orientation and the order parameter per cell or per image, length-scale search and folder batch
|
|
5
|
+
Author-email: Jesko Wagner <35219306+jeskowagner@users.noreply.github.com>
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Project-URL: Bug Tracker, https://github.com/DBI-INFRA/napari-aft/issues
|
|
8
|
+
Project-URL: Documentation, https://github.com/DBI-INFRA/napari-aft#README.md
|
|
9
|
+
Project-URL: Source Code, https://github.com/DBI-INFRA/napari-aft
|
|
10
|
+
Project-URL: User Support, https://github.com/DBI-INFRA/napari-aft/issues
|
|
11
|
+
Project-URL: AFT paper, https://doi.org/10.3389/fcomp.2021.745831
|
|
12
|
+
Keywords: napari,AFT,alignment,orientation,order parameter,fibers,Fourier transform,microscopy
|
|
13
|
+
Classifier: Development Status :: 3 - Alpha
|
|
14
|
+
Classifier: Framework :: napari
|
|
15
|
+
Classifier: Intended Audience :: Science/Research
|
|
16
|
+
Classifier: Operating System :: OS Independent
|
|
17
|
+
Classifier: Programming Language :: Python
|
|
18
|
+
Classifier: Programming Language :: Python :: 3
|
|
19
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
23
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
24
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
25
|
+
Classifier: Topic :: Scientific/Engineering :: Image Processing
|
|
26
|
+
Requires-Python: >=3.11
|
|
27
|
+
Description-Content-Type: text/markdown
|
|
28
|
+
License-File: LICENSE
|
|
29
|
+
Requires-Dist: napari>=0.6
|
|
30
|
+
Requires-Dist: npe2
|
|
31
|
+
Requires-Dist: magicgui
|
|
32
|
+
Requires-Dist: qtpy
|
|
33
|
+
Requires-Dist: numpy
|
|
34
|
+
Requires-Dist: scipy
|
|
35
|
+
Requires-Dist: scikit-image
|
|
36
|
+
Requires-Dist: pandas
|
|
37
|
+
Requires-Dist: matplotlib
|
|
38
|
+
Requires-Dist: pyyaml
|
|
39
|
+
Requires-Dist: bioio
|
|
40
|
+
Requires-Dist: bioio-tifffile
|
|
41
|
+
Requires-Dist: bioio-ome-tiff
|
|
42
|
+
Requires-Dist: bioio-imageio
|
|
43
|
+
Provides-Extra: all
|
|
44
|
+
Requires-Dist: napari[all]; extra == "all"
|
|
45
|
+
Provides-Extra: cellpose
|
|
46
|
+
Requires-Dist: napari-cellposesam; extra == "cellpose"
|
|
47
|
+
Dynamic: license-file
|
|
48
|
+
|
|
49
|
+
# napari-aft
|
|
50
|
+
|
|
51
|
+
napari-aft measures how well fibers are aligned in microscopy images. It brings
|
|
52
|
+
**AFT (Alignment by Fourier Transform)**
|
|
53
|
+
([Marcotti et al., 2021](https://doi.org/10.3389/fcomp.2021.745831)) to
|
|
54
|
+
[napari](https://napari.org).
|
|
55
|
+
|
|
56
|
+
AFT splits the image into small overlapping windows and finds the main fiber direction in each
|
|
57
|
+
one. It then compares each window with its neighbors. This allows it to measure
|
|
58
|
+
the **order parameter**, which describes how much neighboring windows agree on alignment.
|
|
59
|
+
When fibers point in random directions, it is 0 and it is 1 when they all point
|
|
60
|
+
the same way. napari-aft allows measuring this either per cell or for a whole
|
|
61
|
+
image.
|
|
62
|
+
|
|
63
|
+
<p align="center">
|
|
64
|
+
<img src="https://raw.githubusercontent.com/DBI-INFRA/napari-aft/main/docs/img/overview.png" alt="napari-aft on an actin-stained fibroblast" width="800"/>
|
|
65
|
+
</p>
|
|
66
|
+
|
|
67
|
+
## What it does
|
|
68
|
+
napari-aft allows you to:
|
|
69
|
+
|
|
70
|
+
- Detect the **fiber direction per window**
|
|
71
|
+
- Measure the **order parameter per cell** or the whole image
|
|
72
|
+
- Perform **parameter searches** to understand how sensitive your measurements
|
|
73
|
+
are to parameters
|
|
74
|
+
- Run in **batch mode**
|
|
75
|
+
|
|
76
|
+
<p align="center">
|
|
77
|
+
<img src="https://raw.githubusercontent.com/DBI-INFRA/napari-aft/main/docs/img/scan.png" alt="Parameter search" width="800"/>
|
|
78
|
+
</p>
|
|
79
|
+
|
|
80
|
+
## How AFT works
|
|
81
|
+
|
|
82
|
+
https://github.com/user-attachments/assets/18694994-a0a4-4eba-b24c-3f96c2be4a00
|
|
83
|
+
|
|
84
|
+
## Installation
|
|
85
|
+
|
|
86
|
+
napari-aft needs Python 3.11 or later. If you already have napari installed,
|
|
87
|
+
install the plugin using:
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
pip install napari-aft
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
If you don't yet have napari installed, or if you also want to use
|
|
94
|
+
[Cellpose-SAM](https://github.com/DBI-INFRA/napari-cellposesam) for
|
|
95
|
+
segmentation, use:
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
# Also install napari:
|
|
99
|
+
pip install "napari-aft[all]"
|
|
100
|
+
|
|
101
|
+
# If you want to use Cellpose-SAM for segmentation:
|
|
102
|
+
pip install "napari-aft[cellpose]"
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## Quick start
|
|
106
|
+
|
|
107
|
+
1. Start napari and open *File > Open Sample > napari-aft > Actin-stained fibroblast*.
|
|
108
|
+
2. Open *Plugins > AFT (napari-aft)*.
|
|
109
|
+
3. Tick **Live preview** and play with the parameters to see their effect.
|
|
110
|
+
4. Once happy, click **Run AFT**.
|
|
111
|
+
5. To see the effect of parameters on the result more systematically, open the *Parameter search* tab and click **Scan** to compare window sizes.
|
|
112
|
+
|
|
113
|
+
To analyze your own images, open them in napari and pick them under *Input*.
|
|
114
|
+
|
|
115
|
+
https://github.com/user-attachments/assets/d71a3a5f-00fa-416e-b422-a657371ebcac
|
|
116
|
+
|
|
117
|
+
## Documentation
|
|
118
|
+
|
|
119
|
+
For more detailed documentation, please refer to the [user guide](https://github.com/DBI-INFRA/napari-aft/blob/main/docs/usage.md).
|
|
120
|
+
|
|
121
|
+
## Citation
|
|
122
|
+
|
|
123
|
+
If you use napari-aft, please cite the AFT paper:
|
|
124
|
+
|
|
125
|
+
> Marcotti S, Belo de Freitas D, Troughton LD, Kenny FN, Shaw TJ, Stramer BM, Oakes PW (2021).
|
|
126
|
+
> *A Workflow for Rapid Unbiased Quantification of Fibrillar Feature Alignment in Biological Images.*
|
|
127
|
+
> Front. Comput. Sci. 3:745831. doi:10.3389/fcomp.2021.745831
|
|
128
|
+
|
|
129
|
+
The periodic plus smooth decomposition is from Moisan L. (2011), *Periodic plus smooth image
|
|
130
|
+
decomposition*, J Math Imaging Vis 39:161–179.
|
|
131
|
+
|
|
132
|
+
## License
|
|
133
|
+
|
|
134
|
+
See `LICENSE`. napari-aft re-implements AFT from
|
|
135
|
+
[OakesLab/AFT-Alignment_by_Fourier_Transform](https://github.com/OakesLab/AFT-Alignment_by_Fourier_Transform)
|
|
136
|
+
(MIT, Copyright (c) 2024 OakesLab).
|
|
137
|
+
|
|
138
|
+
Sample images were taken from the AFT paper's
|
|
139
|
+
[supplementary data](https://doi.org/10.6084/m9.figshare.15326472) (Marcotti et al., 2021),
|
|
140
|
+
licensed [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).
|