class_docstr: NNCF is an neural network enhanced matrix factorization model which also captures neighborhood information.
  We implement the NNCF model with three ways to process neighborhood information.
code: def __init__(self, config, dataset):
      super(NNCF, self).__init__(config, dataset)
  
      # load dataset info
      self.LABEL = config["LABEL_FIELD"]
      self.interaction_matrix = dataset.inter_matrix(form="coo").astype(
          np.float32
      )
  
      # load parameters info
      self.ui_embedding_size = config["ui_embedding_size"]
      self.neigh_embedding_size = config["neigh_embedding_size"]
      self.num_conv_kernel = config["num_conv_kernel"]
      self.conv_kernel_size = config["conv_kernel_size"]
      self.pool_kernel_size = config["pool_kernel_size"]
      self.mlp_hidden_size = config["mlp_hidden_size"]
      self.neigh_num = config["neigh_num"]
      self.neigh_info_method = config["neigh_info_method"]
      self.resolution = config["resolution"]
  
      # define layers and loss
      self.user_embedding = nn.Embedding(
          self.n_users, self.ui_embedding_size
      )
      self.item_embedding = nn.Embedding(
          self.n_items, self.ui_embedding_size
      )
      self.user_neigh_embedding = nn.Embedding(
          self.n_items, self.neigh_embedding_size
      )
      self.item_neigh_embedding = nn.Embedding(
          self.n_users, self.neigh_embedding_size
      )
      self.user_conv = nn.Sequential(
          nn.Conv1d(
              self.neigh_embedding_size,
              self.num_conv_kernel,
              self.conv_kernel_size,
          ),
          nn.MaxPool1d(self.pool_kernel_size),
          nn.ReLU(),
      )
      self.item_conv = nn.Sequential(
          nn.Conv1d(
              self.neigh_embedding_size,
              self.num_conv_kernel,
              self.conv_kernel_size,
          ),
          nn.MaxPool1d(self.pool_kernel_size),
          nn.ReLU(),
      )
      conved_size = self.neigh_num - (self.conv_kernel_size - 1)
      pooled_size = (
          conved_size - (self.pool_kernel_size - 1) - 1
      ) // self.pool_kernel_size + 1
      self.mlp_layers = MLPLayers(
          [
              2 * pooled_size * self.num_conv_kernel
              + self.ui_embedding_size
          ]
          + self.mlp_hidden_size,
          config["dropout"],
      )
      self.out_layer = nn.Linear(self.mlp_hidden_size[-1], 1)
      self.dropout_layer = torch.nn.Dropout(p=config["dropout"])
      self.loss = nn.BCEWithLogitsLoss()
  
      # choose the method to use neighborhood information
      if self.neigh_info_method == "random":
          self.u_neigh, self.i_neigh = self.get_neigh_random()
      elif self.neigh_info_method == "knn":
          self.u_neigh, self.i_neigh = self.get_neigh_knn()
      elif self.neigh_info_method == "louvain":
          self.u_neigh, self.i_neigh = self.get_neigh_louvain()
      else:
          raise RuntimeError(
              "You need to choose the right algorithm of processing neighborhood information. \
                  The parameter neigh_info_method can be set to random, knn or louvain."
          )
  
      # parameters initialization
      self.apply(self._init_weights)
  
imports: import torch
  import torch.nn
  from torch.nn.init import normal_
  from recbole.model.abstract_recommender import GeneralRecommender
  from recbole.model.layers import MLPLayers
  from recbole.utils import InputType
  from recbole.model.general_recommender.itemknn import ComputeSimilarity
  import numpy
label_desc: Use image node_id 1 to create a new NNCF object from inherited base classes: GeneralRecommender with example: obj = NNCF(config, dataset)