Geometry Nodes Evaluator Improvements #87620

Closed
opened 2021-04-19 11:02:40 +02:00 by Jacques Lucke · 7 comments
Member

The current geometry nodes evaluator in MOD_nodes.cc is a fairly basic evaluator that misses many features. It was useful to get the geometry nodes project started, however nowadays we run into its limitations from time to time.

Below are a few improvements that I'd like to implement. The main goal is to make better use of the users compute and memory resources. I've yet to see whether I implement all the features in one go or if I split them up into separate projects.

  • Lazy input socket evaluation to support nodes like the switch node efficiently.
  • Allow nodes to only compute the outputs that are actually used (that helps the Attribute Statistics node in D10202).
  • Lazy output socket evaluation. This helps in the case when the usage or one output of a node depends on another output of the same node.
  • Multi-threaded evaluation of independent nodes.
  • Avoid storing computed values that are known not to be used anymore to reduce ram usage.
  • Use a non-recursive evaluation strategy. This makes profiling and debugging easier (the stack trace is much smaller). Also removes the scary thought that we might run out of stack space for long chains of nodes.
The current geometry nodes evaluator in `MOD_nodes.cc` is a fairly basic evaluator that misses many features. It was useful to get the geometry nodes project started, however nowadays we run into its limitations from time to time. Below are a few improvements that I'd like to implement. The main goal is to make better use of the users compute and memory resources. I've yet to see whether I implement all the features in one go or if I split them up into separate projects. * Lazy input socket evaluation to support nodes like the switch node efficiently. * Allow nodes to only compute the outputs that are actually used (that helps the Attribute Statistics node in [D10202](https://archive.blender.org/developer/D10202)). * Lazy output socket evaluation. This helps in the case when the usage or one output of a node depends on another output of the same node. * Multi-threaded evaluation of independent nodes. * Avoid storing computed values that are known not to be used anymore to reduce ram usage. * Use a non-recursive evaluation strategy. This makes profiling and debugging easier (the stack trace is much smaller). Also removes the scary thought that we might run out of stack space for long chains of nodes.
Jacques Lucke self-assigned this 2021-04-19 11:02:40 +02:00
Author
Member

Added subscriber: @JacquesLucke

Added subscriber: @JacquesLucke

Added subscriber: @someuser

Added subscriber: @someuser

Hi, this refactoring is also a preparation step before 'For Loop' node?

Hi, this refactoring is also a preparation step before 'For Loop' node?
Author
Member

No, this is unrelated to this refactor.

No, this is unrelated to this refactor.

ok, thank you

ok, thank you

This issue was referenced by b084b57fbf

This issue was referenced by b084b57fbf6d2b6c2a1adb2192f5d82581cede5c
Author
Member

Changed status from 'Needs Triage' to: 'Resolved'

Changed status from 'Needs Triage' to: 'Resolved'
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#87620
No description provided.