i want to review the inputs and outputs of geometry nodes for debugging and to gain a deeper understanding what is going on.
I have read other questions on the topic but they are mostly very short, with a specific example and without the explanation i need.
Other resources Article1 Article2 Article3 . . .
So my naive approach, and i guess the approach of thousands of other people is to enable the python tooltips and go to the shown path like
bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math']
then i add a dot and press tab to see what's inside
as_pointer(
bl_description
bl_height_default
bl_height_max
bl_height_min
bl_icon
bl_idname
bl_label
bl_rna
bl_rna_get_subclass(
bl_rna_get_subclass_py(
bl_static_type
bl_width_default
bl_width_max
bl_width_min
color
dimensions
draw_buttons(
draw_buttons_ext(
driver_add(
driver_remove(
get(
height
hide
id_data
id_properties_clear(
id_properties_ensure(
id_properties_ui(
input_template(
inputs
internal_links
is_property_hidden(
is_property_overridable_library(
is_property_readonly(
is_property_set(
is_registered_node_type(
items(
keyframe_delete(
keyframe_insert(
keys(
label
location
mute
name
operation
output_template(
outputs
parent
path_from_id(
path_resolve(
poll(
poll_instance(
pop(
property_overridable_library_set(
property_unset(
rna_type
select
show_options
show_preview
show_texture
socket_value_update(
type
type_recast(
update(
use_custom_color
values(
width
width_hidden
I then try to figure out what i want to see (please tell me if there is a better documented way). So there is a variable named inputs... sounds good. I'll have a look into
bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs.
and find
as_bytes(
bl_rna
clear(
data
find(
foreach_get(
foreach_set(
get(
id_data
items(
keys(
move(
new(
path_from_id(
remove(
rna_type
update(
values(
Then i try data or value but this leads me nowhere...
In the other articles people use
bpy.context.evaluated_depsgraph_get()
but i lack the understanding what that means. So any reference is welcome.
I'd really like to understand the concepts behind rather than finding a specific example that fixes this exact problem until i run into the next. Is there an article on how geometry nodes (or blender) store data and apply modifiers. I'm sorry for the very open question...
===== Follow Up Edit
As Crantisz pointed out you can access the "default inputs" with
>>> bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs[0].default_value[0]
1.0
>>> bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs[0].default_value[1]
0.0
>>> bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs[0].default_value[2]
1.0
>>> bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs[1].default_value[0]
0.0
>>> bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs[1].default_value[1]
1.0
>>> bpy.data.node_groups['Geometry Nodes'].nodes['Vector Math'].inputs[1].default_value[2]
0.0
So the "regulator inputs" can be adressed.
But when i attach another source (which is the realistic use case)
then i get the same outputs and NOT the ones coming from the real input that is attached (here Combine XYZ)
So, how do i get to the input that is currently active at the input?
========== Final Edit
As Crantisz points out: "This is not accessible" The data of a node does not appear to be accessible.
That is really a bad choice in my opinion. Following Viewer Node Discussion there was a statement that really made me jump of my chair ("The value without geometry doesn't make sense."). Hopefully there will be some overthinking of this statement, but i fear there is a deeper reason (how geometry nodes work deep inside).
but when i connect to a geometry

So that brings me to two thoughts/observations:
- The Information i'm looking for (input / output data) must be somewhere as it was displayed in the tooltip
- Geometry Node does not compute nodes that are not connected to a geometry, which is sad mostly for debugging. I get that the whole point of a geometry node is to deal with geometry, but there are other sidecalculations that may need debugging until you hook it to a geometry eventually. The viewer node is cumbersome (and only knows values). Debugging vectors is a nightmare...




