From 01a6c07640d97def1aaf63c71287f612d175e8fc Mon Sep 17 00:00:00 2001 From: chris-langfield Date: Tue, 27 Feb 2024 15:23:25 +0000 Subject: [PATCH 1/7] spruce README --- README.md | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 1d7cae0..ba13681 100644 --- a/README.md +++ b/README.md @@ -17,12 +17,21 @@ Install via `pip`: pip install poisson-numcodecs ``` -Or from sources: +### Developer installation ``` +conda create -n poisson_numcodecs python=3.xx +conda activate poisson_numcodecs git clone https://github.com/AllenNeuralDynamics/poisson-numcodecs.git cd poisson-numcodecs -pip install . +pip install -e . +``` + +Make sure everything works: + +``` +pip install pytest +pytest tests/ ``` ## Usage From 19e62cf5999644b8e00a99309c98ece5cf0f2de8 Mon Sep 17 00:00:00 2001 From: chris-langfield Date: Tue, 27 Feb 2024 16:01:28 +0000 Subject: [PATCH 2/7] simplify version and add requirements --- README.md | 1 + pyproject.toml | 6 ++---- requirements.txt | 4 +++- src/poisson_numcodecs/_version.py | 1 - 4 files changed, 6 insertions(+), 6 deletions(-) delete mode 100644 src/poisson_numcodecs/_version.py diff --git a/README.md b/README.md index ba13681..2f264ca 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,7 @@ conda create -n poisson_numcodecs python=3.xx conda activate poisson_numcodecs git clone https://github.com/AllenNeuralDynamics/poisson-numcodecs.git cd poisson-numcodecs +pip install -r requirements.txt pip install -e . ``` diff --git a/pyproject.toml b/pyproject.toml index 7fe29ac..27cbd8e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,12 +1,10 @@ [build-system] -requires = ["setuptools>=61.0", "setuptools_scm>=8"] +requires = ["setuptools>=61.0"] build-backend = "setuptools.build_meta" -[tool.setuptools_scm] -version_file = "_version.py" - [project] name = "poisson_numcodecs" +version = "0.1.0" authors = [ { name="Jerome Lecoq", email="jeromel@alleninstitute.org" }, ] diff --git a/requirements.txt b/requirements.txt index 3e0eec1..36ece49 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,4 +2,6 @@ numpy numcodecs zarr matplotlib -scipy \ No newline at end of file +scipy +scikit-learn +imageio diff --git a/src/poisson_numcodecs/_version.py b/src/poisson_numcodecs/_version.py deleted file mode 100644 index 9f7a875..0000000 --- a/src/poisson_numcodecs/_version.py +++ /dev/null @@ -1 +0,0 @@ -version = "0.1.0" From 7109c99e488f156b0679d9ba2a00625603118e97 Mon Sep 17 00:00:00 2001 From: chris-langfield Date: Tue, 27 Feb 2024 16:04:17 +0000 Subject: [PATCH 3/7] test yaml --- .github/workflows/{python-package.yml => tests.yaml} | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) rename .github/workflows/{python-package.yml => tests.yaml} (74%) diff --git a/.github/workflows/python-package.yml b/.github/workflows/tests.yaml similarity index 74% rename from .github/workflows/python-package.yml rename to .github/workflows/tests.yaml index fc44612..506ba54 100644 --- a/.github/workflows/python-package.yml +++ b/.github/workflows/tests.yaml @@ -1,4 +1,4 @@ -name: Python Package +name: poisson_numcodecs CI on: pull_request: @@ -13,7 +13,7 @@ jobs: strategy: fail-fast: false matrix: - os: ["ubuntu-latest", "macos-latest", "windows-latest"] + os: ["ubuntu-latest", "macos-latest"] steps: - uses: actions/checkout@v2 - uses: s-weigand/setup-conda@v1 @@ -21,9 +21,7 @@ jobs: python-version: 3.9 - name: Install dependencies run: | - pip install . - pip install zarr - pip install pytest + pip install -r requirements.txt - name: Test with pytest run: | pytest -v From 69fae1933338c51544534d88b09ffa30b501a0a5 Mon Sep 17 00:00:00 2001 From: chris-langfield Date: Tue, 27 Feb 2024 16:05:03 +0000 Subject: [PATCH 4/7] on push --- .github/workflows/tests.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 506ba54..2338c23 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -1,6 +1,9 @@ name: poisson_numcodecs CI on: + push: + branches: [main] + pull_request: branches: [main] types: [synchronize, opened, reopened, ready_for_review] From 80fd4b4628d78bf80a7f319dbf242184c5f116bd Mon Sep 17 00:00:00 2001 From: Chris Langfield <34426450+chris-langfield@users.noreply.github.com> Date: Tue, 27 Feb 2024 11:05:59 -0500 Subject: [PATCH 5/7] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2f264ca..987d72c 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -[![PyPI version](https://badge.fury.io/py/poisson-numcodecs.svg)](https://badge.fury.io/py/poisson-numcodecs) ![tests](https://github.com/AllenNeuralDynamics/poisson-numcodecs/actions/workflows/python-package.yml/badge.svg) +[![PyPI version](https://badge.fury.io/py/poisson-numcodecs.svg)](https://badge.fury.io/py/poisson-numcodecs) ![tests](https://github.com/AllenNeuralDynamics/poisson-numcodecs/actions/workflows/tests.yaml/badge.svg) # Poisson - numcodecs implementation @@ -63,4 +63,4 @@ Available `**kwargs` can be browsed with: `Poisson?` **NOTE:** In order to reload in zarr an array saved with the `Poisson`, you just need to have the `poisson_numcodecs` package -installed. \ No newline at end of file +installed. From 741f183a0f8b53e6754eaf2c77e8247b019c3e95 Mon Sep 17 00:00:00 2001 From: chris-langfield Date: Tue, 27 Feb 2024 16:06:49 +0000 Subject: [PATCH 6/7] oops need pytest --- .github/workflows/tests.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 2338c23..9a15ceb 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -3,7 +3,7 @@ name: poisson_numcodecs CI on: push: branches: [main] - + pull_request: branches: [main] types: [synchronize, opened, reopened, ready_for_review] @@ -25,6 +25,7 @@ jobs: - name: Install dependencies run: | pip install -r requirements.txt + pip install pytest - name: Test with pytest run: | pytest -v From 2fb3d3b584d4419f61944b06ecb62f92e4772372 Mon Sep 17 00:00:00 2001 From: chris-langfield Date: Tue, 27 Feb 2024 16:09:52 +0000 Subject: [PATCH 7/7] install this package as well --- .github/workflows/tests.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 9a15ceb..7bb333c 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -26,6 +26,7 @@ jobs: run: | pip install -r requirements.txt pip install pytest + pip install . - name: Test with pytest run: | pytest -v