Skip to main content

Neuroglancer compressed_segmentation codec.

Project description

NOTE: This repository is the PyPI distribution repo but is based on work done by Jeremy Maitin-Shepard (Google), Stephen Plaza (Janelia Research Campus), and William Silversmith (Princeton) here: https://github.com/janelia-flyem/compressedseg

# Compress Seg [![Picture](https://raw.github.com/janelia-flyem/janelia-flyem.github.com/master/images/HHMI_Janelia_Color_Alternate_180x40.png)](http://www.janelia.org)
## Library for compressing and decompressing image segmentation (adapted from [neuroglancer](https://github.com/google/neuroglancer))

This library contains routined to decompress and compress segmentation and to manipulate compressed segmentation data defined by the [neuroglancer project](https://github.com/google/neuroglancer/blob/master/src/neuroglancer/sliceview/compressed_segmentation/README.md).

### Features

* Compression and decompression
* (TBD) Interface to relabel and manipulate segmentation from the compressed data
* C++, Python, and Go interface (see original repo for Golang)

### C++ Compilation

Compiling as a shared library. Feel free to subsititute e.g. clang for the C++ compiler.

```bash
g++ -std=c++11 -O3 -fPIC -shared -I./include src/compress_segmentation.cc src/decompress_segmentation.cc -o compress_segmentation.so
```

### Python Installation

_Requires a C++ compiler such as g++ or clang._

Works with both Python 2 and 3. Encodes from / decodes to 3D or 4D numpy ndarrays.

```bash
$ pip install -r requirements.txt
$ python setup.py install

$ python
>>> import compressed_segmentation as cseg
>>> help(cseg)
```

### License

Please see the licenses in this repo.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for compressed-segmentation, version 1.0.0
Filename, size File type Python version Upload date Hashes
Filename, size compressed_segmentation-1.0.0-cp27-cp27m-macosx_10_14_intel.whl (110.4 kB) File type Wheel Python version cp27 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp27-cp27m-manylinux1_x86_64.whl (496.3 kB) File type Wheel Python version cp27 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp34-cp34m-manylinux1_x86_64.whl (495.1 kB) File type Wheel Python version cp34 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp35-cp35m-manylinux1_x86_64.whl (495.0 kB) File type Wheel Python version cp35 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp36-cp36m-macosx_10_13_x86_64.whl (105.2 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp36-cp36m-manylinux1_x86_64.whl (499.2 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp36-cp36m-win_amd64.whl (109.8 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp37-cp37m-macosx_10_9_x86_64.whl (105.4 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp37-cp37m-manylinux1_x86_64.whl (498.3 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp37-cp37m-win_amd64.whl (94.6 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp38-cp38-macosx_10_9_x86_64.whl (107.0 kB) File type Wheel Python version cp38 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0-cp38-cp38-manylinux1_x86_64.whl (507.4 kB) File type Wheel Python version cp38 Upload date Hashes View
Filename, size compressed_segmentation-1.0.0.tar.gz (149.3 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page