Blend Feature Recognition#
Detect fillets and rounds, classify their boundary edges, group them into radius-continuous chains, and find the rings of blends at the foot of a boss or round the rim of a pocket.
Note
Prerequisites: Attributed Adjacency Graph (AAG)
The BlendExtractor requires an Attributed Adjacency Graph (AAG) representation of the shape. If you’re new to AAG, start with the concepts documentation.
Tip
Tutorial Data Files:
Blend Feature Recognition#
Blends — the fillets and rounds that soften the sharp edges and corners of a part — are among the
most common transition features in machined and cast components. volmdlr_tools provides the
BlendExtractor to detect them, describe the role each of their boundary edges plays, and group
them into chains that share a common radius.
Why Detect Blends?#
Recognising blends supports several downstream tasks:
Reverse engineering — a blend is usually the last operation applied to a part. Detecting blends lets the reconstruction remove them first, recover the underlying sharp model, and re-apply them as parametric fillet operations.
Manufacturing analysis — fillet radii drive tool selection and machining strategy.
Simplification — small cosmetic rounds can be suppressed to speed up meshing and simulation without changing the part’s essential shape.
Running the Extractor#
BlendExtractor works on an Attributed Adjacency Graph (AAG). Construct it with a maximum radius
(blends larger than this are ignored) and call perform(); the recognised blends are then attached
to the graph and available as feature objects.
from volmdlr.model import VolumeModel
from volmdlr_tools.features.extractors.blend import BlendExtractor
from volmdlr_tools.graph.faces import AttributedAdjacencyGraph
solid = VolumeModel.from_step("part.step").primitives[0]
aag = AttributedAdjacencyGraph(shape=solid)
extractor = BlendExtractor(aag, max_radius=5.0)
extractor.perform()
blend_face_ids = extractor.ids # 0-based face indices carrying a blend
blends = extractor.get_blends() # one Blend feature per blend face
chains = extractor.get_chains() # blends grouped by continuous radius
Edge Roles#
Every blend face is bounded by edges that play distinct roles. The extractor classifies them, and they are the key to telling one kind of blend from another.
Spring edges — the edges adjacent to the support faces, i.e. the faces the rounded surface blends between. They are smooth (tangent) transitions: the blend rolls onto each support face without a sharp crease. An ordinary edge blend has two spring edges, one per support face.
Terminating edges — the short edges that close the blend at its ends, where the fillet runs out against another face rather than continuing.
Cross edges — edges shared with a neighbouring blend. A cross edge is where one blend meets another: a corner blend joining several edge blends, or a smaller fillet rolling onto a larger one.
Smooth edges — tangent edges internal to the rounded surface that do not bound the blend.

Blend Kinds#
BlendExtractor labels each blend face with a BlendType:
Ordinary — a standard edge blend with two spring edges, one per support face. This is the common fillet running along an edge.
Vertex — a corner blend, a patch where three or more edge blends meet at a vertex. It has no spring edges of its own; its boundary edges are the cross edges it shares with those edge blends.
Cliff — a blend with a single spring edge, such as a fillet that blends a face into a step.
Uncertain — a blend candidate whose edge roles could not be resolved confidently. It is kept for inspection but claims no edges.
The part below shows the two kinds that are visible on the surface: ordinary edge blends run along the edges (green), while vertex blends patch the corners where several edge blends meet (blue). The ordinary/cliff distinction is not a surface difference — it is the number of spring edges (two for ordinary, one for cliff) — so cliff blends are described above rather than shown here.

Each blend carries a BlendAttribute recording its kind, its edge-role index lists, and its
radius. BlendAttribute.owned_cross_edges_indices gives the once-per-owner view of cross edges
(an edge blend owns its cross edges; a corner blend mirrors its neighbours’ and owns none), so
per-edge accounting never counts a shared edge twice.
Blend Chains#
A single fillet often spans several faces of the same radius — around a pocket, along a
multi-segment edge, or across the corners that join them. get_chains() groups such faces into
BlendChain features by radius continuity, so a fillet applied as one modelling operation is
recovered as one chain rather than a scatter of faces.

Concave and Convex Blends#
Each blend also records which way it bends, in BlendAttribute.blend_vexity:
Concave — the blend fills a hollow between its supports, such as the fillet at the foot of a boss or along the inside corner of a pocket wall.
Convex — the blend rounds off material, such as the round along the top of a boss or along the rim of a pocket.
Uncertain — what is left when the face gives no clear answer, which is rare.
The side is read from the curvature of the whole blend face, so it is known for tangent blends as well as for blends meeting a sharp edge.
The part below is used for the rest of this page (download root_blends.step above). A plate carries
three features:
a boss, extruded from a rounded rectangle with a 3° draft, filleted at its foot and rounded along its top;
a pin, filleted at its foot;
a pocket, cut from the same rounded rectangle without draft, rounded along its rim.
The same boss carries a concave fillet at its foot and a convex round along its top. The rounded corners of the pocket’s outline are concave blends, but those of the boss’s outline are not: drafting turns them into cones, and a cone is never read as a blend (see Current Limitations, at the end of this page).

