CONTENTS 1. THE SHAPE MATCHER APPLICATION 2. FIRST EXAMPLE 3. FINDING HELP FOR THE SHAPE MATCHER 4. IMPORTANT COMMAND-LINE OPTIONS FOR SHOCK GRAPH COMPUTATION 5. THE DATABASE DESIGN 6. LIST OF COMMAND LINE OPTIONS _______________________________________________________________________________________ 1. THE SHAPE MATCHER APPLICATION This program allows you to compute skeletons and their corresponding shock graphs. Skeletons and shock graphs are stored into a database file which can be used for matching experiments or simply to visualize shock graphs. The given distribution package DAGMatcher5.tgz includes sm: the "ShapeMatcher 5.2" executable help.txt: can be read by running "dm -h" or by using a text editor dog.ppm: an example ppm image _______________________________________________________________________________________ 2. FIRST EXAMPLE Building a database sm -c example.db test_images/Models120 This reads all the subdirectories under test_images/Models120 and computes the shock graphs for all the ppm or pgm files found. When building a database, we see each image as a view of some object. While this may not be relevant for your application, it is still relevant to know that the image file names are parsed such that the "name of the object" is assumed to be the name of the directory that contains it, and the "view number" is taken from the file name (e.g., X/objname/prefixNNN.ppm). See the list of the objects just added sm -l example.db View one particular object sm -v 20 example.db This shows the skeleton of the object (see the window's title bar for options). To see the shock graph of the shape, press 'a' with the window in focus. This should open another window with a shock graph in it. Right click on the nodes to see some options. All the output is sent to the current terminal. Add a new shock graph to the database (use -a instead of -c) sm -a example.db test_images/dog/dog.ppm Match view 20 against the entire database (output goes in example_results0.log) sm -m 20 example.db Match a database against another (both databases can be the same) and produce some statistics in Matlab format. sm -stats 1 -m query.db model.db _______________________________________________________________________________________ 3. FINDING HELP FOR THE SHAPE MATCHER Run "./sm" to get a list of the command-line options and their current values. _______________________________________________________________________________________ 3. IMPORTANT COMMAND-LINE OPTIONS FOR SHOCK GRAPH COMPUTATION -skelcode: when set to 2, it selects an skeletonization code developed at McGill university by Kaleem Siddiki's group. If it is set to 3, 'sm' will use the skeletonization code developed by Alex Telea. -tsTau2: threshold for ignoring evenets on the shape boundary. It should be greater or equat to 1. In general, 20 [the default] seems to be a reasonable value for this option. _______________________________________________________________________________________ 5. THE DATABASE DESIGN The information stored in a ShapeMatcher database is only readable by the ShaopeMatcher application at this point. However, it should not be to difficult to add the needed functionality to output it's content in XML format. This has not been done simply because we never had the need. You can export a graph from the LEDA Graph Window in several formats, but that would not include all the node attributes (only their labels). We will not be writing the XML functionality in the short term, but we can help any one willing to do so. _______________________________________________________________________________________ 6. LIST OF COMMAND LINE OPTIONS NOTE: A "shape" is represented as a Directed Acyclic Graph (DAG), so DAG == shape in the ShapeMatcher help. -d or -debug Generate a number of log files -c or -create Create database of shock graphs -a or -add Add DAG to DB -l or -list List DAGs in the database -s or -size Shows the database size in num. of views -i or -createIndex Explicitly creates the DB index -m or -match [val] Match DAG [DAG ID] -p or -plot Plot DAG node info -v or -view [val] Visualize a DAG -w or -mview Visualize all DAGs -nodeMatch Match node v1 in graph G1 to v2 in G2 -matrix [val] Outputs similarity matrix to file [val] for all the models in the database -checkSGGrammar Checks the shock graph grammar of all graphs -delete Delete DAGs from database -extract Extract DAGs from database -updatedb Read in the db and write it back -recomputeSG Recomputes all SG an saves them in another DB -splitdb [val] Split database in N%, (100-N)% pieces -mergedb Merge databases (dest src1 src2 ...) -test Test all the object in the DB -objNames List object names in the database -delObjects Removes all dags of given objects -clos3NeigList List the 3 closest neighbours of each view -clos9NeigList List the 9 closest neighbours of each view -getNeig [val] List the neighbours withing a given range in deg. -h or -help Display a man page for this program -tsvSimWeight [val] TSV similarity weight -simMassWeight [val] Similarity vs Mass weight -relMassWeight [val] Relative mass of the query vs. tot model -simFuncType [val] Node similarity function -nodeDistFunc [val] Node distance function -minNodeSim [val] Minimum node similarity allowed -sibRelPen [val] Penalty term for breaking sibling's relationship (1=max) -presAncRel [val] Preserve ancestor relationships when matching -useNewVWF [val] Use new vote weighting function -useMOOVC [val] Use multiple one-to-one vote counting -modelSimWeight [val] Model similarity weight -idxRange [val] Index range -kBest [val] Match only k best from index -idxTau [val] Index similarity threshold -matchTau [val] Matcher similarity threshold -stats [val] Compute view statistics -asyncCompu [val] Compute SG's in async mode (see timeout) -showResults [val] Show matching results -saveResults [val] Save matching results -o or -objName [val] Set object name -iterations [val] Parameter for the SG computation -maxDags [val] Maximum number of DAGs to process -imgStep [val] Image step -from [val] Match DAGs from ID N -to [val] Match DAGs up to ID M -maxOcclRate [val] Maximum occlusion rate -saveSubsamplingInfo [val] Save info to split DB when matching -splitByObject [val] Split DB by object -bumpSize [val] Size of noise bumps -notchSize [val] Size of noise notches -outDir [val] Sets the output directory for noisy images -timeout [val] SG computation Timeout in seconds -skelcode [val] Use skeletoniaztion code number = {1, 2, 3} -split3s [val] Should split 3s into left and right 3s -minslope [val] Slope that is to be considered as zero -minerror [val] Coeff for max min-least-square error tolerated -maxydiff [val] Maximum difference in y-coord discontinuity -skthreshold [val] Parameter for the skeleton computation -maxaccelchg [val] Max acceleration chage tolerated -tsTau1 [val] TreeSkel threshold number 1 -tsTau2 [val] TreeSkel threshold number 2 -bndryWeight [val] Boundary reconstruction error weight -strucWeight [val] Structural reconstruction error weight -doExtSimp [val] Perform the external branch simplification on the skeleton -doIntSimp [val] Perform the internal branch simplification on the skeleton -doCompleteSimp [val] Perform the external as well as the internal branch simplification on the skeleton -verbose [val] Execute in verbose mode