8e20474044b2 — Chris Cannam tip 28 days ago
Comments and debug output only
1 files changed, 5 insertions(+), 1 deletions(-)

M feature-fn.sml
M feature-fn.sml +5 -1
@@ 121,6 121,10 @@ end
      to 127, bins 35 to 83), where all energy above note 127 is mapped
      into the final bin." (all assuming reference 440Hz; midi note 127
      corresponds to 12544Hz)
+
+     Note that the referenceFrequency parameter only affects bin
+     mappings above the crossover point. Below that, the mapping is
+     determined entirely by FFT bin width.
 *)
 functor SemitoneishFeatureBlockStreamFn (S : FREQUENCY_DOMAIN_BLOCK_STREAM) :
         sig

          
@@ 170,7 174,7 @@ functor SemitoneishFeatureBlockStreamFn 
             val crossoverMidi = round (Pitch.pitchForFrequency
                                            (real crossoverBin * binWidth,
                                             referenceFrequency))
-            val () = info (fn () => ["SemitoneishFeatureBlockStreamFn: crossoverMidi = %1 with referenceFrequency = %2", I crossoverMidi, O (Option.map R referenceFrequency)])
+            val () = info (fn () => ["SemitoneishFeatureBlockStreamFn: crossoverMidi = %1 (%2 Hz with referenceFrequency = %3)", I crossoverMidi, R (real crossoverBin * binWidth), O (Option.map R referenceFrequency)])
             fun inRange freq =
                 case (minFrequency, maxFrequency) of
                     (NONE, NONE) => true