d@74: (in-package "AMUSE-SEGMENTATION") d@74: d@74: (defgeneric boundary-strength (segmenter object composition) d@74: (:documentation "Returns a (positive?) number, with 0 d@74: indicating no boundary. N.B. Whether this indicates a boundary d@74: before or after moment-designator is the responsibility of the d@74: caller to know.")) d@74: d@74: (defgeneric boundary-time (segmenter object) d@74: (:documentation "Returns the moment that the value returned by d@74: boundary-strength applies to if object is the second input to d@74: the method. Essentially, this distinguishes between segmenters d@74: that look to the beginning of a note and those that look at the d@74: end.") d@74: d@74: (defgeneric ground-truth-segmenter-before (composition) d@74: (:documentation "Returns the segmenter that, when put into d@74: boundary-strength, supplies segmentation as given in a d@74: ground truth for the composition. N.B. This needs to return one d@74: segmenter only, so in cases of multiple ground truths, this d@74: method must arbitrate.")) d@74: d@74: (defgeneric ground-truth-segmenter-after (composition) d@74: (:documentation "Returns the segmenter that, when put into d@74: boundary-strength-after, supplies segmentation as given in a d@74: ground truth for the composition. N.B. This needs to return one d@74: segmenter only, so in cases of multiple ground truths, this d@74: method must arbitrate.")) d@74: d@74: (defgeneric ground-truth-segmenterp (segmenter)) ;; prob not necessary? d@74: (defgeneric segments-beforep (segmenter)) d@74: (defgeneric segments-afterp (segmenter) d@74: (:method (s) (not (segments-beforep s))))