File Exchange

image thumbnail

Unsupervised Learning with Growing Neural Gas (GNG) Neural Network

version 1.0 (11.7 KB) by

Learns data clusters and their topology in n-dimensional space by using the Growing Neural Gas net.

12 Downloads

Updated

View License

The Growing Neural Gas (GNG) Neural Network belongs to the class of Topology Representing Networks (TRN's). It can learn supervised and unsupervised. Here, the on-line, unsupervised learning mode is implemented and demonstrated. It's learning method employs a combination of modified Kohonen learning to adjust the neuron's positions, with a Competitive Hebbian Learning (CHL) for its connections. For details please consult ref. [1]. In order to make the main script (gng_lax.m) functional, you must first select and generate a manifold (data) using the corresponding data generator. For a nice report on the family of competitive learning methods please consult ref. [2].

REFERENCE
[1] Fritzke B. "A Growing Neural Gas Network Learns Topologies", Advances in Neural Information Processing Systems 7, MIT Press, Cambridge MA, 1995.

[2] Fritzke B. "Some Competitive Learning Methods", 1997 available at: ftp://ftp.neuroinformatik.ruhr-uni-bochum.de/pub/software/NN/DemoGNG/sclm.ps.gz

Comments and Ratings (19)

Ilias Konsoulas

@ David Franco.

1) This can be a result of inadequate learning parameters. Having only 2 nodes at the end means that your added nodes die too soon before they manage to create edges with their neighbors. Therefore, try to increase the max_age parameter or reduce the age_inc parameter. Also, note that the final picture does not contain the original data samples that appear in light green on my picture. I added those using separate commands after a whole learning session was complete for better appearance of the image.

2) The presence of clear command at the end of data generators (manifolds) is not a mistake. I clear the data on purpose to release the occupied memory. The necessary data were saved before the clear commands in the .mat files. Those .mat files are invoked in the beginning of gng_lax.m file which is the main program.

3) Regarding the "shortage" of data samples issue please read below my 21st Oct 2014 answer to Parivash Ashrafi. It's not a problem of the code because you can generate more data points if you wish using the given generators.

Before grading a project in the future, please make sure you understood the code well.

David Franco

Why my first subplot (GNN nodes and edges) doesn't show the entire figure, like yours, just two points? I changed some values in the code but didn't get the entire image...

David Franco

There is a mistake in the "loc_3d_multi_manifold.m" file: there are a 'clear' command inside the function, wich clear the input data.

The main function doesn't work if the number of samples of the dataset is smaller than NumOfEpochs*NumOfSamples in the main code.

Everything is OK.

Thanks!

Please do you have the PDF file of this Mat file ,I need it to see the results

Ilias Konsoulas

@ Basheer
No, the lenght of the edges is adjusted automatically by the GNG algorithm. However, this could potentially a good idea for research.

Hello,
Can I control the length of the edges ?

Thank you so much for your replies and help...

Ilias Konsoulas

@ ybg and @ Parivash. Obviously, you face a lack of data points issue. You can overcome this minor problem by either: 1) Reducing the data samples per Training Epoch (NumOfSamples) , 2) Reduce the Number of Training Epochs (NumOfEpochs) or 3) Generate more data using the given data generators.

Ilias Konsoulas

@ ybg and @ Parivash. Obviously, you face a lack of enough data samples issue. You can overcome this minor "problem" by either: 1) Reducing the used data samples per Training Epoch (NumOfSamples) , 2) Reduce the Number of Training Epochs (NumOfEpochs) or 3) Generate more data using the given data generators.

ybg

ybg (view profile)

@Parivash Ashrafi
I experienced same problem.
I think, variable, NumOfSamples in gng_lax.m does not mean number of samples of data generators.
You may already know, this code don't operate if there are enough sample data. Anyway, To operate this code, NumOfSamples*NumOfEpochs is required or more.

ybg

ybg (view profile)

hello. Nobody is here to answer my question plz...

I get an error when I run it loading local_uniform_2d.mat because it is a 2*400 size matrix and in line 74 in the second loop the Index exceeds matrix dimensions. because it wants to go for Data(:,400:800)
which does not exist! What is the problem. Please help. Thanks

Pedro Ribeiro

Ilias Konsoulas

@Pedro and @Patricia: Thnks a lot for your kind words.

Pedro Ribeiro

The outstanding quality of this implementation of the GNG algorithm is truly remarkable. Many thanks are in order to congratulate Mr. Ilias Konsoulas for his astonishing work.

I would like to congratulate you for the excellent work done was of great value to my studies.

Thank you.

MATLAB Release
MATLAB 7.13 (R2011b)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video