The Blender API is a little quirky. You have to either be in OBJECT mode or use bmesh to select or deselect vertices and edges.

Let’s start with a cube, in EDIT mode, with everything deselected.

start box

To select a vertex, one way is to change to OBJECT mode, select the vertex, and change back to EDIT mode.

#change to OBJECT mode

#deselect the 0th vertex['Cube'].vertices[0].select = True

#change to back to EDIT mode

selected vertex

Deselect works very similarly:


#deselect the 0th vertex['Cube'].vertices[0].select = False


And we’re back to the start.

start box

Selecting an edge uses the same principle:


#select the 0th edge['Cube'].edge[0].select = True


selected edge

Deselecting that edge is quite a bit different. You can’t just use:['Cube'].edge[0].select =False

You have to deselect the vertices of an edge first, and then deselect the edge.

bpy.ops.object.mode_set(mode="OBJECT")['Cube'].vertices[0].select = False['Cube'].vertices[1].select = False['Cube'].edges[0].select = False


Occasionally, when switching the mode to deselect doesn’t work (like if you have non-manifold edges selected), or if you want to stay in edit mode, you can use bmesh.

Let’s start with a box with once face removed and non-manifold edges selected
( bpy.ops.mesh.select_non_manifold())

non manifold edges

mesh = bmesh.from_edit_mesh(
mesh.verts[2].select = False #the vertices are indexed differently
mesh.verts[3].select = False
mesh.edges[0].select = False

deselected edge for non manifold

Ta da! The bottom edge is deselected.

Blender 2.71

Last day!

I didn’t attend as many talks as I did yesterday, mostly ’cause I’m feeling under the weather.


Those that I did go to were AMAZING!

Favorite quotes from the conference:

There is a special place in hell for women who don’t help other women. ~ Madeleine Albright

Heads up to all the employers: there is a legion of women who *will* be negotiating their salaries, so budget accordingly. ~ Ruthe Farmer

Every time you don’t ask, you make it harder for every other woman to ask. ~ Matt Wallaert

I absolutely loved Grace Hopper. It’s probably my favorite of out the ones I’ve been to this year.

Hope I get to come back next year!

Leaving this here for inspiration and nostalgia: