Skip to content

Commit 39e6afa

Browse files
authored
update mnist-core, sentiment and, date-conversion-attention to tfjs 3.0 (#385)
1 parent 298ba06 commit 39e6afa

File tree

7 files changed

+993
-714
lines changed

7 files changed

+993
-714
lines changed

Diff for: date-conversion-attention/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@
1515
"watch": "cross-env NODE_ENV=development parcel index.html --no-hmr --open"
1616
},
1717
"dependencies": {
18-
"@tensorflow/tfjs": "^2.6.0",
18+
"@tensorflow/tfjs": "3.0.0",
1919
"@tensorflow/tfjs-vis": "^1.4.3"
2020
},
2121
"devDependencies": {
22-
"@tensorflow/tfjs-node": "^2.6.0",
23-
"@tensorflow/tfjs-node-gpu": "^2.6.0",
22+
"@tensorflow/tfjs-node": "3.0.0",
23+
"@tensorflow/tfjs-node-gpu": "3.0.0",
2424
"argparse": "^1.0.10",
2525
"babel-cli": "^6.26.0",
2626
"babel-core": "^6.26.3",

Diff for: date-conversion-attention/yarn.lock

+53-54
Original file line numberDiff line numberDiff line change
@@ -651,63 +651,62 @@
651651
resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz#2b5a3ab3f918cca48a8c754c08168e3f03eba61b"
652652
integrity sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw==
653653

654-
"@tensorflow/tfjs-backend-cpu@2.6.0":
655-
version "2.6.0"
656-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-backend-cpu/-/tfjs-backend-cpu-2.6.0.tgz#bd0923ca438e945c4c9347a76e301a4fb1890d33"
657-
integrity sha512-essk82VoET77tuFX5Sa9zv9F8d/2DxjEQ2RavoU+ugs0l64DTbdTpv3WdQwUihv1gNN7/16fUjJ6cG80SnS8/g==
654+
"@tensorflow/tfjs-backend-cpu@3.0.0":
655+
version "3.0.0"
656+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-backend-cpu/-/tfjs-backend-cpu-3.0.0.tgz#73463192bd6965624260641a909fd273a7b0fa11"
657+
integrity sha512-W7IX+xga007cYiFmq+QpEuDCy8SK+fsiVwawfjMFN+Dfs2FFi7JW6cHCLun/SQ5WC7dTWOhJVTwCaSBWQz6bjw==
658658
dependencies:
659659
"@types/seedrandom" "2.4.27"
660660
seedrandom "2.4.3"
661661

662-
"@tensorflow/tfjs-backend-webgl@2.6.0":
663-
version "2.6.0"
664-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-backend-webgl/-/tfjs-backend-webgl-2.6.0.tgz#3855c254a86daf28511530c36bb61938acf26740"
665-
integrity sha512-j1eNYKIpO06CTSRXiIWdpZ2iPDBkx7PPl7K/1BtCEW/9FP7Q0q3doHKNmTdOPvuw7Dt1nNHEMnba0YB2lc5S7Q==
662+
"@tensorflow/tfjs-backend-webgl@3.0.0":
663+
version "3.0.0"
664+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-backend-webgl/-/tfjs-backend-webgl-3.0.0.tgz#9c6e7ee819731fe573c113892ae436f7d015cbeb"
665+
integrity sha512-ydgmwIMLQcX65I8CYXwuY03ShHi9atDn7WopjGb561/asWleL25kg/KfcZRQKbgbCFD3PRePvmW0ytqtXgDdpw==
666666
dependencies:
667-
"@tensorflow/tfjs-backend-cpu" "2.6.0"
667+
"@tensorflow/tfjs-backend-cpu" "3.0.0"
668668
"@types/offscreencanvas" "~2019.3.0"
669669
"@types/seedrandom" "2.4.27"
670670
"@types/webgl-ext" "0.0.30"
671-
"@types/webgl2" "0.0.4"
671+
"@types/webgl2" "0.0.5"
672672
seedrandom "2.4.3"
673673

674-
"@tensorflow/tfjs-converter@2.6.0":
675-
version "2.6.0"
676-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-converter/-/tfjs-converter-2.6.0.tgz#0de5c4c014c25d695ad17ca19e3b654dbcb84cea"
677-
integrity sha512-TzL4ULidZ26iVqfLmv5G6dfnJyJt5HttU1VZoBYCbxUcWQYk1Z4D9wqLVwfdcJz01XEKpmsECh8HBF0hwYlrkA==
674+
"@tensorflow/tfjs-converter@3.0.0":
675+
version "3.0.0"
676+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-converter/-/tfjs-converter-3.0.0.tgz#9b2b6406162a194ade36bcadf0161f9e0a42ae69"
677+
integrity sha512-3Mw7gLQiG65rap8EHKaoPxaWkwjz1hH8EbsDAaatW/ez5bWFY576hdmn/dXN56XOfdvNMDJjTgXTiU6VApH6Sg==
678678

679-
"@tensorflow/tfjs-core@2.6.0":
680-
version "2.6.0"
681-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-core/-/tfjs-core-2.6.0.tgz#ab2f2c9e8f46990643076d7d5bdb912885282bd2"
682-
integrity sha512-akUB1iz663UCUdOfEUu91XeHzGpdYtdtMPxjsGEdF0CwENzSAcvHzQrEVoPBRD+RKpxrVXvQBoOd7GYBxMIIKQ==
679+
"@tensorflow/tfjs-core@3.0.0":
680+
version "3.0.0"
681+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-core/-/tfjs-core-3.0.0.tgz#1d5a87f225c3e7cb77f670dbd2d8a3f3e5f6d8e8"
682+
integrity sha512-bqE6q8afvXtTa21T27+/YIqwj0wvoH3leeAl8ciNvGuOVmYA69hIaDfwthSA8WsvqR0BQDK+8qDxR/BEUtmj7g==
683683
dependencies:
684684
"@types/offscreencanvas" "~2019.3.0"
685685
"@types/seedrandom" "2.4.27"
686686
"@types/webgl-ext" "0.0.30"
687-
"@types/webgl2" "0.0.4"
688687
node-fetch "~2.6.1"
689688
seedrandom "2.4.3"
690689

691-
"@tensorflow/tfjs-data@2.6.0":
692-
version "2.6.0"
693-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-data/-/tfjs-data-2.6.0.tgz#005fb204822322bc652ddd968c15a6b1a295652a"
694-
integrity sha512-/x/j/A4Quiyc21xEYyBC82mqyssbFHRuHez7pYVJA/28TOesAfWPWo2I+wkeOTt91UerUeZMSq2FV3HOnPInhQ==
690+
"@tensorflow/tfjs-data@3.0.0":
691+
version "3.0.0"
692+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-data/-/tfjs-data-3.0.0.tgz#d74bc94b289b9faa8c14db083043ef652186a8a2"
693+
integrity sha512-pZjs8Z+7vD6Y0wnEIUP6qca4+db4C6v1lsV0QAgSqbnfOMz2QxQNorKxTqbrNP1mYkpqfxqR/5mLe+tD7gy36w==
695694
dependencies:
696695
"@types/node-fetch" "^2.1.2"
697696
node-fetch "~2.6.1"
698697

699-
"@tensorflow/tfjs-layers@2.6.0":
700-
version "2.6.0"
701-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-layers/-/tfjs-layers-2.6.0.tgz#fed57ff6514f3fbb78fbcd2d40a09e9bd8d52cfc"
702-
integrity sha512-nU9WNSGpEU6GzKo5bvJBMa/OZRe1bR5Z2W6T0XiEY8CBiPNS+oJFJNm0NY8kQj/WnDS0Hfue38P46q7gV/9XMA==
698+
"@tensorflow/tfjs-layers@3.0.0":
699+
version "3.0.0"
700+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-layers/-/tfjs-layers-3.0.0.tgz#23dd55cec7a2e8c2acb35f23b0f3c881f303810a"
701+
integrity sha512-nNtWXycmlEm56cFMXvTzS4Wr4rslgBbFJ6PC47Qbtl0qSfwV57qNTifDr4VOb9yCovOPiPUZGsi3FTaSr23Q5g==
703702

704-
"@tensorflow/tfjs-node-gpu@^2.6.0":
705-
version "2.6.0"
706-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-node-gpu/-/tfjs-node-gpu-2.6.0.tgz#f7e386c4c3d2011144b65814972215afa4a2d139"
707-
integrity sha512-ZA5GUZ8ug+tcaURiwAvJhfU/r/3hORIEjrECFyKd+dFOST/9EF2KsDir05gkp3P/9nx+0W+4mxIsAff5RCa63A==
703+
"@tensorflow/tfjs-node-gpu@3.0.0":
704+
version "3.0.0"
705+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-node-gpu/-/tfjs-node-gpu-3.0.0.tgz#5889b5cff6cb3bfe245e4e72340a422aa4b12719"
706+
integrity sha512-K0VNB0saaHihbSyS6utFZI7hXsAOhWZsRjFEj38PUS9kA7Li7PBA6u6/rhlRFfjID44SsvhbpaWN8HsFv+brXw==
708707
dependencies:
709-
"@tensorflow/tfjs" "2.6.0"
710-
"@tensorflow/tfjs-core" "2.6.0"
708+
"@tensorflow/tfjs" "3.0.0"
709+
"@tensorflow/tfjs-core" "3.0.0"
711710
adm-zip "^0.4.11"
712711
google-protobuf "^3.9.2"
713712
https-proxy-agent "^2.2.1"
@@ -716,13 +715,13 @@
716715
rimraf "^2.6.2"
717716
tar "^4.4.6"
718717

719-
"@tensorflow/tfjs-node@^2.6.0":
720-
version "2.6.0"
721-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-node/-/tfjs-node-2.6.0.tgz#d9ace4156af36760cad397fa83240b4a92e6597e"
722-
integrity sha512-Yp1PICAVD3jBhqEShlzZHC9uOtT8axpFeciw8TeI4KxnIydWQOnrisI09z6uR7shCwNY4TM6txhpkO5b/RDyvw==
718+
"@tensorflow/tfjs-node@3.0.0":
719+
version "3.0.0"
720+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs-node/-/tfjs-node-3.0.0.tgz#3cc512bf4eaabb5e77d95ff3089e36b036560496"
721+
integrity sha512-eeZIst3uZZ3iYj/8YiCE6nZUSNP9ISgQ9Y3BgrWp3EnySvuZv03F+XWSZ/8mNjyq4S0pBzbt08u5dY7jBRP5Tg==
723722
dependencies:
724-
"@tensorflow/tfjs" "2.6.0"
725-
"@tensorflow/tfjs-core" "2.6.0"
723+
"@tensorflow/tfjs" "3.0.0"
724+
"@tensorflow/tfjs-core" "3.0.0"
726725
adm-zip "^0.4.11"
727726
google-protobuf "^3.9.2"
728727
https-proxy-agent "^2.2.1"
@@ -744,17 +743,17 @@
744743
vega-embed "6.8.0"
745744
vega-lite "4.13.1"
746745

747-
"@tensorflow/tfjs@2.6.0", "@tensorflow/tfjs@^2.6.0":
748-
version "2.6.0"
749-
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs/-/tfjs-2.6.0.tgz#ddc420fbb0d9561f46d3d02ba3ba2d4c15861837"
750-
integrity sha512-f70NAt480+/NH6ueAdKhwgN3BzeBWrvuAZ591pH44nuVlmUHtih7pSMVv2wREPOgA4ciAufops4FtTaqNamxZw==
751-
dependencies:
752-
"@tensorflow/tfjs-backend-cpu" "2.6.0"
753-
"@tensorflow/tfjs-backend-webgl" "2.6.0"
754-
"@tensorflow/tfjs-converter" "2.6.0"
755-
"@tensorflow/tfjs-core" "2.6.0"
756-
"@tensorflow/tfjs-data" "2.6.0"
757-
"@tensorflow/tfjs-layers" "2.6.0"
746+
"@tensorflow/tfjs@3.0.0":
747+
version "3.0.0"
748+
resolved "https://registry.yarnpkg.com/@tensorflow/tfjs/-/tfjs-3.0.0.tgz#8d638b3c121085014aad54a93182a2d626f1db9e"
749+
integrity sha512-8u4BGKhxJ+SHg6pWEwBqIM8Z4hdXmy3Lts8xilC1uMALoVfIActp3icUufZL5PfoXe+v7OsQe3CqC+8qTNLYoA==
750+
dependencies:
751+
"@tensorflow/tfjs-backend-cpu" "3.0.0"
752+
"@tensorflow/tfjs-backend-webgl" "3.0.0"
753+
"@tensorflow/tfjs-converter" "3.0.0"
754+
"@tensorflow/tfjs-core" "3.0.0"
755+
"@tensorflow/tfjs-data" "3.0.0"
756+
"@tensorflow/tfjs-layers" "3.0.0"
758757
argparse "^1.0.10"
759758
chalk "^4.1.0"
760759
core-js "3"
@@ -813,10 +812,10 @@
813812
resolved "https://registry.yarnpkg.com/@types/webgl-ext/-/webgl-ext-0.0.30.tgz#0ce498c16a41a23d15289e0b844d945b25f0fb9d"
814813
integrity sha512-LKVgNmBxN0BbljJrVUwkxwRYqzsAEPcZOe6S2T6ZaBDIrFp0qu4FNlpc5sM1tGbXUYFgdVQIoeLk1Y1UoblyEg==
815814

816-
"@types/[email protected].4":
817-
version "0.0.4"
818-
resolved "https://registry.yarnpkg.com/@types/webgl2/-/webgl2-0.0.4.tgz#c3b0f9d6b465c66138e84e64cb3bdf8373c2c279"
819-
integrity sha512-PACt1xdErJbMUOUweSrbVM7gSIYm1vTncW2hF6Os/EeWi6TXYAYMPp+8v6rzHmypE5gHrxaxZNXgMkJVIdZpHw==
815+
"@types/[email protected].5":
816+
version "0.0.5"
817+
resolved "https://registry.yarnpkg.com/@types/webgl2/-/webgl2-0.0.5.tgz#dd925e20ab8ace80eb4b1e46fda5b109c508fb0d"
818+
integrity sha512-oGaKsBbxQOY5+aJFV3KECDhGaXt+yZJt2y/OZsnQGLRkH6Fvr7rv4pCt3SRH1somIHfej/c4u7NSpCyd9x+1Ow==
820819

821820
abbrev@1:
822821
version "1.1.1"

Diff for: mnist-core/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# TensorFlow.js Example: MNIST using tfjs-core
22

33
This example shows you how to train MNIST only using the [TensorFlow.js core]
4-
(https://github.com/tensorflow/tfjs-core) library (not using the layers API).
4+
(https://github.com/tensorflow/tfjs-core) API (not using the layers API).
55

66
Note: currently the entire dataset of MNIST images is stored in a PNG image we have
77
sprited, and the code in `data.js` is responsible for converting it into
8-
`Tensor`s. This will become much simpler in the near future.
8+
`Tensor`s.
99

1010
[See this example live!](https://storage.googleapis.com/tfjs-examples/mnist-core/dist/index.html)

Diff for: mnist-core/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"node": ">=8.9.0"
1010
},
1111
"dependencies": {
12-
"@tensorflow/tfjs": "2.0.0",
12+
"@tensorflow/tfjs": "3.0.0",
1313
"@tensorflow/tfjs-vis": "^1.0.3"
1414
},
1515
"scripts": {

0 commit comments

Comments
 (0)