Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
26th August 2005, 03:28 | #1 | Link |
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
Neural Network Processing
I have serached the forum for Neural network processing but could not find any. I thought atleast the forum maintained by neuron2(name suggests it must have) may have some but am disappointed.
I do not know how far neural network processing will be practical in video image processing, but I hope it will be. I therefore did some preliminary work and could get some results which I present here. My input for this is a greyscale image which I used in the thread "recoloring". I first did an edge detection with a plugin of mine and its output is below: A small window of 100X150 located in lower middle of this edge map is used for training. The window used is below: I iterated 1600 times for optimising layer weights using steepest descent method. Unlike my edge map which has values of either 0 or 255, the output of neural processing I found were in a range of 52 to 77 percent ( values of 132 to 196) but with a noticeable steep step across 66 to 67% (or around a value of 169). Output image (neural processing done on full frame) with 168 as threshold is below: Output image with 170 as threshold is below: While ideally a noise free image should be used for training my input is with noise. Possibly I should use a cartoon image for training. Or the part with balloons may have less noise. Other details: Input edge detection was with a 3X3 grid. Neural network input was also 3X3 grid. Hidden layer has 9 nodes and output layer 3 nodes. I would appreciate suggestions on any further work, input models etc; . My plugin is in initial stages and need to do some more work. Currently my function handles one plane only. So color can not be handled at this stage. The range of weights to be used for hidden and output layers as well as number of iterations can be specified but I would like to do some automation in this area. While the improvement with each iteration can be gauged with an error parameter, with Avisynth I can not get this value interactively. |
26th August 2005, 04:18 | #2 | Link |
Guest
Join Date: Jan 2002
Posts: 21,901
|
Neural networks come into their own when there are actually instantiated units to permit massively parallel processing. Simulating that serially is pointless. The algorithms just implement known things like gradient descent, etc. There's nothing magical about a "neural network algorithm".
|
26th August 2005, 09:38 | #3 | Link |
Clouded
Join Date: Jul 2003
Location: Cambridge, UK
Posts: 1,148
|
Perhaps it's worth trying some other edge marks for comparison?
There's a whole bundle in a Photoshop plug-in here: http://members.ozemail.com.au/~binar...volcorner.html The one I prefer for most purposes is Prewitt, which I made an YV12 AVISynth version of: http://people.pwf.cam.ac.uk/mg262/po...tt_08Aug05.dll Prewitt(bool thin = false) The brightness of output will correspond to the strength of an edge. It will all be relatively dark, so you might want to follow it up with a Levels call (with coring off). Have a look through and see what you think... .
__________________
a.k.a. Clouded. Come and help by making sure your favourite AVISynth filters and scripts are listed. |
27th August 2005, 03:32 | #4 | Link |
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
What I am looking for is not an edge detection algorithm. There are many. I am exploring Neural networks and just took in edge detection as an excercise. There may be other applications which I want to explore. It may be wasteful of time, but I have some time with me. I want suggestions as to which other applications I can try.
|
27th August 2005, 18:45 | #7 | Link | |
Guest
Join Date: Jan 2002
Posts: 21,901
|
Quote:
Now if you are asking can some algorithm like simulated annealing, which is typically targeted at parallel architectures, be useful for video processing, that is a more interesting question. I haven't seen such processing of video on PCs, presumably because it is dreadfully slow. Of course, no one has yet figured out how to implement human intelligence on a network of simulated neurons. Even if that were achieved, running it on a serial processor would probably be way too slow. Last edited by Guest; 27th August 2005 at 18:55. |
|
28th August 2005, 02:04 | #8 | Link |
Registered User
Join Date: Oct 2003
Location: Germany
Posts: 377
|
lik 1
I would say that NN are good when it is difficult to set a right threshold, for example segmentation, scene-change-detection, deflicker... But in general for all those things for which there is no good algorithm available (for scene-change-detection there are some). I searched a littlebit though the net and searched for "image processing" "neural net". Most of the stuff ist scientific or a link to a book. |
28th August 2005, 04:11 | #9 | Link | ||
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
Quote:
Quote:
As for Zarxarax,s suggestion of noise elimination, I have been thinking using my Fan Filter as a training material. Right now I am not sure as to how many output nodes I need. I am also to understand in more detail the requirements of number of nodes, their starting weights, the number of layers etc. I am aware that all my efforts may not yield any practical or usable process and has to be discarded. However at this stage I am not put off by those considerations. On the otherhand I am optimistic about the outcome. A google search for ANN applications indicates mostly stock market predictions, and some medical image Analysis. I am sure some part of this analysis will be applicable to video images also. May be similar to stock prediction, motion can be predicted? |
||
28th August 2005, 17:46 | #10 | Link |
Registered User
Join Date: Mar 2002
Posts: 1,075
|
You could train a NN for determining image dependent filters (ie train a NN to provide weights for a linear filter depending on the input).
Doesnt make much sense to train a NN with input/output of an existing filter though, unless the filter is very slow and a NN could approximate it faster. VQ is actually better for this though. Usually you train with known correct reference images. Last edited by MfA; 28th August 2005 at 17:49. |
29th August 2005, 03:12 | #11 | Link | |
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
Quote:
Being not a proffessional I did not understand what a VQ is. |
|
29th August 2005, 04:52 | #12 | Link | |
Guest
Join Date: Jan 2002
Posts: 21,901
|
Quote:
|
|
30th August 2005, 04:00 | #13 | Link |
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
Thanks for the reference. I had a quick glimpse at VQ page. It certainly put me off with all those mathematical symbols. However I felt that the regions and codewords appeared to be close to what one gets in Watershed segmentation. That may have an application in compression. But right now I am concentrating on Neural Networks.
|
17th September 2005, 03:57 | #14 | Link |
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
I have posted the plugin NeuralNet and its documentation. This is classic 3 layer categorisation implementation.I have tested it with an edge detection task and could get very encouraging and satisfying results. However as commented by Neuron above its application for video image processing/editing is difficult to imagine.
I am now contemplating to expand the network to a regression type, provided I understand the literature on that aspect. I will appreciate very much any cooments, bugs or suggestions on this. |
18th November 2005, 10:08 | #17 | Link |
Registered User
Join Date: Jul 2003
Location: India
Posts: 890
|
A linear filter function NeuralNetLN is now added to NeuralNet plugin. This function can process images where a linear relation from input to output exists.
Center is input, on right is processed by VFan and a small part of it used for training and on left is processed by NeuralNetLN. The images at this scale appear identical but at full scale there were differences. Most noticeable was in the rectangle inside the inverted triangle to the right of the subjects head. Some faint details seen in VFan filtered image were not seen in NeuralNetLN processed image. I have also tested with GaussBlur (part of ColorIt plugin) with good result. The script used is Code:
f=imagereader("D:\TransPlugins\images\msintrf0.jpg",0,1,25,false).converttoyuy2() i=imagereader("D:\TransPlugins\images\fanmsint0.jpeg",0,1,25,false).converttoyuy2() ln=NeuralNetLN(f,i,tlx=250,trx=380,tty=0,tby=400,xpts=9,ypts=1,iter=400,wh=0.01) stackhorizontal(ln,f,i) reduceby2() I experimented trying to deblur by inputting blurred image and using original as training material. For small starting weights and grid size it appeared to work but in general not. There is no linear relation for the reverse and so may not work. Zarxrax has asked whether Neural Networks will be useful for noise filtering. Blur can be done but Blur directly is far more faster. Many noise reduction schemes are not entirely linear and so will be difficult. |
Thread Tools | Search this Thread |
Display Modes | |
|
|