<｜begin▁of▁sentence｜>### Instruction:
Given the High-energy theoretical physics collaborations Graph which you can read from a gml file named hep-th.gml, can you use the regularized spectral clustering function 'r_spectral_clustering' in cdlib to perform community detection with regularization based on the 20th percentile of the degree distribution? And how would you instantiate this clustering method in Python?
### Response:
import networkx as nx
from cdlib import algorithms

# Read the high-energy theory collaborations graph
G = nx.read_gml('hep-th.gml')

# Perform regularized spectral clustering
coms = algorithms.r_spectral_clustering(G, n_clusters=2, method='regularized', percentile=20)
<|EOT|>