from volmdlr_tools.features.feature_types.blends import BlendVexity
concave = [
face_id
for face_id in extractor.ids
if aag.graph.nodes[face_id]["blend_attribute"].blend_vexity == BlendVexity.Concave
]
Blends on Moulded Parts#
On moulded and cast parts, fillets are often written as free-form faces whose curvature changes from
place to place. BlendExtractor(aag, free_form_curvature=True) reads such faces by their curvature
over their whole extent: a free-form face that keeps one curvature all over is recognised as a round,
and a corner patch takes its radius from its own curvature. Leave the option off for machined parts,
whose fillets are cylinders, tori and spheres.
Boss Roots and Pocket Rims#
A boss on a moulded part rarely meets its base along a sharp edge: a ring of concave blends runs round
its foot. A pocket is usually rimmed by a ring of convex blends in the same way. Such a ring is the
boundary of the feature, and root_blend_chains finds every one of them on a part:
from volmdlr_tools.features.extractors.blend_roots import root_blend_chains
for root in root_blend_chains(aag):
print(root.kind, len(root.blend_face_ids), root.radius)
Each RootBlendChain gives:
kind—"boss"for a concave root,"pocket"for a convex rim;blend_face_ids— the blend faces of the ring alone;base_face_ids— the faces the ring leaves from, which may be several faces joined tangentially;enclosed_face_ids— every face the ring cuts off, the boss or the pocket with its blends;radiusandradii— the blend radius,Nonewhen it varies, and every radius met along the ring.
A ring counts as a root only when the loop where it leaves its base cuts the part in two. The boss’s root is one ring even when the same blend chain carries on round the boss’s top through shared corner blends: only the ring at the foot is kept. In the part below, the roots of the boss and of the pin are green, the rim of the pocket is red, and the other blends — the round on the boss’s top and the inside corners of the pocket — are pale.

root_of_chain and roots_of_chain do the same for a single BlendChain.
Cutting Bosses and Pockets Off at Their Roots#
ShapeIsolatedBossSplitter splits a part into its base and its isolated bosses. By default it cuts
only along the sharp inner wires of a face, so a boss with a root fillet stays attached to the base.
With boundaries="inner_wires_and_root_blends" it also cuts along root rings and pocket rims, and
along the sharp rim of a pocket:
from volmdlr_tools.features.extractors.isolated_boss_splitter import ShapeIsolatedBossSplitter
splitter = ShapeIsolatedBossSplitter(solid, boundaries="inner_wires_and_root_blends")
splitter.perform()
for piece in splitter.result:
print(piece.kind, len(piece.face_indices), len(piece.root_blend_face_ids))
Every piece names its kind ("boss", "pocket", or None for the base), the base_face_ids it
hangs from, its root_blend_face_ids and the loop_edge_ids it was cut along. Pieces never share a
face: each one owns its root blends. Features standing on other features nest, as a lettering on a
plaque on a neck gives the plaque as a child of the base and each glyph as a child of the plaque.

On the default split, this part comes back whole: the boss and the pin are filleted at their foot, and the pocket is a hollow rather than a boss.
Isolable Blends#
An isolable blend is one that can be reduced to an isolated profile-corner round — typically a rounded corner of an extrusion profile that is better re-created when the profile is reconstructed than removed as a separate fillet. A blend is isolable when it has:
exactly two spring edges, and
a two-edge boundary in which each edge is either a terminating edge or a cross edge to a corner blend that terminates cleanly.
A cross edge terminates cleanly when the corner (vertex) blend it reaches has exactly one terminating edge and that terminating edge shares no vertex with the cross edge. When both conditions hold, collapsing the corner blend leaves the edge blend a standalone isolated round.
This capability is recorded on BlendAttribute.isolable. It is broader than
BlendAttribute.is_isolated, which reports the already-standalone state — a blend bounded by two
spring edges and two terminating edges, carrying no cross edges at all. Every already-isolated blend
is isolable; the reverse need not hold.
The three cases below illustrate the two-edge boundary. In each, the four highlighted faces are the isolable blends.
Two terminating edges#
The original standalone definition: each blend is closed at both ends by a terminating edge and
carries no cross edges. These blends are also is_isolated.

One terminating edge and one cross edge#
Each blend is closed at one end by a terminating edge and at the other by a cross edge to a corner blend that terminates cleanly.

Two cross edges#
Each blend is closed at both ends by a cross edge, each reaching a corner blend that terminates cleanly.

extractor.perform()
isolable_faces = [
face_id
for face_id in extractor.ids
if aag.graph.nodes[face_id]["blend_attribute"].isolable
]
Current Limitations#
Cones are not blends. A conical face is read as a chamfer, never as a blend, whether or not it meets its neighbours tangentially. On a drafted feature, the rounded corners of the drafted walls are cones, so they are not found: in the example part above, the corners of the boss’s outline stay grey while the same corners on the undrafted pocket are blends. On moulded parts, where every wall is drafted, expect such corners to be missed.
A variable-radius blend has one radius. A fillet whose radius changes along its length is found as
an ordinary blend, with its side, but BlendAttribute.radius holds a single value somewhere between its
two ends: a fillet running from 1 mm to 4 mm reports about 2.5 mm. Blend chains, and the radius of a
root ring, are built on that single value per face; the range a face covers is not recorded.
See Also#
Feature Processor - Feature extraction orchestrator
Attributed Adjacency Graph (AAG) - Attributed Adjacency Graph
Hole Feature Recognition - Hole recognition