Home
People
Research
Publications
Courses
Seminars
Links

 

Software

NOTE: The following software is provided for research purposes only. You may not distribute this software in any form without the prior approval of the University of California. 

README

Six programs are included: 

1. sofm.c: program for computing the self-organizing feature map 

2. majority_vote.c: assign the labels on the neurons obtained from sofm 

3. LVQ3.c: learning vector quantization for fine-tuning the network 

4. classifier_1.c: classify the input training data using the network 

5. classifier_2.c: organize the training data according to the class labels. 

6. codebook.c: GLA (K-means) for creating codebook within each class 

Examples

Examples of using these programs: 

1. sofm featuresTraining 10299 60 60 sofm.init_weights sofm.output_weights 30 29 0.999 10 

Note that you have to first generate sofm.init_weights using some random number generators. This file should contain 30x30(neuron numbers in one side) x60 (dimension) float numbers, for instance. "featuresTraining" is the file containing the training data. 

2. majority_vote featuresTraining featuresTraining.label 10299 60 60 30 sofm.output_weights majority_vote.output_labels 

The file "featuresTraining.label" contains 4 numbers for each training vector. In these programs, only the first number is used. The remaining numbers are for identifying where these feature vectors are extracted. 3. LVQ3 featuresTraining featuresTraining.label 10299 60 60 30 sofm.output_weights majority_vote.output_labels LVQ.output_weights 10 

After the previous three programs, we obtain two files (LVQ.output_weights and majority_vote.output_labels) which form the network, then we use this network to classify all the training data. The training vectors which are classified into the same subspace represented by the neurons of same class label will be further used in creating codebook for that corresponding class. This will be done by the following programs 

4. classifier_1 classifier.train_data LVQ.output_weights majority_vote.output_labels 30 

Note that "classifier.train_data" is a text file containing the information for running this program. In "classifier.train_data", the first line has 4 numbers (representing number of files, times to repeat the training data, number of feature dimension, and number of classes). The second line is the directory which contains the training vectors of each image file. The third line is the output directory for storing classified vectors. The remaining are the file name and followed by the number of partition in each image file (height x width). For example, in the given file "classifier.train_data", two directory called "features" and "features_class" are created, and there are 13 training data set from 13 large airphotos. 

5. classifier_2 classifier.train_data LVQ.output_weights majority_vote.output_labels 30 

This program will generate many files and store in the directory "features_class" for further processing by program "codebook". 

6. codebook features_class/ 60 60 

The file "run_codes" contain all these commands.

Home | People | Research | Publications | Courses | Seminars | Links