New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@tensorflow/tfjs-converter

Package Overview
Dependencies
Maintainers
10
Versions
155
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tensorflow/tfjs-converter - npm Package Compare versions

Comparing version 3.2.0 to 3.3.0

4

dist/executor/hash_table.d.ts

@@ -43,2 +43,6 @@ /**

/**
* The number of items in the hash table as a rank-0 tensor.
*/
tensorSize(): Tensor;
/**
* Replaces the contents of the table with the specified keys and values.

@@ -45,0 +49,0 @@ * @param keys Keys to store in the hashtable.

@@ -18,2 +18,4 @@ /**

import { keep, scalar, stack, tidy, unstack, util } from '@tensorflow/tfjs-core';
// tslint:disable-next-line: no-imports-from-dist
import * as tfOps from '@tensorflow/tfjs-core/dist/ops/ops_for_converter';
/**

@@ -55,2 +57,8 @@ * Hashtable contains a set of tensors, which can be accessed by key.

/**
* The number of items in the hash table as a rank-0 tensor.
*/
tensorSize() {
return tfOps.scalar(this.size(), 'int32');
}
/**
* Replaces the contents of the table with the specified keys and values.

@@ -57,0 +65,0 @@ * @param keys Keys to store in the hashtable.

2

dist/executor/model_analysis.js

@@ -131,3 +131,3 @@ /**

'HashTable', 'HashTableV2', 'LookupTableImport', 'LookupTableImportV2',
'LookupTableFind', 'LookupTableFindV2'
'LookupTableFind', 'LookupTableFindV2', 'LookupTableSize', 'LookupTableSizeV2'
];

@@ -134,0 +134,0 @@ export function isControlFlow(node) {

@@ -45,2 +45,8 @@ /**

}
case 'LookupTableSize':
case 'LookupTableSizeV2': {
const handle = getParamValue('tableHandle', node, tensorMap, context, resourceManager);
const hashTable = resourceManager.getHashTableById(handle.id);
return [hashTable.tensorSize()];
}
default:

@@ -47,0 +53,0 @@ throw TypeError(`Node type ${node.op} is not implemented`);

@@ -99,4 +99,18 @@ export const json = [

]
},
{
'tfOpName': 'LookupTableSize',
'category': 'hash_table',
'inputs': [
{ 'start': 0, 'name': 'tableHandle', 'type': 'tensor' }
]
},
{
'tfOpName': 'LookupTableSizeV2',
'category': 'hash_table',
'inputs': [
{ 'start': 0, 'name': 'tableHandle', 'type': 'tensor' }
]
}
];
//# sourceMappingURL=hash_table.js.map
/** @license See the LICENSE file. */
declare const version = "3.2.0";
declare const version = "3.3.0";
export { version };
/** @license See the LICENSE file. */
// This code is auto-generated, do not modify this file!
const version = '3.2.0';
const version = '3.3.0';
export { version };
//# sourceMappingURL=version.js.map

@@ -261,2 +261,4 @@ {

"LookupTableImportV2": [],
"LookupTableSize": [],
"LookupTableSizeV2": [],
"LoopCond": [],

@@ -263,0 +265,0 @@ "MatMul": [

{
"name": "@tensorflow/tfjs-converter",
"version": "3.2.0",
"version": "3.3.0",
"description": "Tensorflow model converter for javascript",

@@ -18,3 +18,3 @@ "main": "dist/tf-converter.node.js",

"peerDependencies": {
"@tensorflow/tfjs-core": "3.2.0"
"@tensorflow/tfjs-core": "3.3.0"
},

@@ -26,4 +26,4 @@ "devDependencies": {

"@rollup/plugin-typescript": "^3.0.0",
"@tensorflow/tfjs-backend-cpu": "3.2.0",
"@tensorflow/tfjs-core": "3.2.0",
"@tensorflow/tfjs-backend-cpu": "3.3.0",
"@tensorflow/tfjs-core": "3.3.0",
"@types/argparse": "^1.0.38",

@@ -30,0 +30,0 @@ "@types/deep-equal": "^1.0.1",

@@ -164,2 +164,3 @@ # Getting started

|<nobr>`--control_flow_v2`</nobr>| Only applicable to TF 2.x Saved Model. This flag improve performance on models with control flow ops, default to False.|
|<nobr>`--metadata`</nobr>| Comma separated list of metadata json file paths, indexed by name. Prefer absolute path. Example: 'metadata1:/metadata1.json,metadata2:/metadata2.json'.|

@@ -166,0 +167,0 @@ __Note: If you want to convert TensorFlow session bundle, you can install older versions of the tensorflowjs pip package, i.e. `pip install tensorflowjs==0.8.6`.__

@@ -18,2 +18,4 @@ /**

import {DataType, keep, scalar, stack, Tensor, tidy, unstack, util} from '@tensorflow/tfjs-core';
// tslint:disable-next-line: no-imports-from-dist
import * as tfOps from '@tensorflow/tfjs-core/dist/ops/ops_for_converter';

@@ -64,2 +66,9 @@ /**

/**
* The number of items in the hash table as a rank-0 tensor.
*/
tensorSize(): Tensor {
return tfOps.scalar(this.size(), 'int32');
}
/**
* Replaces the contents of the table with the specified keys and values.

@@ -66,0 +75,0 @@ * @param keys Keys to store in the hashtable.

@@ -158,3 +158,3 @@ /**

'HashTable', 'HashTableV2', 'LookupTableImport', 'LookupTableImportV2',
'LookupTableFind', 'LookupTableFindV2'
'LookupTableFind', 'LookupTableFindV2', 'LookupTableSize', 'LookupTableSizeV2'
];

@@ -161,0 +161,0 @@

@@ -68,2 +68,11 @@ /**

}
case 'LookupTableSize':
case 'LookupTableSizeV2': {
const handle = getParamValue(
'tableHandle', node, tensorMap, context,
resourceManager) as Tensor;
const hashTable = resourceManager.getHashTableById(handle.id);
return [hashTable.tensorSize()];
}
default:

@@ -70,0 +79,0 @@ throw TypeError(`Node type ${node.op} is not implemented`);

@@ -117,3 +117,17 @@ /**

]
},
{
'tfOpName': 'LookupTableSize',
'category': 'hash_table',
'inputs': [
{'start': 0, 'name': 'tableHandle', 'type': 'tensor'}
]
},
{
'tfOpName': 'LookupTableSizeV2',
'category': 'hash_table',
'inputs': [
{'start': 0, 'name': 'tableHandle', 'type': 'tensor'}
]
}
];
/** @license See the LICENSE file. */
// This code is auto-generated, do not modify this file!
const version = '3.2.0';
const version = '3.3.0';
export {version};

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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