<｜begin▁of▁sentence｜>### Instruction:
Given a graph where edges have a 'weight' attribute, can you use `EdgeSeq.select` function from igraph to select all edges with weights greater than 50? You need to return the ids and weights of these heavy edges.
### Response:
from igraph import Graph

# Creating a graph with edge attributes
g = Graph.Erdos_Renyi(10, 0.5)
g.es['weight'] = [2, 3, 75, 44, 5, 61, 27, 3, 18, 59, 36, 13, 42, 7, 2, 21, 9, 10, 25, 1]

# Selecting edges with weight greater than 50
heavy_edges = g.es.select(weight_gt=50)

# Printing the ids and weights of these heavy edges
print([(e.index, e.attributes()['weight']) for e in heavy_edges])
<|EOT|>
