input: string, name of a file containing a Bioquali-like graph description
  output: asp.TermSet, with atoms matching the contents of the input file
  
  Parses a Bioquali-like graph description, and returns
  a TermSet object.
  Written using original Bioquali

def readSIFGraph(filename):
  p = sif_parser.Parser(filename)
  """
  input: string, name of a file containing a Bioquali-like graph description
  output: asp.TermSet, with atoms matching the contents of the input file
  
  Parses a Bioquali-like graph description, and returns
  a TermSet object.
  Written using original Bioquali
  """

  accu = TermSet()
  file = open(filename,'r')
  s = file.readline()
  while s!="":
    try: accu = p.parse(s)
    except EOFError: break
    s = file.readline()
  return accu