code: private static void weightAdjoint(final Hypergraph graph, final Hyperpotential w, final Algebra s,
              final Scores scores, boolean backOutside) {
          final double[] weightAdj = new double[graph.getNumEdges()];
          HyperedgeDoubleFn lambda = new HyperedgeDoubleFn() {
              public void apply(Hyperedge e, double val) {
                  weightAdj[e.getId()] = val;
              }
          };
          weightAdjoint(graph, w, s, scores, lambda, backOutside);
          scores.weightAdj = weightAdj;
      }
docs: Computes the adjoints of the hyperedge weights.
  
  INPUT: scores.alpha, scores.beta, scores.alphaAdj, scores.betaAdj.
  OUTPUT: scores.weightsAdj.
  
  @param graph The hypergraph
  @param w The potential function.
  @param s The semiring.
  @param scores Input and output struct.