LogoLogo
  • TABLE OF CONTENTS
  • General Concepts
    • Overview
    • Introduction to Rendered.ai
    • The Rendered.ai Platform
    • Who Uses Rendered.ai?
    • Rendered.ai Licensing and Offerings
  • Application User Guides
    • Overview
    • Quick Start Guide
      • Terminology
      • Content Codes
      • Getting Started with the SDK
    • Tutorials
      • Organization and Workspace Resources
      • Creating and Using Graphs
        • Graph Validation
        • Graph Best Practices
      • Creating and Using Datasets
        • Dataset Annotations
        • Dataset Analytics
        • Domain Adaptation
        • Dataset Comparison
        • Training and Inference
        • Mixing Datasets
        • Dataset Best Practices
      • Creating and Using Volumes
        • Inpaint Service
      • Collaboration
  • Development Guides
    • Overview
    • Ana Software Architecture
      • Basic components
      • Graphs
      • Channels
      • Packages
      • Package Volumes
      • Nodes
      • Schema
      • Ana Modules, Classes, and Functions
      • The anatools Package
      • Graph Validation
        • Typical Validation Use Cases
      • Preview
      • In-tool Help
    • Setting Up the Development Environment
      • Local Development With NVIDIA GPUs
      • Remote Development With AWS EC2
    • Deploying a Channel
    • An Example Channel - Toybox
      • Run and Deploy the Toybox Channel
      • Add a Modifier Node
      • Add a Generator Node
  • Open Source Channels
    • Toybox
    • DIRSIG Channel
  • Release Notes
    • Rendered.ai Platform
      • Platform Version 1.6.0
      • Platform Version 1.5.0
      • Platform Version 1.4.1
      • Platform Version 1.4.0
      • Platform Version 1.3.2
      • Platform Version 1.3.1
      • Platform Version 1.3.0
      • Platform Version 1.2.6
      • Platform Version 1.2.5
      • Platform Version 1.2.4
      • Platform Version 1.2.3
      • Platform Version 1.2.2
      • Platform Version 1.2.1
      • Platform Version 1.2.0
      • Platform Version 1.1.5
      • Platform Version 1.1.4
      • Platform Version 1.1.3
      • Platform Version 1.1.2
      • Platform Version 1.1.1
      • Platform Version 1.1.0
      • Platform Version 1.0.3
      • Platform Version 1.0.2
      • Platform Version 1.0.1
      • Platform Version 1.0.0
      • Platform Version 0.3.4.4
      • Platform Version 0.3.4.3
      • Platform Version 0.3.4.2
      • Platform Version 0.3.4.1
      • Platform Version 0.3.4
      • Platform Version 0.3.3.1
      • Platform Version 0.3.3
      • Platform Version 0.3.2.2
      • Platform Version 0.3.2.1
      • Platform Version 0.3.2
      • Platform Version 0.3.1.6
      • Platform Version 0.3.1.5
      • Platform Version 0.3.1.4
      • Platform Version 0.3.1.3
      • Platform Version 0.3.1.2
      • Platform Version 0.3.1
      • Platform Version 0.3.0.9
      • Platform Version 0.3.0.8
      • Platform Version 0.3.0.7
      • Platform Version 0.3.0.6
      • Platform Version 0.3.0.5
      • Platform Version 0.3.0
      • Platform Version 0.2.15
      • Platform Version 0.2.14
      • Platform Version 0.2.13
      • Platform Version 0.2.12
      • Platform Version 0.2.11
      • Platform Version 0.2.10
      • Platform Version 0.2.9
      • Platform Version 0.2.8
      • Platform Version 0.2.7
      • Platform Version 0.2.6
      • Platform Version 0.2.5
      • Platform Version 0.2.4
      • Platform Version 0.2.3
      • Platform Version 0.2.2
      • Platform Version 0.2.1
      • Platform Version 0.2.0
Powered by GitBook
On this page
Export as PDF
  1. Development Guides
  2. Ana Software Architecture

Schema

For every node in a channel there is an associated schema that defines what inputs, outputs, and other attributes are implemented by the node. Schema are stored in schema files in the same directory as the node files. For every node module in the package, there is an associated schema file. Schema files are written in YAML and use the same base name as the corresponding node module, e.g. the schema file for “my_node.py” is “my_node.yml”.

Here is an example schema for the “Add” node defined in the previous section:

schemas:
  Add:
    inputs:
    - name: Value1
      description: The first value to be added
    - name: Value2
      description: The second value to be added
      default: 1
    outputs:
    - name: Sum
      description: The sum of Value1 and Value2 added together
    tooltip: Add two values and return the sum
    category: Functions
    subcategory: Math
    color: "#0C667A"

The schema file has a single top level element called “schemas” which is a dictionary containing one item for every node defined in the corresponding node module. In this example, the schema file defines a single node called “Add”.

Node input ports are specified as a list of dictionaries, with one list entry per input port. Each input port must specify a name and description. Optionally, a default value for the port can be specified. This value will be used if no value or link is assigned to that port in the graph.

In this example, there are two input ports - “Value1” and “Value2”. The Value2 input port is assigned a default value of 1.

Output ports are specified as a list of dictionaries, with one list entry per output port. Each output port must specify a name and description.

In this example there is one output port - “Sum”.

The “tooltip”, “category”, “subcategory”, and “color” attributes specify information used in the GUI based graph editor.

The “category” and “subcategory” specify where the node will be located in the add-node menu on the left side of the graph editor. In this example, the node will be located under “Functions” → “Math”.

The “color” attribute specifies the color to be used when the node is displayed in the GUI.

Additional attributes can be assigned to input ports to help guide users when they are entering inputs in the GUI. Here is an example:

schemas:
  Location3d:
    inputs:
    - name: Terrain Type 
      description: The type of terrain to generate for this location
      select:
      - desert
      - forest
      - urban
      default: urban
    outputs:
    - name: Terrain
      description: The terrain for this location
    tooltip: Generate a 3d background to be used in the scene
    category: Locations
    subcategory: Procedural
    color: "#0C667A"

In this example, we define a node called “Location3d” that will procedurally generate 3d terrain. The type of terrain to be generated is specified via the “Terrain Type” input port. The “select” attribute provides a list of values for this port that will be displayed in the GUI as a pull-down menu. The user can scroll through this menu to pick a value. The default value displayed in the pull-down is “urban”.

PreviousNodesNextAna Modules, Classes, and Functions

Last updated 9 months ago

The “tooltip” attribute specifies a string to be displayed when the user hovers over the symbol on the node.