<｜begin▁of▁sentence｜>### Instruction:
Given a list of dictionaries representing vertices, each with a 'name' attribute, and a list of dictionaries representing edges with 'source', 'target', and 'weight' attributes, how can you use the Graph.DictList constructor from the igraph library to create an undirected graph from these lists and then print a summary of the graph?
### Response:
from igraph import Graph

# Define the vertices with their attributes
vertices = [{'name': 'apple'}, {'name': 'pear'}, {'name': 'peach'}]

# Define the edges with the connections and attributes
edges = [
    {'source': 'apple', 'target': 'pear', 'weight': 1.2},
    {'source': 'apple', 'target': 'peach', 'weight': 0.9}
]

# Create the graph using the DictList constructor
g = Graph.DictList(vertices=vertices, edges=edges, directed=False, vertex_name_attr='name', edge_foreign_keys=('source', 'target'))

# Print the summary of the graph
print(g.summary())
<|EOT|>
