docstr: Processes test set and returns dictionary containing
  user-item idx as key and score as value.
  
  Parameters
  ----------
  test_set : cornac.data.dataset.Dataset
      The data set as provided by cornac
      Returns
  
  Returns
  -------
  u_i_rating_dict : dict
      Dictionary containing '{user_idx}-{item_idx}' as key
      and {score} as value.
docstr_tok: ["Processes","test","set","and","returns","dictionary","containing","user-item","idx","as","key","and","score","as","value",".","Parameters","--","--","--","--","--","test_set",":","cornac.data.dataset.Dataset","The","data","set","as","provided","by","cornac","Returns","Returns","--","--","--","-","u_i_rating_dict",":","dict","Dictionary","containing","'","{","user_idx","}","-","{","item_idx","}","'","as","key","and","{","score","}","as","value","."]
code: def predict(self, test_set):
      """
      Processes test set and returns dictionary containing
      user-item idx as key and score as value.
  
      Parameters
      ----------
      test_set : cornac.data.dataset.Dataset
          The data set as provided by cornac
          Returns
  
      Returns
      -------
      u_i_rating_dict : dict
          Dictionary containing '{user_idx}-{item_idx}' as key
          and {score} as value.
      """
      test_dec_graph = self._generate_dec_graph(test_set)
      test_dec_graph = test_dec_graph.int().to(self.device)
  
      self.net.eval()
  
      with torch.no_grad():
          pred_ratings = self.net(self.train_enc_graph, test_dec_graph)
  
      nd_positive_rating_values = torch.FloatTensor(
          self.rating_values
      ).to(self.device)
  
      test_pred_ratings = (
          torch.softmax(pred_ratings, dim=1)
          * nd_positive_rating_values.view(1, -1)
      ).sum(dim=1)
  
      test_pred_ratings = test_pred_ratings.cpu().numpy()
  
      user_nodes, item_nodes, _ = test_set.uir_tuple
      u_i_rating_dict = {
          f"{user_nodes[idx]}-{item_nodes[idx]}": rating
          for idx, rating in enumerate(test_pred_ratings)
      }
      return u_i_rating_dict
  
imports: import logging
  import time
  from collections import defaultdict
  import torch
  from torch import nn
  import dgl
  import numpy
  import scipy.sparse
  from tqdm import tqdm
  from .nn_modules import NeuralNetwork
  from .utils import get_optimizer, torch_net_info, torch_total_param_num
label_desc: Use image node_id 9 for calling the Model obj's underlying member method code with example usage: obj.predict(test_set) and returns: u_i_rating_dict