class_docstr: SGL is a GCN-based recommender model.
  
  SGL supplements the classical supervised task of recommendation with an auxiliary
  self supervised task, which reinforces node representation learning via self-
  discrimination.Specifically,SGL generates multiple views of a node, maximizing the
  agreement between different views of the same node compared to that of other nodes.
  SGL devises three operators to generate the views — node dropout, edge dropout, and
  random walk — that change the graph structure in different manners.
  
  We implement the model following the original author with a pairwise training mode.
docstr: Get the normalized interaction matrix of users and items.
  
  Construct the square matrix from the training data and normalize it
  using the laplace matrix.If it is a subgraph, it may be processed by
  node dropout or edge dropout.
  
  .. math::
      A_{hat} = D^{-0.5} \times A \times D^{-0.5}
  
  Returns:
      csr_matrix of the normalized interaction matrix.
docstr_tok: ["Get","the","normalized","interaction","matrix","of","users","and","items",".","Construct","the","square","matrix","from","the","training","data","and","normalize","it","using","the","laplace","matrix.If","it","is","a","subgraph",",","it","may","be","processed","by","node","dropout","or","edge","dropout",".","..","math",":",":","A_","{","hat","}","=","D^","{","-0.5","}","\\times","A","\\times","D^","{","-0.5","}","Returns",":","csr_matrix","of","the","normalized","interaction","matrix","."]
code: def create_adjust_matrix(self, is_sub: bool):
      r"""Get the normalized interaction matrix of users and items.
  
      Construct the square matrix from the training data and normalize it
      using the laplace matrix.If it is a subgraph, it may be processed by
      node dropout or edge dropout.
  
      .. math::
          A_{hat} = D^{-0.5} \times A \times D^{-0.5}
  
      Returns:
          csr_matrix of the normalized interaction matrix.
      """
      matrix = None
      if not is_sub:
          ratings = np.ones_like(self._user, dtype=np.float32)
          matrix = sp.csr_matrix(
              (ratings, (self._user, self._item + self.n_users)),
              shape=(
                  self.n_users + self.n_items,
                  self.n_users + self.n_items,
              ),
          )
      else:
          if self.type == "ND":
              drop_user = self.rand_sample(
                  self.n_users,
                  size=int(self.n_users * self.drop_ratio),
                  replace=False,
              )
              drop_item = self.rand_sample(
                  self.n_items,
                  size=int(self.n_items * self.drop_ratio),
                  replace=False,
              )
              R_user = np.ones(self.n_users, dtype=np.float32)
              R_user[drop_user] = 0.0
              R_item = np.ones(self.n_items, dtype=np.float32)
              R_item[drop_item] = 0.0
              R_user = sp.diags(R_user)
              R_item = sp.diags(R_item)
              R_G = sp.csr_matrix(
                  (
                      np.ones_like(self._user, dtype=np.float32),
                      (self._user, self._item),
                  ),
                  shape=(self.n_users, self.n_items),
              )
              res = R_user.dot(R_G)
              res = res.dot(R_item)
  
              user, item = res.nonzero()
              ratings = res.data
              matrix = sp.csr_matrix(
                  (ratings, (user, item + self.n_users)),
                  shape=(
                      self.n_users + self.n_items,
                      self.n_users + self.n_items,
                  ),
              )
  
          elif self.type == "ED" or self.type == "RW":
              keep_item = self.rand_sample(
                  len(self._user),
                  size=int(len(self._user) * (1 - self.drop_ratio)),
                  replace=False,
              )
              user = self._user[keep_item]
              item = self._item[keep_item]
  
              matrix = sp.csr_matrix(
                  (np.ones_like(user), (user, item + self.n_users)),
                  shape=(
                      self.n_users + self.n_items,
                      self.n_users + self.n_items,
                  ),
              )
  
      matrix = matrix + matrix.T
      D = np.array(matrix.sum(axis=1)) + 1e-7
      D = np.power(D, -0.5).flatten()
      D = sp.diags(D)
      return D.dot(matrix).dot(D)
  
imports: import numpy
  import scipy.sparse
  import torch
  from recbole.model.abstract_recommender import GeneralRecommender
  from recbole.model.init import xavier_uniform_initialization
  from recbole.model.loss import BPRLoss, EmbLoss
  from recbole.utils import InputType
  import torch.nn.functional
label_desc: Use image node_id 4 for calling the SGL obj's underlying member method code with example usage: obj.create_adjust_matrix(is_sub) and returns: D