Skip to content

Commit

Permalink
updated packages
Browse files Browse the repository at this point in the history
  • Loading branch information
cpietsch authored Jun 19, 2022
1 parent f23fab9 commit 30d64b1
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 14 deletions.
20 changes: 10 additions & 10 deletions similarity/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vikus-viewer-tsne",
"version": "0.1.1",
"version": "0.1.2",
"description": "tsne preprocessing script for vikus-viewer",
"author": "Christopher Pietsch <cpietsch@gmail.com>",
"private": true,
Expand All @@ -11,15 +11,15 @@
},
"license": "MIT",
"dependencies": {
"@tensorflow-models/mobilenet": "^1.0.0",
"@tensorflow/tfjs": "^1.0.0",
"@tensorflow/tfjs-node": "^1.0.1",
"canvas": "^2.3.1",
"@tensorflow-models/mobilenet": "^2.1.0",
"@tensorflow/tfjs": "^3.18.0",
"@tensorflow/tfjs-node": "^3.18.0",
"canvas": "^2.9.1",
"d3": "^5.8.2",
"glob": "^7.1.3",
"glob-promise": "^3.4.0",
"minimist": "^1.2.0",
"node-fetch": "^2.3.0",
"umap-js": "^1.3.1"
"glob": "^7.1.6",
"glob-promise": "^4.2.2",
"minimist": "^1.2.6",
"node-fetch": "^3.2.6",
"umap-js": "^1.3.3"
}
}
8 changes: 6 additions & 2 deletions similarity/tsne.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,13 @@ async function run() {
// mobilenet = await tf.loadLayersModel(MOBILENET_MODEL_PATH);
mobilenet = await require('@tensorflow-models/mobilenet').load()

const files = await glob(inputPath + '/*.' + inputFormat)
let files = await glob(inputPath + '/*.' + inputFormat)
console.log("found files", files.length)
const subset = files.filter((d, i) => i < 100)
//files = files.filter((d, i) => i < 100)
if (files.length === 0) {
console.log("no files found")
return
}

const activations = await getActivations(files)
console.log("done activations", activations.length)
Expand Down
8 changes: 6 additions & 2 deletions similarity/umap.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,14 @@ async function run() {
// mobilenet = await tf.loadLayersModel(MOBILENET_MODEL_PATH);
mobilenet = await require('@tensorflow-models/mobilenet').load()

const files = await glob(inputPath + '/*.' + inputFormat)
let files = await glob(inputPath + '/*.' + inputFormat)
console.log(files)
console.log("found files", files.length)
const subset = files.filter((d, i) => i < 100)
if (files.length === 0) {
console.log("no files found")
return
}
//files = files.filter((d, i) => i < 100)

const activations = await getActivations(files)
console.log("done activations", activations.length)
Expand Down

0 comments on commit 30d64b1

Please sign in to comment.