code: def hopfield_energy(weight, X, y):
      return -0.5 * inner1d(X.dot(weight), y)
  
file_path: neupy/neupy/algorithms/memory/bam.py
imports: import random
  import numpy
  from numpy.core.umath_tests import inner1d
  from neupy.utils import format_data
  from neupy.exceptions import NotTrained
  from .base import DiscreteMemory
label_desc: Use image node_id 3 for calling a global function with example usage: hopfield_energy(weight, X, y) and returns: unknown