Attribute

Attributes

Below are the attributes which are potentially created when a structure is imported. Explanations of type and domain conversions can be found in the Blender documentation here

World Scale

In Molecular Nodes, the world scale determines how real-world measurements are translated into the 3D environment of Blender which uses metres. Currently, 1 angstrom (Å) is equivalent to 1 centimeter (cm). Scaling structural coodinates by 0.01 correctly converts them and 0.01 is referred to as the world scale.

This scale will change in Blender 5.0 to be 0.1 so 1 nm will equal 1 m.

When an attribute is going to be read from the geometry, it is colored red like so: Index, chain_id, while when a specific data type is refernce it will be colored accoring to the data type like so: Int, Float, Vector, etc.

Data Types

Attribute Types

Attributes are always associated with Geometry. They will be stored on one of the domains of the geometry. The type of the attribute is determined by the type of the data it contains. The following types are supported by Geometry Nodes.

Type Description
Int 32-bit integers
Float 32-bit floating point numbers
Bool A simple True or False value
Vector 3D vectors
Matrix 4x4 matrices, also references as Transform inside of Geometry Nodes
Color RGBA colors, stored as 0..1 values
Rotation A rotation that internally is represented as a quaternion, but can implicitly be converted to an Euler vector.

Other Data Types

Additional data types which are not supported as Attributes but can be used in the node tree are:

Type Description
String String support in Geometry Nodes is limited at the moment and you cannot store strings as attributes
Object Access to objects in the 3D scene and their associated data
Collection Access a collection of objects from the scene. Objects are returned as instances
Material Material to be applied to the created geometry
Menu A menu for selecting a value from a list of options

Attributes

All of the molecular attributes which are defined as strings such as chain_id, res_name, etc. are stored as integers in the geometry because Geometry Nodes does not support string attributes.

For chain_id, entity_id and other dynamic attributes, the unique values are first sorted alphabetically and then assigned an integer value based on their order.

For other attributes such as res_name, they are looked up from the dictionary and assigned an integer value.

Point Attributes

Type

Description

Position Vector Coordinates in 3D space of the points, read from the molecular data file. They are scaled by the world scale 0.01 on import so that 1 Å == 1 cm.
b_factor Float The temperature factor for the atom on import. If importing an AlphaFold structure this corresponds to the pLDDT value.
vdw_radii Float The radii of the atom, stored in world space (~0.015). Values sourced from Wikipedia.
sec_struct Int Defines secondary structure for the residue the atom is part of. 0 for not a protein. 1 for helices, 2 for sheets, 3 for coils / unstructured.
mass Float Mass of the element
chain_id Int The integer representation of the chain ID, for it’s position in the sorted list of chain IDs in the structure.
entity_id Int Multiple chains can be the same entity, if they are copies of the same protein that appear multiple times in the structure. Also sorted and assigned integers on import.
res_name Int Residues are mapped to integer values based on the lookup table.
res_id Int The residue number, which starts at 1 for the first residue in each chain. If a structure is truncated it might not start at 1.
ures_id Int The ures_id starts at 0 and increases by 1 for each residue across the whole structure, compared to the res_id which starts at 1 and restarts at 1 for each chain.
atomic_number Int Stores the atomic number of the atom for it’s position on the periodic table, instead of the element’s name.
atom_name Int Atom names are mapped to integer values based on the lookup table.
Color Color Color of the atom, assigned on import but often changed in node trees.
atom_id Int Unique ascending value for each atom in the file, starting at 1
is_alpha_carbon Bool Computed on import or from the atom_name attribute.
is_side_chain Bool Computed on import or from the atom_name attribute.
is_backbone Bool Computed on import or from the atom_name attribute.
is_solvent Bool Computed on import or from the atom_name attribute.
is_nucleic Bool Computed on import or from the atom_name attribute.
is_peptide Bool Computed on import or from the atom_name attribute.
is_hetero Bool Computed on import or from the atom_name attribute.
is_carb Bool Computed on import or from the atom_name attribute.

Edge Attributes

Bonds between atoms are represented as edges in the geometry, and only the bond type is stored on the edge domain.

Attribute Type Description
bond_type Int The type of bond between the atoms.

Bond types are currently the values used by biotite

Bond Type Integer Value Description
ANY 0 Used if the actual type is unknown
SINGLE 1 Single bond
DOUBLE 2 Double bond
TRIPLE 3 Triple bond
QUADRUPLE 4 A quadruple bond
AROMATIC_SINGLE 5 Aromatic bond with a single formal bond
AROMATIC_DOUBLE 6 Aromatic bond with a double formal bond
AROMATIC_TRIPLE 7 Aromatic bond with a triple formal bond

Domains

Domain Description
Point Individual points of geometry. These can be the vertices in a mesh, the points in a point cloud, or the control points of a curve.
Edge The edges of a mesh, defined as the indices between two points.
Face A face of a mesh, defined as a collection of edges.
Corner Corners of a face, where two edges meet.
Curve A curve object, which contains multiple control points, but can itself store attributes.
Instance Instances are references to other geometry. Instancing is useful for making lots of copies of some geometry for performance.
Layer Layers are for Grease Pencil, and contain a collection of curves.