<｜begin▁of▁sentence｜>### Instruction:
Given an undirected graph with edges [(0, 1), (1, 2), (2, 0), (1, 3), (3, 4), (4, 1)], how can you use the `community_leading_eigenvector` function in igraph to detect the community structure in the graph?
### Response:
import igraph as ig

# Create a graph instance
edges = [(0, 1), (1, 2), (2, 0), (1, 3), (3, 4), (4, 1)]
graph = ig.Graph(edges=edges, directed=False)

# Detect community structure
comms, merges = graph.community_leading_eigenvector()

# Print the membership vector of the detected communities
print('Community membership:', comms)
<|EOT|>
