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

ndarray

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ndarray - npm Package Compare versions

Comparing version 1.0.6 to 1.0.8

8

ndarray.js

@@ -115,3 +115,3 @@ "use strict"

code.push(["aproto.toJSON=function ", arrayName, "_toJSON(){return [", array_elements.join(","), "]}"].join(""))
code.push(["aproto.toString=function ", arrayName, "_toJSON(){return [", array_elements.join(","), "].join()}"].join(""))
code.push(["aproto.toString=function ", arrayName, "_toString(){return [", array_elements.join(","), "].join()}"].join(""))

@@ -191,3 +191,3 @@ for(var i=0; i<dimension; ++i) {

indices.map(function(i) {
return ["typeof i", i, "!=='number'?this._shape", i, ":i", i,"|0"].join("")
return ["(typeof i",i,"!=='number'||i",i,"<0)?this._shape", i, ":i", i,"|0"].join("")
}).join(","), ",",

@@ -204,3 +204,3 @@ indices.map(function(i) {

code.push([
"if(typeof i", i, "==='number'){\
"if(typeof i",i,"==='number'&&i",i,">=0){\
d=i",i,"|0;\

@@ -259,3 +259,3 @@ b+=c",i,"*d;\

for(var i=0; i<dimension; ++i) {
code.push(["if(i",i,">=0){c=(c+this._stride",i,"*i",i,")|0}else{a.push(this._shape",i,");b.push(this._stride",i,")}"].join(""))
code.push(["if(typeof i",i,"==='number'&&i",i,">=0){c=(c+this._stride",i,"*i",i,")|0}else{a.push(this._shape",i,");b.push(this._stride",i,")}"].join(""))
}

@@ -262,0 +262,0 @@ code.push("var ctor=CTOR_LIST[a.length];return ctor(this.data,a,b,c)}")

{
"name": "ndarray",
"version": "1.0.6",
"version": "1.0.8",
"description": "Multidimensional Arrays",

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

@@ -226,3 +226,3 @@ ndarray

As the above example illustrates, passing a non-numeric value to a coordinate in pick skips that index.
As the above example illustrates, passing a negative or non-numeric value to a coordinate in pick skips that index.

@@ -229,0 +229,0 @@ Credits

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