code: def calculate_scores(self, ground_truth, predict):
      correct = 0
      assert len(ground_truth) == len(predict)
      for gt, pred in zip(ground_truth, predict):
          gt = gt.strip()
          pred = pred.strip()
  
          result = True
          c1 = gt
          c2 = pred
          if ("=" not in c1) or ("=" not in c2):
              result = False
          else:
              try:
                  s1 = c1.split("=")
                  s2 = c2.split("=")
                  eq1 = []
                  eq2 = []
                  x = sympy.Symbol("x")
                  eq1.append(parse_expr(s1[0]))
                  eq1.append(parse_expr(s1[1]))
                  eq2.append(parse_expr(s2[0]))
                  eq2.append(parse_expr(s2[1]))
                  res1 = sympy.solve(sympy.Eq(eq1[0], eq1[1]), x)
                  res2 = sympy.solve(sympy.Eq(eq2[0], eq2[1]), x)
  
                  if not res1 or not res2:
                      result = False
                  result = res1[0] == res2[0]
              except BaseException:
                  result = False
          if result:
              correct += 1.0
      return correct / len(ground_truth)
  
file_path: graph4nlp/examples/pytorch/math_word_problem/mawps/src/evaluation.py
imports: from graph4nlp.pytorch.modules.evaluation.base import EvaluationMetricBase
  import sympy
  from sympy.parsing.sympy_parser import parse_expr
label_desc: Use image node_id 2 for calling the SolutionMatch obj's underlying member method code with example usage: obj.calculate_scores(ground_truth, predict) and returns: unknown