Skip to content

Commit

Permalink
Merge pull request #2 from tlambert03/main
Browse files Browse the repository at this point in the history
move repo
  • Loading branch information
tlambert03 authored Jun 8, 2024
2 parents 5c05395 + 1b07c50 commit f6c3d14
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 18 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# ndv

[![License](https://img.shields.io/pypi/l/ndv.svg?color=green)](https://github.com/tlambert03/ndv/raw/main/LICENSE)
[![License](https://img.shields.io/pypi/l/ndv.svg?color=green)](https://github.com/pyapp-kit/ndv/raw/main/LICENSE)
[![PyPI](https://img.shields.io/pypi/v/ndv.svg?color=green)](https://pypi.org/project/ndv)
[![Python Version](https://img.shields.io/pypi/pyversions/ndv.svg?color=green)](https://python.org)
[![CI](https://github.com/tlambert03/ndv/actions/workflows/ci.yml/badge.svg)](https://github.com/tlambert03/ndv/actions/workflows/ci.yml)
[![codecov](https://codecov.io/gh/tlambert03/ndv/branch/main/graph/badge.svg)](https://codecov.io/gh/tlambert03/ndv)
[![CI](https://github.com/pyapp-kit/ndv/actions/workflows/ci.yml/badge.svg)](https://github.com/pyapp-kit/ndv/actions/workflows/ci.yml)
[![codecov](https://codecov.io/gh/pyapp-kit/ndv/branch/main/graph/badge.svg)](https://codecov.io/gh/pyapp-kit/ndv)

Simple, fast-loading, asynchronous, n-dimensional viewer for Qt, with minimal dependencies.

Expand All @@ -19,7 +19,7 @@ v.show()
qapp.exec()
```

![Montage](https://github.com/tlambert03/ndv/assets/1609449/712861f7-ddcb-4ecd-9a4c-ba5f0cc1ee2c)
![Montage](https://github.com/pyapp-kit/ndv/assets/1609449/712861f7-ddcb-4ecd-9a4c-ba5f0cc1ee2c)

## `NDViewer`

Expand Down
10 changes: 5 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,13 @@ dev = [
]

[project.urls]
homepage = "https://github.com/tlambert03/ndv"
repository = "https://github.com/tlambert03/ndv"
homepage = "https://github.com/pyapp-kit/ndv"
repository = "https://github.com/pyapp-kit/ndv"

# https://docs.astral.sh/ruff
[tool.ruff]
line-length = 88
target-version = "py38"
target-version = "py39"
src = ["src"]

# https://docs.astral.sh/ruff/rules
Expand All @@ -79,7 +79,7 @@ select = [
"TID", # flake8-tidy-imports
]
ignore = [
"D401", # First line should be in imperative mood (remove to opt in)
"D401", # First line should be in imperative mood
]

[tool.ruff.lint.per-file-ignores]
Expand Down Expand Up @@ -127,4 +127,4 @@ source = ["ndv"]
ignore = [".pre-commit-config.yaml", ".ruff_cache/**/*", "tests/**/*"]

[tool.typos.default]
extend-ignore-identifiers-re = ["(?i)nd2?.*", "(?i)ome", ".*ser_schema"]
extend-ignore-identifiers-re = ["(?i)nd2?.*", "(?i)ome", ".*ser_schema"]
3 changes: 2 additions & 1 deletion src/ndv/viewer/_dims_slider.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@
from superqt.utils import signals_blocked

if TYPE_CHECKING:
from typing import Hashable, Mapping, TypeAlias
from collections.abc import Hashable, Mapping
from typing import TypeAlias

from PyQt6.QtGui import QResizeEvent

Expand Down
5 changes: 1 addition & 4 deletions src/ndv/viewer/_indexing.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,12 @@
import sys
import warnings
from abc import abstractmethod
from collections.abc import Hashable, Iterable, Mapping, Sequence
from concurrent.futures import Future, ThreadPoolExecutor
from contextlib import suppress
from typing import (
TYPE_CHECKING,
Generic,
Hashable,
Iterable,
Mapping,
Sequence,
TypeVar,
cast,
)
Expand Down
4 changes: 3 additions & 1 deletion src/ndv/viewer/_lut_control.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from __future__ import annotations

from typing import TYPE_CHECKING, Any, Iterable, cast
from typing import TYPE_CHECKING, Any, cast

import numpy as np
from qtpy.QtCore import Qt
Expand All @@ -12,6 +12,8 @@
from ._dims_slider import SS

if TYPE_CHECKING:
from collections.abc import Iterable

import cmap

from ._protocols import PImageHandle
Expand Down
6 changes: 4 additions & 2 deletions src/ndv/viewer/_stack_viewer.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
from __future__ import annotations

from collections import defaultdict
from collections.abc import Iterable, Mapping, Sequence
from enum import Enum
from itertools import cycle
from typing import TYPE_CHECKING, Iterable, Literal, Mapping, Sequence, cast
from typing import TYPE_CHECKING, Literal, cast

import cmap
import numpy as np
Expand All @@ -17,8 +18,9 @@
from ._lut_control import LutControl

if TYPE_CHECKING:
from collections.abc import Hashable
from concurrent.futures import Future
from typing import Any, Callable, Hashable, TypeAlias
from typing import Any, Callable, TypeAlias

from qtpy.QtGui import QCloseEvent

Expand Down
3 changes: 2 additions & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import gc
from typing import TYPE_CHECKING, Iterator
from collections.abc import Iterator
from typing import TYPE_CHECKING

import pytest

Expand Down

0 comments on commit f6c3d14

Please sign in to comment.