Metadata-Version: 2.5
Name: napari-copick
Version: 2.0.0-alpha.1
Summary: A plugin for collaborative annotation in cryoET using copick
Project-URL: Repository, https://github.com/copick/napari-copick
Project-URL: Issues, https://github.com/copick/napari-copick/issues
Project-URL: Documentation, https://github.com/copick/napari-copick#README.md
Project-URL: Bug Tracker, https://github.com/copick/napari-copick/issues
Project-URL: Source Code, https://github.com/copick/napari-copick
Project-URL: User Support, https://github.com/copick/napari-copick/issues
Author-email: Kyle Harrington <czi@kyleharrington.com>, "Utz H. Ermel" <utz.ermel@czii.org>
License: 
        The MIT License (MIT)
        
        Copyright (c) 2024 Kyle Harrington
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in
        all copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
        THE SOFTWARE.
License-File: LICENSE
Keywords: annotation,copick,cryo-et,cryoet,napari,plugin,tomography
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Framework :: napari
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Topic :: Scientific/Engineering :: Image Processing
Requires-Python: >=3.11
Requires-Dist: click
Requires-Dist: copick-shared-ui<3,>=2.0.0a1
Requires-Dist: copick<3,>=2.0.0a1
Requires-Dist: fsspec
Requires-Dist: magicgui
Requires-Dist: napari
Requires-Dist: numpy>=2.0.2
Requires-Dist: pydantic>=2
Requires-Dist: qtpy
Requires-Dist: scikit-image
Requires-Dist: trimesh
Requires-Dist: zarr<4,>=3.1.6
Provides-Extra: dev
Requires-Dist: black>=25.1.0; extra == 'dev'
Requires-Dist: hatch-vcs>=0.4.0; extra == 'dev'
Requires-Dist: hatchling>=1.25.0; extra == 'dev'
Requires-Dist: pre-commit>=4.2.0; extra == 'dev'
Requires-Dist: ruff>=0.12.0; extra == 'dev'
Provides-Extra: testing
Requires-Dist: napari; extra == 'testing'
Requires-Dist: pyqt6; extra == 'testing'
Requires-Dist: pytest; extra == 'testing'
Requires-Dist: pytest-cov; extra == 'testing'
Requires-Dist: pytest-qt; extra == 'testing'
Requires-Dist: tox; extra == 'testing'
Requires-Dist: tox-gh-actions; extra == 'testing'
Requires-Dist: tox-uv; extra == 'testing'
Description-Content-Type: text/markdown

# napari-copick

[![License MIT](https://img.shields.io/pypi/l/napari-copick.svg?color=green)](https://github.com/copick/napari-copick/raw/main/LICENSE)
[![PyPI](https://img.shields.io/pypi/v/napari-copick.svg?color=green)](https://pypi.org/project/napari-copick)
[![Python Version](https://img.shields.io/pypi/pyversions/napari-copick.svg?color=green)](https://python.org)
[![tests](https://github.com/copick/napari-copick/workflows/tests/badge.svg)](https://github.com/copick/napari-copick/actions)
[![codecov](https://codecov.io/gh/copick/napari-copick/branch/main/graph/badge.svg)](https://codecov.io/gh/copick/napari-copick)
[![napari hub](https://img.shields.io/endpoint?url=https://api.napari-hub.org/shields/napari-copick)](https://napari-hub.org/plugins/napari-copick)

A plugin for collaborative annotation in cryoET using copick

![interface.png](https://github.com/copick/napari-copick/raw/main/docs/assets/interface.png)

----------------------------------

This [napari] plugin was generated with [Cookiecutter] using [@napari]'s [cookiecutter-napari-plugin] template.

<!--
Don't miss the full getting started guide to set up your new package:
https://github.com/napari/cookiecutter-napari-plugin#getting-started

and review the napari docs for plugin developers:
https://napari.org/stable/plugins/index.html
-->

## Installation

You can install `napari-copick` via [pip]:

    pip install napari-copick

Copick 2 / OME-Zarr 0.5 prereleases use the alpha channel:

    pip install --pre napari-copick

To install latest development version:

    pip install git+https://github.com/copick/napari-copick.git@v2.0

## Usage

### Using a copick config file

```bash
napari-copick run --config path/to/copick_config.json
```

### Using dataset IDs from CZ cryoET Data Portal

```bash
napari-copick run --dataset-ids 10440 10441 --overlay-root /path/to/overlay_root
```

You can specify multiple dataset IDs separated by spaces.

### GUI Usage

The plugin provides an intuitive interface with two loading options:

1. **Load Config File**: Opens a file dialog to select a copick configuration JSON file
2. **Load from Dataset IDs**: Opens a dialog to enter CZ cryoET Data Portal dataset IDs and overlay root path

After loading, you'll see a hierarchical tree of the project structure that you can navigate to access tomograms, segmentations, and picks.

### Tomogram Handling

napari-copick handles multiscale OME-Zarr arrays directly:

- Selects resolution levels from OME multiscale metadata, including non-numeric dataset paths
- Reads both legacy OME-Zarr 0.4 / Zarr v2 and OME-Zarr 0.5 / Zarr v3 stores
- Loads the selected resolution level into memory before adding it to napari
- Applies the selected dataset's OME coordinate transformation as the layer scale

This direct zarr handling provides better performance and more flexibility compared to relying on external plugins.

Volume reads use the Zarr store supplied by copick and require OME multiscales metadata. Stores written by copick 1.x
(OME-Zarr 0.4 / Zarr v2) and copick 2.x (OME-Zarr 0.5 / Zarr v3) are supported. Third-party stores that expose only
a root `data` array without OME multiscales metadata are intentionally unsupported; napari-copick does not infer a
dataset path from array names or root-key order. Storage backend access and retry behavior remain owned by copick.

## Contributing

Contributions are very welcome. Tests can be run with [tox], please ensure
the coverage at least stays the same before you submit a pull request.

## License

Distributed under the terms of the [MIT] license,
"napari-copick" is free and open source software

## Issues

If you encounter any problems, please [file an issue] along with a detailed description.

[napari]: https://github.com/napari/napari
[Cookiecutter]: https://github.com/audreyr/cookiecutter
[@napari]: https://github.com/napari
[MIT]: http://opensource.org/licenses/MIT
[cookiecutter-napari-plugin]: https://github.com/napari/cookiecutter-napari-plugin

[file an issue]: https://github.com/copick/napari-copick/issues

[napari]: https://github.com/napari/napari
[tox]: https://tox.readthedocs.io/en/latest/
[pip]: https://pypi.org/project/pip/
[PyPI]: https://pypi.org/

## Code of Conduct

This project adheres to the Contributor Covenant [code of conduct](https://github.com/chanzuckerberg/.github/blob/main/CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code. Please report unacceptable behavior to [opensource@chanzuckerberg.com](mailto:opensource@chanzuckerberg.com).

## Reporting Security Issues

If you believe you have found a security issue, please responsibly disclose by contacting us at [security@chanzuckerberg.com](mailto:security@chanzuckerberg.com).
