From dc121a2941f7ef81e62195026925ea66bf6b888c Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Thu, 11 Feb 2021 18:04:52 +0100 Subject: [PATCH] Environment Flags Implemented --- Projects/TensorFlow/Icons/delete-entity.png | Bin 0 -> 3902 bytes Projects/TensorFlow/Schemas/AppSchema.json | 148 +++++++++++++++++- .../Schemas/Docs-Concepts/backend.json | 4 +- .../Schemas/Docs-Nodes/debug-mode.json | 13 ++ .../Schemas/Docs-Nodes/environment-flags.json | 13 ++ .../execution-environment.json} | 6 +- .../Schemas/Docs-Nodes/production-mode.json | 13 ++ .../Docs-Nodes/tensorflow-library.json | 13 ++ 8 files changed, 199 insertions(+), 11 deletions(-) create mode 100644 Projects/TensorFlow/Icons/delete-entity.png create mode 100644 Projects/TensorFlow/Schemas/Docs-Nodes/debug-mode.json create mode 100644 Projects/TensorFlow/Schemas/Docs-Nodes/environment-flags.json rename Projects/TensorFlow/Schemas/{Docs-Concepts/execution-environmet.json => Docs-Nodes/execution-environment.json} (54%) create mode 100644 Projects/TensorFlow/Schemas/Docs-Nodes/production-mode.json create mode 100644 Projects/TensorFlow/Schemas/Docs-Nodes/tensorflow-library.json diff --git a/Projects/TensorFlow/Icons/delete-entity.png b/Projects/TensorFlow/Icons/delete-entity.png new file mode 100644 index 0000000000000000000000000000000000000000..2c31a2f3eeb19a36131aed5bbe4c69bdd0067622 GIT binary patch literal 3902 zcmb_fdpy)x8$UBmcA{juVdT=vWjEIf$!LZe^17tdJBV>9w^Bm6?V6dAdfjb`yux%r zv{4hulCf^3DMS<^88ejY%(xA6*`MCs&9>^(=l$&bbAF%mJm-7P`99BizR$$i+gYxV zL`wnyR#@%cwGRL|^a%$@322xIdoc?Q@+a|*CmjO3PlkE~c>%M-0iIqeR>wSiy!Lr{ z91ag`@WKEf-D|bWY=2niaJQ>}<|)N04%zb2>&|C2H!iJVZnw8~$7%SR#dOFYxkhlU z=rvz0zfoqDPFNY&Tr-0h=9TVkbosIOHQ92?h(uU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lnqW;q7)6n!BI*4b`{_{Qv*} literal 0 HcmV?d00001 diff --git a/Projects/TensorFlow/Schemas/AppSchema.json b/Projects/TensorFlow/Schemas/AppSchema.json index 743a19632..7bd710450 100644 --- a/Projects/TensorFlow/Schemas/AppSchema.json +++ b/Projects/TensorFlow/Schemas/AppSchema.json @@ -68,6 +68,33 @@ }, { "type": "TensorFlow Library", + "menuItems": [ + { + "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "executionEnvironment", + "label": "Add Execution Environment", + "relatedUiObject": "Execution Environment", + "actionFunction": "payload.executeAction" + } + ], + "addLeftIcons": true, + "level": 3, + "attachingRules": { + "compatibleTypes": "->Learning System->" + }, + "propertyNameAtParent": "machineLearningLibrary", + "childrenNodesProperties": [ + { + "name": "executionEnvironment", + "type": "node", + "childType": "Execution Environment" + } + ], + "icon": "tensorflow" + }, + { + "type": "Execution Environment", "menuItems": [ { "action": "Add UI Object", @@ -101,6 +128,14 @@ "relatedUiObject": "CPU Backend", "actionFunction": "payload.executeAction" }, + { + "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "environmentFlags", + "label": "Add Environment Flags", + "relatedUiObject": "Environment Flags", + "actionFunction": "payload.executeAction" + }, { "action": "Delete UI Object", "askConfirmation": true, @@ -114,9 +149,9 @@ "addLeftIcons": true, "level": 3, "attachingRules": { - "compatibleTypes": "->Learning System->" + "compatibleTypes": "->TensorFlow Library->" }, - "propertyNameAtParent": "machineLearningLibrary", + "propertyNameAtParent": "executionEnvironment", "childrenNodesProperties": [ { "name": "backend", @@ -137,6 +172,61 @@ "name": "backend", "type": "node", "childType": "CPU Backend" + }, + { + "name": "environmentFlags", + "type": "node", + "childType": "Environment Flags", + "autoAdd": true + } + ], + "icon": "tensorflow" + }, + { + "type": "Environment Flags", + "menuItems": [ + { + "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "mode", + "label": "Add Debug Mode", + "relatedUiObject": "Debug Mode", + "actionFunction": "payload.executeAction" + }, + { + "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "mode", + "label": "Add Production Mode", + "relatedUiObject": "Production Mode", + "actionFunction": "payload.executeAction" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "addLeftIcons": true, + "level": 3, + "attachingRules": { + "compatibleTypes": "->Execution Environment->" + }, + "propertyNameAtParent": "environmentFlags", + "childrenNodesProperties": [ + { + "name": "mode", + "type": "node", + "childType": "Debug Mode" + }, + { + "name": "mode", + "type": "node", + "childType": "Production Mode" } ], "icon": "tensorflow" @@ -163,7 +253,7 @@ "addLeftIcons": true, "level": 3, "attachingRules": { - "compatibleTypes": "->TensorFlow Library->" + "compatibleTypes": "->Execution Environment->" }, "propertyNameAtParent": "backend", "childrenNodesProperties": [ @@ -192,7 +282,7 @@ "addLeftIcons": true, "level": 3, "attachingRules": { - "compatibleTypes": "->TensorFlow Library->" + "compatibleTypes": "->Execution Environment->" }, "propertyNameAtParent": "backend", "childrenNodesProperties": [ @@ -221,7 +311,7 @@ "addLeftIcons": true, "level": 3, "attachingRules": { - "compatibleTypes": "->TensorFlow Library->" + "compatibleTypes": "->Execution Environment->" }, "propertyNameAtParent": "backend", "childrenNodesProperties": [ @@ -250,11 +340,57 @@ "addLeftIcons": true, "level": 3, "attachingRules": { - "compatibleTypes": "->TensorFlow Library->" + "compatibleTypes": "->Execution Environment->" }, "propertyNameAtParent": "backend", "childrenNodesProperties": [ ], "icon": "tensorflow" + }, + { + "type": "Debug Mode", + "menuItems": [ + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "addLeftIcons": true, + "level": 3, + "attachingRules": { + "compatibleTypes": "->Environment Flags->" + }, + "propertyNameAtParent": "mode", + "childrenNodesProperties": [ + ], + "icon": "tensorflow" + }, + { + "type": "Production Mode", + "menuItems": [ + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "addLeftIcons": true, + "level": 3, + "attachingRules": { + "compatibleTypes": "->Environment Flags->" + }, + "propertyNameAtParent": "mode", + "childrenNodesProperties": [ + ], + "icon": "tensorflow" } ] \ No newline at end of file diff --git a/Projects/TensorFlow/Schemas/Docs-Concepts/backend.json b/Projects/TensorFlow/Schemas/Docs-Concepts/backend.json index 1ee674dd9..b3319ae2c 100644 --- a/Projects/TensorFlow/Schemas/Docs-Concepts/backend.json +++ b/Projects/TensorFlow/Schemas/Docs-Concepts/backend.json @@ -1,8 +1,8 @@ { "type": "Backend", "definition": { - "text": "TensorFlow.js support multiple different backends that implement tensor storage and mathematical operations. At any given time, only one backend is active. Most of the time, TensorFlow.js will automatically choose the best backend for you given the current Environment. ", - "updated": 1613058525297 + "text": "TensorFlow.js support multiple different backends that implement tensor storage and mathematical operations. At any given time, only one backend is active. Most of the time, TensorFlow.js will automatically choose the best backend for you given the current Execution Environmet.", + "updated": 1613059266937 }, "paragraphs": [ { diff --git a/Projects/TensorFlow/Schemas/Docs-Nodes/debug-mode.json b/Projects/TensorFlow/Schemas/Docs-Nodes/debug-mode.json new file mode 100644 index 000000000..15772e5c8 --- /dev/null +++ b/Projects/TensorFlow/Schemas/Docs-Nodes/debug-mode.json @@ -0,0 +1,13 @@ +{ + "type": "Debug Mode", + "definition": { + "text": "Debug Mode will log to the console every operation that is executed, as well as runtime performance information like memory footprint and total kernel execution time. Note that this will greatly slow down your application, do not use this in production.", + "updated": 1613062911672 + }, + "paragraphs": [ + { + "style": "Text", + "text": "Left click and select the pencil button to enter edit mode." + } + ] +} \ No newline at end of file diff --git a/Projects/TensorFlow/Schemas/Docs-Nodes/environment-flags.json b/Projects/TensorFlow/Schemas/Docs-Nodes/environment-flags.json new file mode 100644 index 000000000..cc8f55069 --- /dev/null +++ b/Projects/TensorFlow/Schemas/Docs-Nodes/environment-flags.json @@ -0,0 +1,13 @@ +{ + "type": "Environment Flags", + "definition": { + "text": "TensorFlow.js has a set of environment flags that are automatically evaluated and determine the best configuration in the current platform. These flags are mostly internal, but a few global flags can be controlled with public API.", + "updated": 1613062805784 + }, + "paragraphs": [ + { + "style": "Text", + "text": "Left click and select the pencil button to enter edit mode." + } + ] +} \ No newline at end of file diff --git a/Projects/TensorFlow/Schemas/Docs-Concepts/execution-environmet.json b/Projects/TensorFlow/Schemas/Docs-Nodes/execution-environment.json similarity index 54% rename from Projects/TensorFlow/Schemas/Docs-Concepts/execution-environmet.json rename to Projects/TensorFlow/Schemas/Docs-Nodes/execution-environment.json index fb0b45358..c961cdb9f 100644 --- a/Projects/TensorFlow/Schemas/Docs-Concepts/execution-environmet.json +++ b/Projects/TensorFlow/Schemas/Docs-Nodes/execution-environment.json @@ -1,13 +1,13 @@ { - "type": "Execution Environmet", + "type": "Execution Environment", "definition": { "text": "When a TensorFlow.js program is executed, the specific configuration is called the execution environment. The Execution Environment is comprised of a single global backend as well as a set of flags that control fine-grained features of TensorFlow.js.", - "updated": 1613058650461 + "updated": 1613060399329 }, "paragraphs": [ { "style": "Text", - "text": "Left click and Edit to enter edit mode and change this text. ENTER to write new paragraphs. ESC to exit edit mode. Then you can use doscs.save to save your changes and app.contribute to send it to the main repository." + "text": "Left click and select the pencil button to enter edit mode." } ] } \ No newline at end of file diff --git a/Projects/TensorFlow/Schemas/Docs-Nodes/production-mode.json b/Projects/TensorFlow/Schemas/Docs-Nodes/production-mode.json new file mode 100644 index 000000000..3e7c638ac --- /dev/null +++ b/Projects/TensorFlow/Schemas/Docs-Nodes/production-mode.json @@ -0,0 +1,13 @@ +{ + "type": "Production Mode", + "definition": { + "text": "Production Mode will remove model validation, NaN checks, and other correctness checks in favor of performance.", + "updated": 1613062862838 + }, + "paragraphs": [ + { + "style": "Text", + "text": "Left click and select the pencil button to enter edit mode." + } + ] +} \ No newline at end of file diff --git a/Projects/TensorFlow/Schemas/Docs-Nodes/tensorflow-library.json b/Projects/TensorFlow/Schemas/Docs-Nodes/tensorflow-library.json new file mode 100644 index 000000000..37b381547 --- /dev/null +++ b/Projects/TensorFlow/Schemas/Docs-Nodes/tensorflow-library.json @@ -0,0 +1,13 @@ +{ + "type": "TensorFlow Library", + "definition": { + "text": "In Node.js, TensorFlow.js supports binding directly to the TensorFlow API or running with the slower vanilla CPU implementations.", + "updated": 1613062988909 + }, + "paragraphs": [ + { + "style": "Text", + "text": "Left click and select the pencil button to enter edit mode." + } + ] +} \ No newline at end of file