From 87a1403d5389bae3c1b74f30b12bd323a4871310 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 20 Oct 2025 21:25:06 +0000 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/pre-commit-hooks: v4.5.0 → v6.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.5.0...v6.0.0) - [github.com/astral-sh/ruff-pre-commit: v0.3.4 → v0.14.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.3.4...v0.14.1) - https://github.com/psf/black → https://github.com/psf/black-pre-commit-mirror - [github.com/psf/black-pre-commit-mirror: 24.3.0 → 25.9.0](https://github.com/psf/black-pre-commit-mirror/compare/24.3.0...25.9.0) --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d48b2510..9730d982 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.5.0 + rev: v6.0.0 hooks: - id: check-docstring-first - id: end-of-file-fixer @@ -8,11 +8,11 @@ repos: exclude: ^\.napari-hub/.* - id: check-yaml # checks for correct yaml syntax for github actions ex. - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.3.4 + rev: v0.14.1 hooks: - id: ruff - - repo: https://github.com/psf/black - rev: 24.3.0 + - repo: https://github.com/psf/black-pre-commit-mirror + rev: 25.9.0 hooks: - id: black - repo: https://github.com/tlambert03/napari-plugin-checks From 115cf05ce5dd8a8fa50a93e00410caec298c5cd0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 20 Oct 2025 21:25:16 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- notebooks/demo_biological_data.ipynb | 9 ++------- notebooks/demo_cluster_export.ipynb | 7 +++++-- notebooks/demo_new_plotter.ipynb | 8 ++++---- notebooks/demo_new_reduction.ipynb | 12 ++++++------ notebooks/demo_shapes_clustering.ipynb | 14 +++++--------- 5 files changed, 22 insertions(+), 28 deletions(-) diff --git a/notebooks/demo_biological_data.ipynb b/notebooks/demo_biological_data.ipynb index 5f8aa19e..1f34d1bc 100644 --- a/notebooks/demo_biological_data.ipynb +++ b/notebooks/demo_biological_data.ipynb @@ -6,15 +6,10 @@ "metadata": {}, "outputs": [], "source": [ - "import glob\n", - "import pandas as pd\n", - "from pathlib import Path\n", - "import numpy as np\n", - "from skimage import io, measure\n", "\n", "import napari\n", - "import napari_clusters_plotter as ncp\n", - "import napari_segment_blobs_and_things_with_membranes as nsbatwm" + "\n", + "import napari_clusters_plotter as ncp" ] }, { diff --git a/notebooks/demo_cluster_export.ipynb b/notebooks/demo_cluster_export.ipynb index 45db8147..f00cdefe 100644 --- a/notebooks/demo_cluster_export.ipynb +++ b/notebooks/demo_cluster_export.ipynb @@ -8,9 +8,12 @@ "outputs": [], "source": [ "import napari\n", - "from napari.layers import Points\n", "import numpy as np\n", - "from napari_clusters_plotter._new_plotter_widget import _export_cluster_to_layer, PlotterWidget" + "from napari.layers import Points\n", + "\n", + "from napari_clusters_plotter._new_plotter_widget import (\n", + " PlotterWidget,\n", + ")" ] }, { diff --git a/notebooks/demo_new_plotter.ipynb b/notebooks/demo_new_plotter.ipynb index 12f8e005..cc78bba6 100644 --- a/notebooks/demo_new_plotter.ipynb +++ b/notebooks/demo_new_plotter.ipynb @@ -7,11 +7,11 @@ "outputs": [], "source": [ "import napari\n", - "from napari_clusters_plotter._new_plotter_widget import PlotterWidget\n", - "\n", - "from skimage import morphology, measure, data\n", "import numpy as np\n", - "import pandas as pd" + "import pandas as pd\n", + "from skimage import data, measure\n", + "\n", + "from napari_clusters_plotter._new_plotter_widget import PlotterWidget" ] }, { diff --git a/notebooks/demo_new_reduction.ipynb b/notebooks/demo_new_reduction.ipynb index a3b306a8..3df761a0 100644 --- a/notebooks/demo_new_reduction.ipynb +++ b/notebooks/demo_new_reduction.ipynb @@ -6,16 +6,16 @@ "metadata": {}, "outputs": [], "source": [ - "from napari_clusters_plotter._new_plotter_widget import PlotterWidget\n", - "from napari_clusters_plotter._dim_reduction_and_clustering import DimensionalityReductionWidget, ClusteringWidget\n", - "from napari_clusters_plotter._algorithms import reduce_pca\n", "import napari\n", "import numpy as np\n", + "import pandas as pd\n", "from napari.layers import Points\n", "\n", - "from skimage import data, measure\n", - "\n", - "import pandas as pd" + "from napari_clusters_plotter._dim_reduction_and_clustering import (\n", + " ClusteringWidget,\n", + " DimensionalityReductionWidget,\n", + ")\n", + "from napari_clusters_plotter._new_plotter_widget import PlotterWidget" ] }, { diff --git a/notebooks/demo_shapes_clustering.ipynb b/notebooks/demo_shapes_clustering.ipynb index 3f9b85cd..db9522d5 100644 --- a/notebooks/demo_shapes_clustering.ipynb +++ b/notebooks/demo_shapes_clustering.ipynb @@ -6,15 +6,11 @@ "metadata": {}, "outputs": [], "source": [ - "import glob\n", - "import pandas as pd\n", - "from pathlib import Path\n", + "import napari\n", "import numpy as np\n", - "from skimage import io, measure\n", + "import pandas as pd\n", "\n", - "import napari\n", - "import napari_clusters_plotter as ncp\n", - "import napari_segment_blobs_and_things_with_membranes as nsbatwm" + "import napari_clusters_plotter as ncp" ] }, { @@ -49,8 +45,8 @@ "source": [ "# random centers\n", "box_centers = np.random.random((20, 2)) * 1000\n", - "box_widths = np.random.random((20)) * 100\n", - "box_heights = np.random.random((20)) * 100\n", + "box_widths = np.random.random(20) * 100\n", + "box_heights = np.random.random(20) * 100\n", "features = pd.DataFrame({'box_widths': box_widths, 'box_heights': box_heights})\n", "features['area'] = features['box_widths'] * features['box_heights']\n", "\n",