com.meapsoft.composers
Class HMMComposer

java.lang.Object
  extended bycom.meapsoft.MEAPUtil
      extended bycom.meapsoft.composers.Composer
          extended bycom.meapsoft.composers.VQComposer
              extended bycom.meapsoft.composers.HMMComposer
All Implemented Interfaces:
java.lang.Runnable

public class HMMComposer
extends VQComposer

Program that learns a simple fully connected hidden Markov model from a FeatFile and generates chunk sequences from it. This doesn't produce very compelling compositions because the markov assumption (that the currect chunk only depends on the previous chunk) is not at all valid for most music which has a more complex structure. Later versions will support more constrained HMM topologies that should make for more interesting compositions. All about HMMs: http://en.wikipedia.org/wiki/Hidden_Markov_model


Field Summary
static java.lang.String description
           
 
Fields inherited from class com.meapsoft.composers.VQComposer
beatsPerCodeword, cbSize, debug, dist, featdim, featsToQuantize, outFileName, templateChunks, trainFile
 
Fields inherited from class com.meapsoft.MEAPUtil
bigEndian, bitsPerSamp, exceptionHandler, frameLatency, mixerToUse, numChannels, progress, samplingRate, signed, slash, stereo, verbose, version, writeMEAPFile
 
Constructor Summary
HMMComposer(FeatFile trainFN, EDLFile outFN)
           
HMMComposer(java.lang.String[] args)
           
 
Method Summary
 EDLFile compose()
          Compose an EDLFile.
static void main(java.lang.String[] args)
           
 void printUsageAndExit()
           
 void setSequenceLength(int len)
           
 
Methods inherited from class com.meapsoft.composers.VQComposer
learnCodebook, quantizeChunk, setBeatsPerCodeword, setCodebookSize, setFeatsToQuantize, setup
 
Methods inherited from class com.meapsoft.composers.Composer
addCommand, addCommandsToAllEDLChunks, addCommandsToAllEDLChunks, addCommandToAllEDLChunks, description, doComposer, parseCommands, printCommandLineOptions, run
 
Methods inherited from class com.meapsoft.MEAPUtil
bytes2doubles, doubles2bytes, getPaths, getProgress, openAudioWriter, openAudioWriter, openInputStream, openInputStream, parseChunkDist, parseFeatDim, parseFeatureExtractor, parseFeatureExtractor, printCommandLineOptions, setExceptionHandler
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

description

public static java.lang.String description
Constructor Detail

HMMComposer

public HMMComposer(FeatFile trainFN,
                   EDLFile outFN)

HMMComposer

public HMMComposer(java.lang.String[] args)
Method Detail

printUsageAndExit

public void printUsageAndExit()
Overrides:
printUsageAndExit in class VQComposer

setSequenceLength

public void setSequenceLength(int len)

compose

public EDLFile compose()
Description copied from class: Composer
Compose an EDLFile. This is where the magic happens.

Overrides:
compose in class VQComposer

main

public static void main(java.lang.String[] args)