Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rle-ndarray

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rle-ndarray

Convert between ndarrays and rle volumes

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

rle-ndarray

Conversion between rle volumes and ndarrays

Install

npm install rle-ndarray

API

var convert = require("rle-ndarray")

convert.rle2array(volume[, bounds])

Converts an rle data structure into an ndarray

  • volume is the volume we are converting
  • `bounds is a bound on the region to convert (optional)

Returns An object containing a pair of ndarrays:

  • phase is the phase field of the volume
  • distance is the distance field of the volume

convert.array2rle(phase[, distance, offset])

Converts an ndarray into an rle data structure

  • phase an array of phases
  • distance approximate signed distance to boundary (default constant 1.0)
  • offset a translational offset which is applied to the array (default [0,0,0])

Returns An ndarray encoding the array

Credits

(c) 2013 Mikola Lysenko. MIT License

Keywords

FAQs

Package last updated on 10 Jul 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc