code: def add_session(session, graph):
      """
      For session like:
          [sku1, sku2, sku3]
      add 1 weight to each of the following edges:
          sku1 -> sku2
          sku2 -> sku3
      If sesson length < 2, no nodes/edges will be added
      """
      for i in range(len(session) - 1):
          edge = str(session[i]) + "," + str(session[i + 1])
          try:
              graph[edge] += 1
          except KeyError:
              graph[edge] = 1
  
file_path: dgl/examples/pytorch/eges/utils.py
imports: import argparse
  import random
  from datetime import datetime
  import dgl
  import networkx
  import numpy
  import torch
label_desc: Use image node_id 4 for calling a global function with example usage: add_session(session, graph) without return types