code: def degree_drop_weights(edge_index):
      """Returns the dropping weight of each edge depending on the degree centrality
      Args:
          edge_index (torch.Tensor): A tensor of shape [2, n_edges]
      :rtype: :class:`Tensor`
      """
      edge_index_ = to_undirected(edge_index)
      deg = degree(edge_index_[1])
      deg_col = deg[edge_index[1]].to(torch.float32)
      s_col = torch.log(deg_col)
      weights = (s_col.max() - s_col) / (s_col.max() - s_col.mean())
  
      return weights
  
file_path: DIG/dig/sslgraph/utils/adaptive.py
imports: import torch
  from torch.utils.data import random_split
  from torch_geometric.utils import degree, remove_self_loops, get_laplacian, to_undirected, to_dense_adj, to_networkx, degree, to_undirected
  from torch_scatter import scatter
  import networkx
label_desc: Use image node_id 7 for calling a global function with example usage: degree_drop_weights(edge_index) and returns: weights