<｜begin▁of▁sentence｜>### Instruction:
Given a random graph with 100 nodes and 300 edges generated using the G(n, m) random graph model, can you use the EdMot model to perform motif-aware community detection and provide the cluster memberships?
### Response:
import networkx as nx
from karateclub import EdMot

# Create a graph
G = nx.gnm_random_graph(100, 300)

# Initialize EdMot with default parameters
model = EdMot()

# Fit the model on the graph
def fit_graph(model, graph):
    model.fit(graph)

# Get the cluster memberships of nodes
def get_memberships(model):
    return model.get_memberships()

fit_graph(model, G)
memberships = get_memberships(model)
print(memberships)
<|EOT|>
