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

ndarray-ops

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ndarray-ops - npm Package Compare versions

Comparing version 0.1.2 to 0.1.3

3

index.js

@@ -415,4 +415,5 @@ var cwise = require("cwise")

}
var result = ndarray(array.data.slice(0, tsz), array.shape.slice(0), stride, 0)
var ndata = new array.data.constructor(array.data.slice(0, tsz*array.data.BYTES_PER_ELEMENT))
var result = ndarray(ndata, array.shape.slice(0), stride, 0)
return exports.assign(result, array)
}
{
"name": "ndarray-ops",
"version": "0.1.2",
"version": "0.1.3",
"description": "Common operations for ndarray arrays",

@@ -5,0 +5,0 @@ "main": "index.js",

var ops = require("../index.js")
, ndarray = require("ndarray")
for(var i in ops) {
console.log("*", i)
}
require("tap").test("clone", function(t) {
var x = ndarray.zeros([3])
x.set(0, 1)
x.set(1, 2)
x.set(2, 3)
var y = ops.clone(x)
t.equals(y.get(0), 1)
t.equals(y.get(1), 2)
t.equals(y.get(2), 3)
y.set(0, 1000)
t.equals(x.get(0), 1)
t.equals(x.get(1), 2)
t.equals(x.get(2), 3)
t.equals(y.get(0), 1000)
t.equals(y.get(1), 2)
t.equals(y.get(2), 3)
t.end()
})
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