pynrrd

Simple pure-python module for reading and writing nrrd files.

https://github.com/mhe/pynrrd

Science Score: 59.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 3 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
    6 of 23 committers (26.1%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (15.5%) to scientific vocabulary

Keywords

nrrd numpy python

Keywords from Contributors

dicom medical-imaging neuroimaging open-science qt workflow-engine dataflow-programming dataflow brainweb brain-imaging
Last synced: 6 months ago · JSON representation

Repository

Simple pure-python module for reading and writing nrrd files.

Basic Info
Statistics
  • Stars: 122
  • Watchers: 8
  • Forks: 54
  • Open Issues: 8
  • Releases: 21
Topics
nrrd numpy python
Created over 15 years ago · Last pushed about 1 year ago
Metadata Files
Readme License Authors

README.rst

.. image:: https://travis-ci.org/mhe/pynrrd.svg?branch=master
    :target: https://travis-ci.org/mhe/pynrrd
    :alt: Build Status

.. image:: https://zenodo.org/badge/DOI/10.5281/zenodo.592532.svg
   :target: https://doi.org/10.5281/zenodo.592532
   :alt: DOI

.. image:: https://img.shields.io/pypi/pyversions/pynrrd.svg
    :target: https://img.shields.io/pypi/pyversions/pynrrd.svg
    :alt: Python version

.. image:: https://badge.fury.io/py/pynrrd.svg
    :target: https://badge.fury.io/py/pynrrd
    :alt: PyPi version

.. image:: https://readthedocs.org/projects/pynrrd/badge/?version=stable
    :target: https://pynrrd.readthedocs.io/en/stable/?badge=stable
    :alt: Documentation Status

.. image:: https://codecov.io/gh/mhe/pynrrd/branch/master/graph/badge.svg
  :target: https://codecov.io/gh/mhe/pynrrd

|

pynrrd
======
pynrrd is a pure-Python module for reading and writing `NRRD `_ files into and
from numpy arrays.

Requirements
------------

* `numpy `_
* typing_extensions

v1.0+ requires Python 3.7 or above. If you have an older Python version, please install a v0.x release instead.

Installation
------------

Install via pip and PyPi repository (recommended)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: bash

    pip install pynrrd

Install via pip and GitHub
~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: bash

    pip install git+https://github.com/mhe/pynrrd.git

Install from source (recommended for contributing to pynrrd)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
For developers that want to contribute to pynrrd, you can clone the pynrrd repository and install it using the following commands:

.. code-block:: bash

    git clone https://github.com/mhe/pynrrd.git
    cd pynrrd
    pip install .

or, for the last line, instead use:

.. code-block:: bash

    pip install -e .

to install in 'develop' or 'editable' mode, where changes can be made to the local working code and Python will use
the updated pynrrd code.

**Tests**

The tests can be run via the following command from the base directory:

.. code-block:: bash

    python -m unittest discover -v nrrd/tests

**Format and Lint code**

 This repository uses pre-commit hooks to run format and lint the code and they are enforced in CI. See [pre-commit](https://pre-commit.com)

Example usage
-------------
.. code-block:: python

    import numpy as np
    import nrrd

    # Some sample numpy data
    data = np.zeros((5,4,3,2))
    filename = 'testdata.nrrd'

    # Write to a NRRD file
    nrrd.write(filename, data)

    # Read the data back from file
    readdata, header = nrrd.read(filename)
    print(readdata.shape)
    print(header)


Next Steps
----------
For more information, see the `documentation `_.

License
-------
See the `LICENSE `_ for more information.

Owner

  • Name: Maarten Everts
  • Login: mhe
  • Kind: user
  • Location: The Netherlands
  • Company: @linksight

GitHub Events

Total
  • Create event: 5
  • Release event: 4
  • Issues event: 6
  • Watch event: 8
  • Delete event: 1
  • Issue comment event: 11
  • Push event: 11
  • Pull request event: 25
  • Fork event: 3
Last Year
  • Create event: 5
  • Release event: 4
  • Issues event: 6
  • Watch event: 8
  • Delete event: 1
  • Issue comment event: 11
  • Push event: 11
  • Pull request event: 25
  • Fork event: 3

Committers

Last synced: 8 months ago

All Time
  • Total Commits: 240
  • Total Committers: 23
  • Avg Commits per committer: 10.435
  • Development Distribution Score (DDS): 0.533
Past Year
  • Commits: 15
  • Committers: 4
  • Avg Commits per committer: 3.75
  • Development Distribution Score (DDS): 0.2
Top Committers
Name Email Commits
Addison Elliott a****t@g****m 112
Maarten Everts m****n@b****m 59
Taylor Braun-Jones t****r@b****g 18
Robbie1977 r****t@g****m 8
Hans Johnson h****n@u****u 6
Isaiah Norton i****n 5
JDWarner w****a@m****u 4
Simon Pezold s****d@u****h 3
Ali Ghayoor a****r@u****u 3
Bernardo Pericacho Sánchez b****o@g****m 3
Hans Meine h****e@g****t 3
Peter Fischer y****d 3
Tashrif Billah t****h@g****m 2
Simon Ekström s****m@g****m 2
Bryn Lloyd d****b 1
Dan Brown 5****n 1
Eleftherios Zisis e****s@e****h 1
GFleishman g****e@g****m 1
JcNils j****s 1
Katrin Leinweber 9****r 1
Matthew Scheifer m****r@g****m 1
jackriccomini 2****i 1
Jasper van de Gronde j****e@r****l 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 44
  • Total pull requests: 86
  • Average time to close issues: 3 months
  • Average time to close pull requests: 4 days
  • Total issue authors: 28
  • Total pull request authors: 14
  • Average comments per issue: 3.68
  • Average comments per pull request: 1.45
  • Merged pull requests: 81
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 6
  • Pull requests: 21
  • Average time to close issues: 4 days
  • Average time to close pull requests: about 15 hours
  • Issue authors: 4
  • Pull request authors: 4
  • Average comments per issue: 2.0
  • Average comments per pull request: 0.33
  • Merged pull requests: 19
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • addisonElliott (7)
  • tashrifbillah (7)
  • eleftherioszisis (3)
  • mhe (2)
  • kishanbala (2)
  • prakharprakash (1)
  • NonlinearNimesh (1)
  • jcnils (1)
  • ihnorton (1)
  • wraith1995 (1)
  • GFleishman (1)
  • lguyot (1)
  • amegianeg (1)
  • AAAArcus (1)
  • Optimox (1)
Pull Request Authors
  • addisonElliott (71)
  • ihnorton (3)
  • tashrifbillah (3)
  • bernardopericacho (3)
  • eleftherioszisis (2)
  • mhalle (2)
  • simeks (2)
  • jackriccomini (2)
  • jasper-tms (1)
  • mscheifer (1)
  • GFleishman (1)
  • dyollb (1)
  • danb-pcs (1)
  • v4lli (1)
  • jcnils (1)
Top Labels
Issue Labels
help wanted (3) Follow Up Required (1) bug (1)
Pull Request Labels

Packages

  • Total packages: 3
  • Total downloads:
    • pypi 88,372 last-month
  • Total docker downloads: 6,557
  • Total dependent packages: 53
    (may contain duplicates)
  • Total dependent repositories: 241
    (may contain duplicates)
  • Total versions: 22
  • Total maintainers: 4
pypi.org: pynrrd

Pure python module for reading and writing NRRD files.

  • Homepage: https://github.com/mhe/pynrrd
  • Documentation: https://pynrrd.readthedocs.io/en/stable
  • License: Copyright (c) 2012 Maarten H. Everts and contributors. See AUTHORS for more details. 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.
  • Latest release: 1.1.3
    published about 1 year ago
  • Versions: 20
  • Dependent Packages: 51
  • Dependent Repositories: 240
  • Downloads: 88,372 Last month
  • Docker Downloads: 6,557
Rankings
Dependent packages count: 0.3%
Dependent repos count: 1.0%
Docker downloads count: 1.6%
Downloads: 1.8%
Average: 2.9%
Forks count: 6.0%
Stargazers count: 6.8%
Maintainers (3)
Last synced: 6 months ago
spack.io: py-pynrrd

Python library for reading and writing NRRD files into and from numpy arrays

  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
Rankings
Dependent repos count: 0.0%
Forks count: 15.7%
Stargazers count: 18.1%
Average: 22.8%
Dependent packages count: 57.3%
Maintainers (1)
Last synced: 6 months ago
conda-forge.org: pynrrd
  • Versions: 1
  • Dependent Packages: 2
  • Dependent Repositories: 1
Rankings
Dependent packages count: 19.6%
Dependent repos count: 24.3%
Average: 25.7%
Forks count: 26.1%
Stargazers count: 32.9%
Last synced: 6 months ago

Dependencies

docs/requirements.txt pypi
  • numpy >=1.11.1
  • numpydoc *
requirements.txt pypi
  • numpy >=1.11.1
setup.py pypi
  • numpy >=1.11.1
.github/workflows/lint.yml actions
  • actions/checkout v2 composite
  • actions/setup-python v3 composite
.github/workflows/pythonpublish.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v4 composite
  • pypa/gh-action-pypi-publish release/v1 composite
.github/workflows/test.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v3 composite
  • codecov/codecov-action v2 composite
pyproject.toml pypi
  • numpy >= 1.21
  • typing_extensions *