learn how to use Node-RED to create a photo booth web app infused with AI through the use of TensorFlow. The workshop will step through getting started with Node-RED, creating the web app and then containerising it, ready to be deployed into the cloud or onto edge devices. 2
with a Web Cam attached • Node.js 12.x or 14.x Had some early reports of issues with npm 7 and the Node-RED Palette Manager. Recommend avoiding that today if you can. • Git • Docker Desktop (optional) • A cup, banana, apple or other recognizable object • Node-RED Slack - https://nodered.org/slack Join #workshop • All the workshop material is available here
Node-RED running on your local computer - Enable the Projects feature - Learn how to install additional nodes into its palette - Create a simple application to learn how Node-RED works 2. Introduce Node-RED Dashboard - Install Dashboard and some other nodes - Build a simple dashboard application 3. TensorFlow in Node-RED - Look at the available TF nodes for Node-RED - Update the dashboard application to include TF 4. Containerization - Turn your Node-RED project into a standalone application, wrapped in a container that can be deployed wherever you want it
build today, from Integration to IoT, often require pulling together different APIs, online services and hardware devices in new and interesting ways. Time spent figuring out how to access a Serial port, or to complete an OAuth flow against Twitter is not time spent on creating the real value of a solution. We need tools that make it easier for developers at all levels to create applications and allow them to focus on what is important.
runs in a browser and allows you to create applications by drawing flows of events. Each node in a flow represents a well-defined piece of functionality, such as updating a value, making a database query or sending a tweet. The developer configures each node as required, focused on what it does, not how it does it. When the flow is deployed to the Node-RED runtime, each node becomes a running piece of code and messages start passing through the flow. “Flow-based programming for event-driven applications”
a collection of nodes that are wired together. A node can have multiple output ports and a single port can have multiple wires connected to it. The flow is stored as a JSON object – providing the configuration for all of its nodes and how they are connected. The flow JSON can be imported and exported between Node-RED instances, making it easy to share flows.
pass through a flow are JavaScript Objects. By convention they will have a payload property that contains the ‘interesting’ information. This is the property most nodes will operate on by default. topic: “weather/uk” payload: “sunny!” … …
basic building blocks of a flow. Nodes that sit at the start of a flow will be waiting for some external event to occur, such as an incoming HTTP request, a timer event or a hardware IO event. They then pass messages onto the nodes they are connected to. Nodes receive those messages, do some work, and then pass them on down the flow. payload: “Jedi are totally amazing!” payload: “Jedi are totally amazing!” sentiment: { score: 4 } In this example, a Sentiment analysis node has examined the ’payload’ property of the message, assessed its sentiment and added its result as a new property of the message.
a set of nodes that can be used to create an interactive webpage. Each node maps to a widget on the dashboard, such as a Text Input, Button or Chart. The dashboard uses a grid-based layout to automatically position widgets on the page. Trades off opinionated appearance against ease of use. Hello world