dvp-io 0.2.2__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.
- dvp_io-0.2.2/.bumpversion.toml +40 -0
- dvp_io-0.2.2/.codecov.yaml +17 -0
- dvp_io-0.2.2/.cruft.json +30 -0
- dvp_io-0.2.2/.editorconfig +15 -0
- dvp_io-0.2.2/.github/ISSUE_TEMPLATE/bug_report.yml +89 -0
- dvp_io-0.2.2/.github/ISSUE_TEMPLATE/config.yml +5 -0
- dvp_io-0.2.2/.github/ISSUE_TEMPLATE/feature_request.yml +11 -0
- dvp_io-0.2.2/.github/release_notes.yaml +25 -0
- dvp_io-0.2.2/.github/workflows/build.yaml +32 -0
- dvp_io-0.2.2/.github/workflows/bump_version.yaml +23 -0
- dvp_io-0.2.2/.github/workflows/prepare_test_data.yaml +46 -0
- dvp_io-0.2.2/.github/workflows/release.yaml +29 -0
- dvp_io-0.2.2/.github/workflows/test.yaml +83 -0
- dvp_io-0.2.2/.gitignore +25 -0
- dvp_io-0.2.2/.pre-commit-config.yaml +46 -0
- dvp_io-0.2.2/.prettierrc.yaml +7 -0
- dvp_io-0.2.2/.readthedocs.yaml +19 -0
- dvp_io-0.2.2/.vscode/extensions.json +18 -0
- dvp_io-0.2.2/.vscode/launch.json +33 -0
- dvp_io-0.2.2/.vscode/settings.json +18 -0
- dvp_io-0.2.2/CHANGELOG.md +3 -0
- dvp_io-0.2.2/CITATION.cff +25 -0
- dvp_io-0.2.2/LICENSE +201 -0
- dvp_io-0.2.2/PKG-INFO +337 -0
- dvp_io-0.2.2/README.md +88 -0
- dvp_io-0.2.2/docs/Makefile +20 -0
- dvp_io-0.2.2/docs/_static/.gitkeep +0 -0
- dvp_io-0.2.2/docs/_static/css/custom.css +4 -0
- dvp_io-0.2.2/docs/_static/img/006_sopa-point-selection.gif +0 -0
- dvp_io-0.2.2/docs/_static/img/napari-roi-selection.gif +0 -0
- dvp_io-0.2.2/docs/_static/img/napari-tutorial1.gif +0 -0
- dvp_io-0.2.2/docs/_static/img/quapath-tutorial1.gif +0 -0
- dvp_io-0.2.2/docs/_templates/.gitkeep +0 -0
- dvp_io-0.2.2/docs/_templates/autosummary/class.rst +61 -0
- dvp_io-0.2.2/docs/api.md +60 -0
- dvp_io-0.2.2/docs/changelog.md +3 -0
- dvp_io-0.2.2/docs/conf.py +136 -0
- dvp_io-0.2.2/docs/contributing.md +215 -0
- dvp_io-0.2.2/docs/extensions/typed_returns.py +32 -0
- dvp_io-0.2.2/docs/faq.md +107 -0
- dvp_io-0.2.2/docs/index.md +15 -0
- dvp_io-0.2.2/docs/references.bib +104 -0
- dvp_io-0.2.2/docs/references.md +5 -0
- dvp_io-0.2.2/docs/tutorials/000_spatialdata_and_dvp.md +31 -0
- dvp_io-0.2.2/docs/tutorials/001_introduction-to-spatialdata.ipynb +1514 -0
- dvp_io-0.2.2/docs/tutorials/002_read-dvpio.ipynb +1001 -0
- dvp_io-0.2.2/docs/tutorials/003_write-dvpio.ipynb +773 -0
- dvp_io-0.2.2/docs/tutorials/004_scdvp.ipynb +1429 -0
- dvp_io-0.2.2/docs/tutorials/005_scportrait.ipynb +240 -0
- dvp_io-0.2.2/docs/tutorials/006_sopa.ipynb +433 -0
- dvp_io-0.2.2/docs/tutorials.md +39 -0
- dvp_io-0.2.2/pyproject.toml +151 -0
- dvp_io-0.2.2/src/dvpio/__init__.py +3 -0
- dvp_io-0.2.2/src/dvpio/_utils.py +33 -0
- dvp_io-0.2.2/src/dvpio/read/__init__.py +0 -0
- dvp_io-0.2.2/src/dvpio/read/image/__init__.py +6 -0
- dvp_io-0.2.2/src/dvpio/read/image/_metadata.py +425 -0
- dvp_io-0.2.2/src/dvpio/read/image/_utils.py +127 -0
- dvp_io-0.2.2/src/dvpio/read/image/custom.py +40 -0
- dvp_io-0.2.2/src/dvpio/read/image/czi.py +228 -0
- dvp_io-0.2.2/src/dvpio/read/image/openslide.py +116 -0
- dvp_io-0.2.2/src/dvpio/read/omics/__init__.py +3 -0
- dvp_io-0.2.2/src/dvpio/read/omics/_anndata.py +128 -0
- dvp_io-0.2.2/src/dvpio/read/omics/report_reader.py +194 -0
- dvp_io-0.2.2/src/dvpio/read/shapes/__init__.py +3 -0
- dvp_io-0.2.2/src/dvpio/read/shapes/geometry.py +79 -0
- dvp_io-0.2.2/src/dvpio/read/shapes/lmd_reader.py +193 -0
- dvp_io-0.2.2/src/dvpio/write/__init__.py +3 -0
- dvp_io-0.2.2/src/dvpio/write/lmd_writer.py +121 -0
- dvp_io-0.2.2/tests/read/image/test_custom.py +17 -0
- dvp_io-0.2.2/tests/read/image/test_czi.py +69 -0
- dvp_io-0.2.2/tests/read/image/test_metadata.py +174 -0
- dvp_io-0.2.2/tests/read/image/test_openslide.py +45 -0
- dvp_io-0.2.2/tests/read/image/test_utils.py +139 -0
- dvp_io-0.2.2/tests/read/omics/test_report_reader.py +230 -0
- dvp_io-0.2.2/tests/read/shapes/test_geometry.py +93 -0
- dvp_io-0.2.2/tests/read/shapes/test_lmd_reader.py +76 -0
- dvp_io-0.2.2/tests/test_utils.py +31 -0
- dvp_io-0.2.2/tests/write/test_lmd_writer.py +114 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
[tool.bumpversion]
|
|
2
|
+
current_version = "0.2.2"
|
|
3
|
+
parse = """(?x)
|
|
4
|
+
(?P<major>0|[1-9]\\d*)\\.
|
|
5
|
+
(?P<minor>0|[1-9]\\d*)\\.
|
|
6
|
+
(?P<patch>0|[1-9]\\d*)
|
|
7
|
+
(?:
|
|
8
|
+
- # dash separator for pre-release section
|
|
9
|
+
(?P<pre_l>[a-zA-Z-]+) # pre_l: pre-release label
|
|
10
|
+
(?P<pre_n>0|[1-9]\\d*) # pre_n: pre-release version number
|
|
11
|
+
)? # pre-release section is optional
|
|
12
|
+
"""
|
|
13
|
+
serialize = [
|
|
14
|
+
"{major}.{minor}.{patch}-{pre_l}{pre_n}",
|
|
15
|
+
"{major}.{minor}.{patch}",
|
|
16
|
+
]
|
|
17
|
+
search = "{current_version}"
|
|
18
|
+
replace = "{new_version}"
|
|
19
|
+
regex = false
|
|
20
|
+
ignore_missing_version = false
|
|
21
|
+
ignore_missing_files = false
|
|
22
|
+
tag = false
|
|
23
|
+
sign_tags = false
|
|
24
|
+
tag_name = "v{new_version}"
|
|
25
|
+
tag_message = "Bump version: {current_version} → {new_version}"
|
|
26
|
+
allow_dirty = false
|
|
27
|
+
commit = true
|
|
28
|
+
message = "Bump version: {current_version} → {new_version}"
|
|
29
|
+
commit_args = ""
|
|
30
|
+
setup_hooks = []
|
|
31
|
+
pre_commit_hooks = []
|
|
32
|
+
post_commit_hooks = []
|
|
33
|
+
|
|
34
|
+
[tool.bumpversion.parts.pre_l]
|
|
35
|
+
# 'final' is just a dummy, but required to have the versioning compatible with the reusable alphashared workflow
|
|
36
|
+
values = ["dev", "final"]
|
|
37
|
+
optional_value = "final"
|
|
38
|
+
|
|
39
|
+
[[tool.bumpversion.files]]
|
|
40
|
+
filename = "./pyproject.toml"
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Based on pydata/xarray
|
|
2
|
+
codecov:
|
|
3
|
+
require_ci_to_pass: no
|
|
4
|
+
|
|
5
|
+
coverage:
|
|
6
|
+
status:
|
|
7
|
+
project:
|
|
8
|
+
default:
|
|
9
|
+
# Require 1% coverage, i.e., always succeed
|
|
10
|
+
target: 1
|
|
11
|
+
patch: false
|
|
12
|
+
changes: false
|
|
13
|
+
|
|
14
|
+
comment:
|
|
15
|
+
layout: diff, flags, files
|
|
16
|
+
behavior: once
|
|
17
|
+
require_base: no
|
dvp_io-0.2.2/.cruft.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
{
|
|
2
|
+
"template": "https://github.com/scverse/cookiecutter-scverse",
|
|
3
|
+
"commit": "5d44c58df427f884585ae9772cae81f1b6638f80",
|
|
4
|
+
"checkout": null,
|
|
5
|
+
"context": {
|
|
6
|
+
"cookiecutter": {
|
|
7
|
+
"project_name": "dvp-io",
|
|
8
|
+
"package_name": "dvpio",
|
|
9
|
+
"project_description": "Read and write funtionalities from and to spatialdata for deep vizual proteomics",
|
|
10
|
+
"author_full_name": "Lucas Diedrich",
|
|
11
|
+
"author_email": "diedrich@biochem.mpg.de",
|
|
12
|
+
"github_user": "lucas-diedrich",
|
|
13
|
+
"github_repo": "dvp-io",
|
|
14
|
+
"license": "Apache License Version 2.0",
|
|
15
|
+
"ide_integration": true,
|
|
16
|
+
"_copy_without_render": [
|
|
17
|
+
".github/workflows/build.yaml",
|
|
18
|
+
".github/workflows/test.yaml",
|
|
19
|
+
"docs/_templates/autosummary/**.rst"
|
|
20
|
+
],
|
|
21
|
+
"_render_devdocs": false,
|
|
22
|
+
"_jinja2_env_vars": {
|
|
23
|
+
"lstrip_blocks": true,
|
|
24
|
+
"trim_blocks": true
|
|
25
|
+
},
|
|
26
|
+
"_template": "https://github.com/scverse/cookiecutter-scverse"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"directory": null
|
|
30
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
root = true
|
|
2
|
+
|
|
3
|
+
[*]
|
|
4
|
+
indent_style = space
|
|
5
|
+
indent_size = 4
|
|
6
|
+
end_of_line = lf
|
|
7
|
+
charset = utf-8
|
|
8
|
+
trim_trailing_whitespace = true
|
|
9
|
+
insert_final_newline = true
|
|
10
|
+
|
|
11
|
+
[{*.{yml,yaml,toml},.cruft.json}]
|
|
12
|
+
indent_size = 2
|
|
13
|
+
|
|
14
|
+
[Makefile]
|
|
15
|
+
indent_style = tab
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
name: Bug report
|
|
2
|
+
description: Report something that is broken or incorrect
|
|
3
|
+
labels: bug
|
|
4
|
+
body:
|
|
5
|
+
- type: markdown
|
|
6
|
+
attributes:
|
|
7
|
+
value: |
|
|
8
|
+
**Note**: Please read [this guide](https://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports)
|
|
9
|
+
detailing how to provide the necessary information for us to reproduce your bug. In brief:
|
|
10
|
+
* Please provide exact steps how to reproduce the bug in a clean Python environment.
|
|
11
|
+
* In case it's not clear what's causing this bug, please provide the data or the data generation procedure.
|
|
12
|
+
* Sometimes it is not possible to share the data, but usually it is possible to replicate problems on publicly
|
|
13
|
+
available datasets or to share a subset of your data.
|
|
14
|
+
|
|
15
|
+
- type: textarea
|
|
16
|
+
id: report
|
|
17
|
+
attributes:
|
|
18
|
+
label: Report
|
|
19
|
+
description: A clear and concise description of what the bug is.
|
|
20
|
+
validations:
|
|
21
|
+
required: true
|
|
22
|
+
|
|
23
|
+
- type: textarea
|
|
24
|
+
id: versions
|
|
25
|
+
attributes:
|
|
26
|
+
label: Version information
|
|
27
|
+
description: |
|
|
28
|
+
Please paste below the output of
|
|
29
|
+
|
|
30
|
+
```python
|
|
31
|
+
import session_info
|
|
32
|
+
session_info.show(html=False, dependencies=True)
|
|
33
|
+
```
|
|
34
|
+
placeholder: |
|
|
35
|
+
-----
|
|
36
|
+
anndata 0.8.0rc2.dev27+ge524389
|
|
37
|
+
session_info 1.0.0
|
|
38
|
+
-----
|
|
39
|
+
asttokens NA
|
|
40
|
+
awkward 1.8.0
|
|
41
|
+
backcall 0.2.0
|
|
42
|
+
cython_runtime NA
|
|
43
|
+
dateutil 2.8.2
|
|
44
|
+
debugpy 1.6.0
|
|
45
|
+
decorator 5.1.1
|
|
46
|
+
entrypoints 0.4
|
|
47
|
+
executing 0.8.3
|
|
48
|
+
h5py 3.7.0
|
|
49
|
+
ipykernel 6.15.0
|
|
50
|
+
jedi 0.18.1
|
|
51
|
+
mpl_toolkits NA
|
|
52
|
+
natsort 8.1.0
|
|
53
|
+
numpy 1.22.4
|
|
54
|
+
packaging 21.3
|
|
55
|
+
pandas 1.4.2
|
|
56
|
+
parso 0.8.3
|
|
57
|
+
pexpect 4.8.0
|
|
58
|
+
pickleshare 0.7.5
|
|
59
|
+
pkg_resources NA
|
|
60
|
+
prompt_toolkit 3.0.29
|
|
61
|
+
psutil 5.9.1
|
|
62
|
+
ptyprocess 0.7.0
|
|
63
|
+
pure_eval 0.2.2
|
|
64
|
+
pydev_ipython NA
|
|
65
|
+
pydevconsole NA
|
|
66
|
+
pydevd 2.8.0
|
|
67
|
+
pydevd_file_utils NA
|
|
68
|
+
pydevd_plugins NA
|
|
69
|
+
pydevd_tracing NA
|
|
70
|
+
pygments 2.12.0
|
|
71
|
+
pytz 2022.1
|
|
72
|
+
scipy 1.8.1
|
|
73
|
+
setuptools 62.5.0
|
|
74
|
+
setuptools_scm NA
|
|
75
|
+
six 1.16.0
|
|
76
|
+
stack_data 0.3.0
|
|
77
|
+
tornado 6.1
|
|
78
|
+
traitlets 5.3.0
|
|
79
|
+
wcwidth 0.2.5
|
|
80
|
+
zmq 23.1.0
|
|
81
|
+
-----
|
|
82
|
+
IPython 8.4.0
|
|
83
|
+
jupyter_client 7.3.4
|
|
84
|
+
jupyter_core 4.10.0
|
|
85
|
+
-----
|
|
86
|
+
Python 3.9.13 | packaged by conda-forge | (main, May 27 2022, 16:58:50) [GCC 10.3.0]
|
|
87
|
+
Linux-5.18.6-arch1-1-x86_64-with-glibc2.35
|
|
88
|
+
-----
|
|
89
|
+
Session information updated at 2022-07-07 17:55
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
name: Feature request
|
|
2
|
+
description: Propose a new feature for dvp-io
|
|
3
|
+
labels: enhancement
|
|
4
|
+
body:
|
|
5
|
+
- type: textarea
|
|
6
|
+
id: description
|
|
7
|
+
attributes:
|
|
8
|
+
label: Description of feature
|
|
9
|
+
description: Please describe your suggestion for a new feature. It might help to describe a problem or use case, plus any alternatives that you have considered.
|
|
10
|
+
validations:
|
|
11
|
+
required: true
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# name: Release Notes
|
|
2
|
+
# Automatically generate summary of all channges since last release
|
|
3
|
+
# https://docs.github.com/en/repositories/releasing-projects-on-github/automatically-generated-release-notes#configuring-automatically-generated-release-notes
|
|
4
|
+
|
|
5
|
+
changelog:
|
|
6
|
+
exclude:
|
|
7
|
+
labels:
|
|
8
|
+
- ignore-for-release
|
|
9
|
+
categories:
|
|
10
|
+
- title: Breaking Changes
|
|
11
|
+
labels:
|
|
12
|
+
- breaking-change
|
|
13
|
+
- title: Bug fixes
|
|
14
|
+
labels:
|
|
15
|
+
- bug
|
|
16
|
+
- bug-fixes
|
|
17
|
+
- title: New Features
|
|
18
|
+
labels:
|
|
19
|
+
- enhancement
|
|
20
|
+
- title: Documentation
|
|
21
|
+
labels:
|
|
22
|
+
- documentation
|
|
23
|
+
- title: Other Changes / unlabeled
|
|
24
|
+
labels:
|
|
25
|
+
- "*"
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
name: Check Build
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
|
|
9
|
+
concurrency:
|
|
10
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
11
|
+
cancel-in-progress: true
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
package:
|
|
15
|
+
runs-on: ${{ matrix.platform }}
|
|
16
|
+
strategy:
|
|
17
|
+
matrix:
|
|
18
|
+
platform: [ubuntu-latest, windows-latest, macos-latest]
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
- name: Set up Python 3.12
|
|
22
|
+
uses: actions/setup-python@v5
|
|
23
|
+
with:
|
|
24
|
+
python-version: "3.12"
|
|
25
|
+
cache: "pip"
|
|
26
|
+
cache-dependency-path: "**/pyproject.toml"
|
|
27
|
+
- name: Install build dependencies
|
|
28
|
+
run: python -m pip install --upgrade pip wheel twine build
|
|
29
|
+
- name: Build package
|
|
30
|
+
run: python -m build
|
|
31
|
+
- name: Check package
|
|
32
|
+
run: twine check --strict dist/*.whl
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Bump the version for releases
|
|
2
|
+
name: Bump version
|
|
3
|
+
|
|
4
|
+
on:
|
|
5
|
+
workflow_dispatch:
|
|
6
|
+
inputs:
|
|
7
|
+
bump_type:
|
|
8
|
+
description: "Bump type"
|
|
9
|
+
required: true
|
|
10
|
+
default: "minor"
|
|
11
|
+
type: choice
|
|
12
|
+
options:
|
|
13
|
+
- prerelease
|
|
14
|
+
- patch
|
|
15
|
+
- minor
|
|
16
|
+
- major
|
|
17
|
+
|
|
18
|
+
jobs:
|
|
19
|
+
bump-version:
|
|
20
|
+
uses: MannLabs/alphashared/.github/workflows/bump_version.yml@v1
|
|
21
|
+
secrets: inherit
|
|
22
|
+
with:
|
|
23
|
+
bump_type: ${{ inputs.bump_type }}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
name: Prepare test data
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
# Pushing to branch dataset will create a new artifact
|
|
6
|
+
push:
|
|
7
|
+
branches:
|
|
8
|
+
- dataset
|
|
9
|
+
jobs:
|
|
10
|
+
prepare-data:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v3
|
|
15
|
+
|
|
16
|
+
- name: Download test datasets
|
|
17
|
+
run: |
|
|
18
|
+
set -e
|
|
19
|
+
rm -rf ./data && mkdir -p ./data
|
|
20
|
+
curl -o ./data/openslide-mirax.zip https://openslide.cs.cmu.edu/download/openslide-testdata/Mirax/Mirax2.2-4-PNG.zip
|
|
21
|
+
curl -o ./data/zeiss.zip https://datashare.biochem.mpg.de/s/k2C6sg0qrXBdWdc/download
|
|
22
|
+
curl -o ./data/blobs.zip https://datashare.biochem.mpg.de/s/0oTGB6xpUaWIaVh/download
|
|
23
|
+
curl -o ./data/triangles.zip https://datashare.biochem.mpg.de/s/zneNg7QxZNM2wSm/download
|
|
24
|
+
curl -o ./data/omics.zip https://datashare.biochem.mpg.de/s/a9bTNCXBYgE5n5S/download
|
|
25
|
+
|
|
26
|
+
- name: Unzip files
|
|
27
|
+
run: |
|
|
28
|
+
unzip ./data/openslide-mirax.zip -d ./data/openslide-mirax
|
|
29
|
+
unzip ./data/zeiss.zip -d ./data/zeiss
|
|
30
|
+
unzip ./data/blobs.zip -d ./data/blobs
|
|
31
|
+
unzip ./data/triangles.zip -d ./data
|
|
32
|
+
unzip ./data/omics.zip -d ./data
|
|
33
|
+
|
|
34
|
+
- name: Remove archives
|
|
35
|
+
run: |
|
|
36
|
+
rm ./data/openslide-mirax.zip
|
|
37
|
+
rm ./data/zeiss.zip
|
|
38
|
+
rm ./data/blobs.zip
|
|
39
|
+
rm ./data/triangles.zip
|
|
40
|
+
rm ./data/omics.zip
|
|
41
|
+
|
|
42
|
+
- name: Upload artifacts
|
|
43
|
+
uses: actions/upload-artifact@v4
|
|
44
|
+
with:
|
|
45
|
+
name: data
|
|
46
|
+
path: ./data
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
|
|
7
|
+
# Use "trusted publishing", see https://docs.pypi.org/trusted-publishers/
|
|
8
|
+
jobs:
|
|
9
|
+
release:
|
|
10
|
+
name: Upload release to PyPI
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
environment:
|
|
13
|
+
name: pypi
|
|
14
|
+
url: https://pypi.org/p/dvpio
|
|
15
|
+
permissions:
|
|
16
|
+
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
with:
|
|
20
|
+
filter: blob:none
|
|
21
|
+
fetch-depth: 0
|
|
22
|
+
- uses: actions/setup-python@v5
|
|
23
|
+
with:
|
|
24
|
+
python-version: "3.x"
|
|
25
|
+
cache: "pip"
|
|
26
|
+
- run: pip install build
|
|
27
|
+
- run: python -m build
|
|
28
|
+
- name: Publish package distributions to PyPI
|
|
29
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
name: Test
|
|
2
|
+
|
|
3
|
+
permissions:
|
|
4
|
+
actions: read
|
|
5
|
+
contents: read
|
|
6
|
+
|
|
7
|
+
on:
|
|
8
|
+
push:
|
|
9
|
+
branches: [main]
|
|
10
|
+
pull_request:
|
|
11
|
+
branches: [main]
|
|
12
|
+
schedule:
|
|
13
|
+
- cron: "0 5 1,15 * *"
|
|
14
|
+
|
|
15
|
+
concurrency:
|
|
16
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
17
|
+
cancel-in-progress: true
|
|
18
|
+
|
|
19
|
+
jobs:
|
|
20
|
+
test:
|
|
21
|
+
runs-on: ${{ matrix.os }}
|
|
22
|
+
defaults:
|
|
23
|
+
run:
|
|
24
|
+
shell: bash -e {0} # -e to fail on error
|
|
25
|
+
|
|
26
|
+
strategy:
|
|
27
|
+
fail-fast: false
|
|
28
|
+
matrix:
|
|
29
|
+
include:
|
|
30
|
+
- os: ubuntu-latest
|
|
31
|
+
python: "3.10"
|
|
32
|
+
- os: ubuntu-latest
|
|
33
|
+
python: "3.11"
|
|
34
|
+
- os: ubuntu-latest
|
|
35
|
+
python: "3.11"
|
|
36
|
+
pip-flags: "--pre"
|
|
37
|
+
name: PRE-RELEASE DEPENDENCIES
|
|
38
|
+
|
|
39
|
+
name: ${{ matrix.name }} Python ${{ matrix.python }}
|
|
40
|
+
|
|
41
|
+
env:
|
|
42
|
+
OS: ${{ matrix.os }}
|
|
43
|
+
PYTHON: ${{ matrix.python }}
|
|
44
|
+
|
|
45
|
+
steps:
|
|
46
|
+
- uses: actions/checkout@v4
|
|
47
|
+
- name: Set up Python ${{ matrix.python }}
|
|
48
|
+
uses: actions/setup-python@v5
|
|
49
|
+
with:
|
|
50
|
+
python-version: ${{ matrix.python }}
|
|
51
|
+
cache: "pip"
|
|
52
|
+
cache-dependency-path: "**/pyproject.toml"
|
|
53
|
+
|
|
54
|
+
- name: Download artifact of test data
|
|
55
|
+
uses: dawidd6/action-download-artifact@v6
|
|
56
|
+
with:
|
|
57
|
+
workflow: prepare_test_data.yaml
|
|
58
|
+
name: data
|
|
59
|
+
path: ./data
|
|
60
|
+
|
|
61
|
+
- name: Install test dependencies
|
|
62
|
+
run: |
|
|
63
|
+
python -m pip install --upgrade pip wheel
|
|
64
|
+
|
|
65
|
+
- name: Install dependencies
|
|
66
|
+
run: |
|
|
67
|
+
pip install ${{ matrix.pip-flags }} ".[dev,test]"
|
|
68
|
+
|
|
69
|
+
- name: Test
|
|
70
|
+
env:
|
|
71
|
+
MPLBACKEND: agg
|
|
72
|
+
PLATFORM: ${{ matrix.os }}
|
|
73
|
+
DISPLAY: :42
|
|
74
|
+
run: |
|
|
75
|
+
coverage run -m pytest -v --color=yes
|
|
76
|
+
|
|
77
|
+
- name: Report coverage
|
|
78
|
+
run: |
|
|
79
|
+
coverage report
|
|
80
|
+
- name: Upload coverage
|
|
81
|
+
uses: codecov/codecov-action@v3
|
|
82
|
+
env:
|
|
83
|
+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
dvp_io-0.2.2/.gitignore
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Temp files
|
|
2
|
+
.DS_Store
|
|
3
|
+
*~
|
|
4
|
+
buck-out/
|
|
5
|
+
|
|
6
|
+
# Compiled files
|
|
7
|
+
.venv/
|
|
8
|
+
__pycache__/
|
|
9
|
+
.*cache/
|
|
10
|
+
|
|
11
|
+
# Distribution / packaging
|
|
12
|
+
/dist/
|
|
13
|
+
|
|
14
|
+
# Tests and coverage
|
|
15
|
+
/data/
|
|
16
|
+
/node_modules/
|
|
17
|
+
|
|
18
|
+
# docs
|
|
19
|
+
/docs/generated/
|
|
20
|
+
/docs/_build/
|
|
21
|
+
/docs/tutorials/mock-data/*
|
|
22
|
+
/docs/tutorials/data/*
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
.coverage
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
fail_fast: false
|
|
2
|
+
default_language_version:
|
|
3
|
+
python: python3
|
|
4
|
+
default_stages:
|
|
5
|
+
- pre-commit
|
|
6
|
+
- pre-push
|
|
7
|
+
minimum_pre_commit_version: 2.16.0
|
|
8
|
+
repos:
|
|
9
|
+
- repo: https://github.com/pre-commit/mirrors-prettier
|
|
10
|
+
rev: v4.0.0-alpha.8
|
|
11
|
+
hooks:
|
|
12
|
+
- id: prettier
|
|
13
|
+
- repo: https://github.com/tox-dev/pyproject-fmt
|
|
14
|
+
rev: v2.5.0
|
|
15
|
+
hooks:
|
|
16
|
+
- id: pyproject-fmt
|
|
17
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
18
|
+
rev: v0.8.3
|
|
19
|
+
hooks:
|
|
20
|
+
- id: ruff
|
|
21
|
+
types_or: [python, pyi, jupyter]
|
|
22
|
+
args: [--fix, --exit-non-zero-on-fix]
|
|
23
|
+
- id: ruff-format
|
|
24
|
+
types_or: [python, pyi, jupyter]
|
|
25
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
26
|
+
rev: v5.0.0
|
|
27
|
+
hooks:
|
|
28
|
+
- id: detect-private-key
|
|
29
|
+
- id: check-ast
|
|
30
|
+
- id: end-of-file-fixer
|
|
31
|
+
- id: mixed-line-ending
|
|
32
|
+
args: [--fix=lf]
|
|
33
|
+
- id: trailing-whitespace
|
|
34
|
+
- id: check-case-conflict
|
|
35
|
+
# Check that there are no merge conflicts (could be generated by template sync)
|
|
36
|
+
- id: check-merge-conflict
|
|
37
|
+
args: [--assume-in-merge]
|
|
38
|
+
- repo: local
|
|
39
|
+
hooks:
|
|
40
|
+
- id: forbid-to-commit
|
|
41
|
+
name: Don't commit rej files
|
|
42
|
+
entry: |
|
|
43
|
+
Cannot commit .rej files. These indicate merge conflicts that arise during automated template updates.
|
|
44
|
+
Fix the merge conflicts manually and remove the .rej files.
|
|
45
|
+
language: fail
|
|
46
|
+
files: '.*\.rej$'
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# https://docs.readthedocs.io/en/stable/config-file/v2.html
|
|
2
|
+
version: 2
|
|
3
|
+
build:
|
|
4
|
+
os: ubuntu-20.04
|
|
5
|
+
tools:
|
|
6
|
+
python: "3.10"
|
|
7
|
+
apt_packages:
|
|
8
|
+
- libssh2-1
|
|
9
|
+
- libssh2-1.dev
|
|
10
|
+
sphinx:
|
|
11
|
+
configuration: docs/conf.py
|
|
12
|
+
# disable this for more lenient docs builds
|
|
13
|
+
fail_on_warning: true
|
|
14
|
+
python:
|
|
15
|
+
install:
|
|
16
|
+
- method: pip
|
|
17
|
+
path: .
|
|
18
|
+
extra_requirements:
|
|
19
|
+
- doc
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"recommendations": [
|
|
3
|
+
// GitHub integration
|
|
4
|
+
"github.vscode-github-actions",
|
|
5
|
+
"github.vscode-pull-request-github",
|
|
6
|
+
// Language support
|
|
7
|
+
"ms-python.python",
|
|
8
|
+
"ms-python.vscode-pylance",
|
|
9
|
+
"ms-toolsai.jupyter",
|
|
10
|
+
"tamasfe.even-better-toml",
|
|
11
|
+
// Dependency management
|
|
12
|
+
"ninoseki.vscode-mogami",
|
|
13
|
+
// Linting and formatting
|
|
14
|
+
"editorconfig.editorconfig",
|
|
15
|
+
"charliermarsh.ruff",
|
|
16
|
+
"esbenp.prettier-vscode",
|
|
17
|
+
],
|
|
18
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
// Use IntelliSense to learn about possible attributes.
|
|
3
|
+
// Hover to view descriptions of existing attributes.
|
|
4
|
+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
|
5
|
+
"version": "0.2.0",
|
|
6
|
+
"configurations": [
|
|
7
|
+
{
|
|
8
|
+
"name": "Python: Build Documentation",
|
|
9
|
+
"type": "debugpy",
|
|
10
|
+
"request": "launch",
|
|
11
|
+
"module": "sphinx",
|
|
12
|
+
"args": ["-M", "html", ".", "_build"],
|
|
13
|
+
"cwd": "${workspaceFolder}/docs",
|
|
14
|
+
"console": "internalConsole",
|
|
15
|
+
"justMyCode": false,
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"name": "Python: Debug Test",
|
|
19
|
+
"type": "debugpy",
|
|
20
|
+
"request": "launch",
|
|
21
|
+
"program": "${file}",
|
|
22
|
+
"purpose": ["debug-test"],
|
|
23
|
+
"console": "internalConsole",
|
|
24
|
+
"justMyCode": false,
|
|
25
|
+
"env": {
|
|
26
|
+
"PYTEST_ADDOPTS": "--color=yes",
|
|
27
|
+
},
|
|
28
|
+
"presentation": {
|
|
29
|
+
"hidden": true,
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
],
|
|
33
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"[python][jsonc][yaml]": {
|
|
3
|
+
"editor.formatOnSave": true,
|
|
4
|
+
},
|
|
5
|
+
"[python]": {
|
|
6
|
+
"editor.defaultFormatter": "charliermarsh.ruff",
|
|
7
|
+
"editor.codeActionsOnSave": {
|
|
8
|
+
"source.fixAll": "always",
|
|
9
|
+
"source.organizeImports": "always",
|
|
10
|
+
},
|
|
11
|
+
},
|
|
12
|
+
"[jsonc][yaml]": {
|
|
13
|
+
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
|
14
|
+
},
|
|
15
|
+
"python.analysis.typeCheckingMode": "basic",
|
|
16
|
+
"python.testing.pytestEnabled": true,
|
|
17
|
+
"python.testing.pytestArgs": ["-vv", "--color=yes"],
|
|
18
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# This CITATION.cff file was generated with cffinit.
|
|
2
|
+
# Visit https://bit.ly/cffinit to generate yours today!
|
|
3
|
+
|
|
4
|
+
cff-version: 1.2.0
|
|
5
|
+
title: dvp-io
|
|
6
|
+
message: >-
|
|
7
|
+
Read and write funtionalities from and to spatialdata for
|
|
8
|
+
deep visual proteomics
|
|
9
|
+
type: software
|
|
10
|
+
authors:
|
|
11
|
+
- given-names: Lucas
|
|
12
|
+
family-names: Diedrich
|
|
13
|
+
email: diedrich@biochem.mpg.de
|
|
14
|
+
affiliation: Max-Planck-Institute of Biochemistry
|
|
15
|
+
name-suffix: †
|
|
16
|
+
orcid: "https://orcid.org/0009-0007-4884-1422"
|
|
17
|
+
repository-code: "https://github.com/lucas-diedrich/dvp-io"
|
|
18
|
+
url: "https://dvp-io.readthedocs.io/en/latest/index.html"
|
|
19
|
+
abstract: >
|
|
20
|
+
Read/write functions to and from spatialdata for Deep
|
|
21
|
+
Visual Proteomics
|
|
22
|
+
keywords:
|
|
23
|
+
- spatial-omics
|
|
24
|
+
- proteomics
|
|
25
|
+
license: Apache-2.0
|