docs: def build(self, X, Y, w=None, edges=None):
          """ Assigns data to this object and builds the Merge Tree
              @ In, X, an m-by-n array of values specifying m
              n-dimensional samples
              @ In, Y, a m vector of values specifying the output
              responses corresponding to the m samples specified by X
              @ In, w, an optional m vector of values specifying the
              weights associated to each of the m samples used. Default of
              None means all points will be equally weighted
              @ In, edges, an optional list of custom edges to use as a
              starting point for pruning, or in place of a computed graph.
          """
          super(MergeTree, self).build(X, Y, w, edges)
  
          if self.debug:
              sys.stdout.write("Merge Tree Computation: ")
              start = time.clock()
  
          self.__tree = MergeTreeFloat(
              vectorFloat(self.Xnorm.flatten()),
              vectorFloat(self.Y),
              str(self.gradient),
              self.graph_rep.full_graph(),
              self.debug,
          )
  
          self._internal_build()
  
          if self.debug:
              end = time.clock()
              sys.stdout.write("%f s\n" % (end - start))