Saturday, July 3, 2010

Neural Network

Artificial neural network are biologically inspired and consists of elements that more or less perform in manner that is analogous to the human brain .Some of the brains characteristics exhibited are that they learn from experience and generalize from examples and can extract important information from irrelevant data set.


The artificial neuron

The complexity of the human nervous system built up of neurons is quite staggering, with neurons receiving, processing and transmitting electrochemical signals .the artificial neuron is designed to duplicate this very complex task.
Each unit performs a relatively simple job: takes in values from external sources and use this to compute an output signal which is propagated to other neurons. In addition to processing, another task is the adjustment of the weights. Within Neural Network it is useful to distinguish three types of units: input units which receive data from outside the neural network, output units which send data out of the neural network, and hidden layers whose input and output signals remain within the neural network.

During training, weights can be updated either synchronously or asynchronously. With synchronous updating, all units update their activation simultaneously; with asynchronous updating, each unit has a (usually fixed) probability of updating its activation at a time t, and usually only one unit will be able to do this at a time. In some cases the latter model has some advantages.

The basic methodology behind is , a set of inputs applied (which may be output of some other neuron ) .this input is multiplied to a arbitrary weight and then all the weighted inputs are summed up and then checked to determine the activation level .For the input applied there is a fixed target response desired at the output. The error resulting from the output produced and the desired output is used to change the weights, and thus gradually the desired output is found with acceptable error .This process is called learning.
For the learning process to be accurate the data set for training should be large and should cover a significant part of operating conditions, with relatively less noise.

Disadvantages: - it requires large amount of data to train, and it takes much processing time to train large neural nets.


THE mathematical model of artificial neuron

When a functional model duplicating a biological neuron is created, there are three basic parts, first one being weights .And others being adder to sum up inputs and an activity function control. Generally the acceptable range of output is usually between 0 and 1 or -1 and 1.
Let there be p inputs X0 …… Xp
And weights for each input being W0 …… Wp
The weights are multiplied to input and then summed up: -
X0W0 + X1W1 + X2W2 +…….. + XpWp =net
If net is greater than the threshold value then the output is 1 else its 0.
The weight is analogous to the synaptic strength

Activation function: - the function used to get the threshold value is termed as the squashing function. Common non linear functions used are

• Sigmoid function :- out = 1(1+��−������)

• Hyperbolic tangent function :- out = tanh(net)


• Step function :- out = 1 if net >0
out = 0 if net =0 and undefined at net<0 • Signum function :- out = 1 if net >0
out = -1 if net <0 and undefined at net=0 Single layer and multi-layer artificial neural network

The simplest of neural network is the single layer neural network .but fail to solve some very simple problems (Exclusive –OR problem).larger and more complex networks (multi layer network) provide greater computational capabilities, provided the activation function is non linear.


Training of neural network

A neural network is trained so that application of a set of inputs produces the desired set of outputs .the training is done by sequentially applying the input vector and adjusting the network according to the output. The algorithms to train a network do ensure that the weights gradually converge so as to obtain a desired output. There are two types of training, supervised and unsupervised.

Supervised training: - in this type of training a set training pair is made comprising of the input and target vector .the output of the network is found and is compared to the target network and the difference is send back to the network to adjust the weights.

Unsupervised training: - this kind of training requires no target vector and no comparison of the output is made with the desired output. The training set only has the input vectors.

Reinforcement Learning: - This type of learning is a intermediate form of the above two types of learning. Here the learning machine does some action on the environment and gets a feedback response from the environment. The learning system grades its action acceptable or unacceptable based on the response received and accordingly adjust its parameters. Generally, parameter adjustment is continued until an equilibrium state occurs, following which there will be no more changes in its parameters. The self organizing neural learning may be categorized under this type of learning.


Perceptrons

They are single layer of artificial neural network and results in output of one or zero. it’s a single layer neural network whose weights and biases are trained with a target vector to obtain the desired output vector. The training used is called the perceptron learning .One of the greatest advantages is its ability to generalize from training data .They are mostly used in pattern clustering .Although it has some drawbacks ,being a single layer network it cannot simulate a simple exclusive –or gate.
The perceptron network consists of a single neuron connected to two or more inputs through a set of equal number of weights, with an additional bias input.
The neuron calculates its output using the following equation:
X * W + b > T
X * W + b < T Where X is the input vector fed into the network, W is the Weight vector and b is the bias. Perceptron learning:-

Perceptron learning is of the supervised type i.e. the error in output is used to change the weights .The input vectors are fed to the network one after the another. If the network's output is correct, no changes are made. Otherwise, the weights and biases are updated,Using the Perceptron learning rule.

When the complete input training vector are fed it is called an epoch. When such an epoch results without the occurrence of any error or acceptable error , the learning of perceptron is said to be done .After the learning is done ,if a input vector in supplied the perceptron will give the correct output and if a new input vector is presented (which wasn’t in the training data ) then the neural net will exhibit generalization ,resulting in output nearly same as the output for a nearly same training input .


The delta rule:-

The delta rule is a learning rule used for updating the weights of the artificial neurons in a single-layer perceptron.
The delta rule can be summarized as follows:-
For all i:
µ=[ T - A ] In case of µ=0 the output obtained is correct
Wn+1(i) = Wn(i) + [ T - A ] * X(i)

A learning rate co efficient is also sometimes used ( Ʊ )
Wn+1(i) = Wn(i) + Ʊ *[ T - A ] * X(i)

The default value of Ʊ is: - Ʊ = (��������− ������ ��)��

If bias are used they are modified by: - b = b + [ T - A ]
where T is the expected result , A is the actual output of the neuron,
W is the vector of weights, X is the input vector to the network, and b is the bias.
If a solution exists and a algorithm using this rule ,then it has been proven to converge on a solution in finite time .


Linear seperablity

Like the exclusive or gate , there are some other functions which cannot be resolved using a single neuron layer. Such functions are called linearly inseparable . When a single straight line completely separates two different cluster of points in a two-dimensional mapping they , they are said to be linearly separable. For a three input case the separation is done by a flat plane cutting through a 3 d space. In general, for n input case, they are linearly separable in n-dimensional space if they can be separated by an (n − 1)-dimensional hyper plane.


Limitations

Perceptron networks have several limitations. First, the linear seperablity limits the representational power of the perceptron .it can only classify only linearly separable sets of vectors. If a straight line or (n-1 dimensional ) plane can be drawn to separate the input vectors into their correct categories, the input vectors are linearly separable and the perceptron will find the solution. If the vectors are not linearly separable learning will never reach a point where all vectors are classified properly and will always produce error.
Secondly, output values of a perceptron can take on only one of two values (True or False).
The most famous example of the perceptron's inability to solve problems with linearly nonseparable vectors is the logical exclusive-or problem.
To overcome this limitation more number of layers are added. A multi layer network is formed by cascading number of single layer networks. these multi layer network perform a great deal more then single layer



Back propagation

Since the single layer network severely limit in what they could represent ,algorithms were needed to train multi layer networks. Backpropagation is a systematic way to train multilayer neural networks. the artificial neurons are organized in layers, and send their signals “forward”, and then the errors are propagated backwards.

Multilayer network :- The first set of neurons serve only as distribution points of input .the input signal is simply passed through the weights and each neuron in subsequent layer produces the output .The network receives inputs by neurons in the input layer, and the output of the network is given by the neurons on an output layer. There may be one or more intermediate hidden layers. The backpropagation algorithm uses supervised learning, which means that we provide the algorithm with examples of the inputs and outputs we want the network to compute, and then the error (difference between actual and expected results) is calculated. With this error the weights are readjusted .The idea of the backpropagation algorithm is to reduce this error, until the neural network learns the training data. The training begins with random weights, and the goal is to adjust them so that the error will be minimal.
The weights are changed according to :-
Wpq,k(i+1) = Wpq,k(i) + Ʊ *A(1-A)[T-A]* A
Where W is weight , T is target output , A is actual output and Ʊ is rate training coefficient.
Adjusting the weight of hidden layer:- Here the training is more complicated because the
hidden layers do not have any target value for comparison .The backpropagation algorithm
trains the hidden layers by propagating the output error through the network layer by layer
adjusting weights of each layer.

Before the start of the training all the weights are set to small random numbers to eliminate the possibility of network being over saturated by large value of weights. A drawback here is if the weights start at same values and the desired neural structure needs different values then this network will never learn .

All about Eclipse

Where is my project explorer window
If you have closed it then you can view it again through window->Show View->Project Explorer. There are many other view options also available here like console, javadoc, search etc.

Relative path in Eclipse
/src is not home folder for project in eclipse. Eclipse see the top level directory of a project as home directory so, if you want to use some input file in project put it in main project folder and then only you can use file name simply to access it in your code.If you want to put the input file in /src then specify /src/filename.

Amarok

As I keep on using Amarok it seems to me as best audio player. Some of it's feature are really amazing. You not need any additional software to keep on your last.fm profile. It is only windows where you need the last.fm player software, on mac also it is not required.Other cool feature is wikipedia browsing for artists

Monday, June 28, 2010

Encrypt Documents easily

You don't need all those password manager software and applications for text files encryption/protection. It is very easy in linux or in mac.
Put your rarely and tough passwords in a text file then encrypt it. Anyway it's bad idea not because of encryption but because you may open it while someone is around and he sees all your password. Encryption is DES which is considered good so don't worry about encrypted thing.
Now if you have a file named text.txt and you want to encrytpt it simply run following command in terminal.

openssl des3 -salt -in text.txt -out text_encrypted

This will ask you for a password two times last one is for confirmation. That's all your file is password protected. Now you can safely delete your text.txt.
For decrypting the command is

openssl des3 -d -in text_encrypted

oho! everything inside the encrypted file is decrypted and printed on terminal(std output). You can even specify the out file name but then you have to delete the file after you have read it in plain text. If you forget to delete or leave the terminal open while you have use it for displaying :( sad anyone can see it now. So, use this thing with caution.
For creating the file back( for putting things in a file and not on std output)
type this in terminal:
openssl des3 -d -in text_encrypted -out text.txt

Here is a simple bash script which will do all this with one command and is user friendly way.


#!/bin/bash
#for locking
echo "Enter file to encrypt"
read "in_file"
out_file=`basename "$in_file"`
out_file="$out_file.encrypt"
echo encrypted file will be: $out_file
openssl des3 -salt -in "$in_file" -out "$out_file"
echo "Do you want to delete original file y/n?"
read "resp"
true="y"
if [ "$resp" = "$true" ]; then
rm "$in_file"
fi



For unlocking:
#!/bin/bash
#for unlocking
echo "Enter file to decrypt"
read "in_file"
echo "Do you want to write the output on std out(y) or in file(n) enter y/n"
read "resp"
true="y"
if [ "$resp" != "$true" ]; then
out_file=`basename "$in_file"`
openssl des3 -d -in "$in_file" -out "$out_file.unecrypted"
echo "Remember to delete the unencrypted file afterward"
else
openssl des3 -d -in "$in_file"
fi

Friday, June 25, 2010

No need for simple calculator if you have bc

Also do some advance stuff like power. very simple to use. obvious commands.
run bc then give inputs on standard input you can even write your calculation in a file then give that file as input to bc command.

Some Commands for audio files

May be not so useful :)

who wants to play song from terminal? I guess no one but if you want to do it for some reason for some audio file in mac try this
afplay file.mp3
afplay for playing audio file

want information about audio file use
afinfo filename

for getting information bat an audio file

sample info result:
Nandan-Dubeys-MacBook:Watermark nandan$ afinfo 03\ On\ Your\ Shore.mp3
File: 03 On Your Shore.mp3
File type ID: MPG3
Data format: 2 ch, 44100 Hz, '.mp3' (0x00000000) 0 bits/channel, 0 bytes/packet, 1152 frames/packet, 0 bytes/frame
no channel layout.
estimated duration: 240.222 sec
audio bytes: 2237152
audio packets: 9196
bit rate: 74000 bits per second
packet size upper bound: 1052
maximum packet size: 731
audio data file offset: 15678
optimized
----

Friday, June 18, 2010

MacOS opening applications from terminal

Do you use terminal most of the time?
For opening applications form Terminal I have added /Applications/app/Contents/MacOS/ for all applicatons so for TextEdit I have /Applications/TextEdit.app/Contents/MacOS/ in my path. This has made my .bash_profile long. Then I got this command
open -a application_name
-a for application For using this command you don't need to add anything in PATH. application_name is not case sensitive so you can write
open -a teXeDiT or open -a textedit or open -a preview . So this make things easy.
To open files from any folder you can write
open file.txt or open path/file.pdf etc this will directly open a file with corresponding application but it will not create a new file so file must exists.
You can even use open http://www.blogger.com to open blogger in safari.
cool!!
So just remeber
open for opening file and open -a for opening applications

Monday, June 14, 2010

Enable php on mac

This one of the many great good things which I like in mac. Mac already comes with apache configured so you can just start building your own site. I use this to check the pages before uploading to server and also for sharing things blogging privately among wing mates locally.
By default php is not enabled when you configure apache to any computer so here is the way to make it work on mac.

Open file /private/etc/apache2/httpd.conf for edit for this you may use
sudo vi /private/etc/apache2/httpd.conf

Uncomment the line which read something like 
LoadModule php5_module libexec/apache2/libphp5.so
you can search this line on vi

Now restart your Web Sharing
Open System Preferences and go to Sharing
Stop and then restart Web Sharing
That’s it!

Saturday, June 5, 2010

Beamer themes

Beamer themes I generally use

\usetheme{Madrid} % good one!
\usetheme{Boadilla} % Pretty neat, soft color.
\usetheme{Warsaw} % This one is my favorite
\usetheme{Bergen} % This one has navigation on the left
\usecolortheme{seahorse} % Simple and clean template

Mac switch b/w options

I was too worried about this. I was really not able to understand the intention why they have made touchpad or mouse use compulsory. For almost one and half year I have touched my touchpad whenever I got option buttons(dialogue buttons) i.e. cancel, ok, save, quit,restart, sleep etc. Then suddenly I realize that I am wrong all the time there is option to switch the keyboard buttons in action for these petty but all the time used things also. I don't able to figure out why they have disabled this option by default that really is wrong.
So here is the way to enable keyboard tab button to switch between options in dialogue box.

Go to System Preferences -> Keyboard -> Keyboard Shortcuts and then check mark the option "All Controls" at the bottom.

Saturday, May 29, 2010

Algorithm for everyone

Computer Science department organize a course for general student each summer. Topic is decided by Instructors.
This summer we have decided to teach Algorithm, Advance C++ and web programming.

These are my initial thoughts about teaching Algorithms.

Algorithm is heart of cse and very important for everyday use.
for anybody who is going to do any kind of coding will require it.


basic algorithm design technique
basic data structure
ability to analyze algorithm
understanding complexity of a problem.

what do we want to make them learn after the course is over. what is exactly our goal and their take home. determining factor what’s important to them and what will be good course structure. one way out is teach them everything but that we can’t do so we have to compromise.
things which are really important are=>
We don’t want to anybody say that the students don’t even tell the order of a simple algorithm that will be ridicules so Big O is very important.
Second important thing will be covering data structure that is why they are here so they need to know more than just array and list which is common sense.
so we need to teach them tree and red black introduction don’t expect them to remember the rotation and insertion procedure. but basic constraints are good enough just give them a feel that binary tree is not what we use actually because it can be fooled so they will also get to know about some randomization involved.
After binary tree we can cover some smart data structure like heap

Pseudo code

Good tricky question which are puzzle types are best because they don’t need to do all computer science stuff and go deep in theory of everything.
that will be good but again we don’t have time.

implementation always tell you more than you read there are many things which u come across while u are really implementing things.

So must have one programming assignment language of your choice we can even combine projects if they are doing other course also to make it more useful and a good project and also weight age will be reduced.

again introduction to graph is important but it’s more for our well being because they are not going to learn any useful thing from it which they can apply.
but if we get time we can try to cover some graph stuff. i will suggest that we introduce it anytime between first 3 lecture and if we get time cover it in detail.
Algorithms

recursion
randomization

Searching/sorting algorithm is again important thing they need to know in list array tree etc.

then we need to introduce divide and conquer so sorting will transit into divide and conquer by merge sort.
then we need to cover or introduce greedy algorithm.

Dynamic programming


choose small simple and typical example don’t try to create your own which will take time to understand itself.
formulate clearly don’t fear from mathematics it’s only way to make things clear as hell
apply things step by step slowly why for each step why i really choose this step why not some other. how u will approach a new problem. so there is no magic.
motivation for learning is important see for geometry example they are daily life.


So Always start by a puzzle
e.g.
how to cover a chess board by dominoes?

First I have opted for teaching Algorithms. But we have only one guy who is willing to teach Advance C++ while we need at least 2 guys since I have done some Advance C++ stuff So I flipped to teaching C++.

Sunday, May 2, 2010

Mac: Listen Terminal say words

command: say
Funny use this command to check how terminal pronounce words. I make it useful by putting it last of any command or just type this command (e.g. say done) whenever I have a somewhat large process to run on terminal. when process ends the say command will announce that it has done executing all previous commands.

Chinese Room

Abstract:

Chinese Room Argument(CRA) (15) has continuously bothered logicians and Computer Scientist for almost 30 years now (12). The argument was given by prominent Philosopher John Searle in 1980. By CRA Searle has proved that Strong AI can't exist. He said that computers can only simulate things(which he called ``weak AI") and never be able to show actual intelligence i.e. learning. There has already been enormous amount of debate on CRA by many prominent Philosophers of mind and AI scientist. The general consensus among literature is that CRA is wrong but with little agreement upon exactly how and why it is wrong. (4) In this course project I attempt to give some new logical thought against the famous argument and try to prove it wrong.




Keywords: Chinese room argument, Weak AI, Strong AI, Turing test, Logic, Mind, Thought.


Introduction


CRA has stirred enormous amount of debate and controversy among AI scientists and engineers, philosophers of mind and cognitive scientists. Gomila describes the literature on the CRA are nearly infinite, and the editor at the time (Stevan Harnad) has since described it as BBs most influential target article.

Chinese room argument means to state that the purely formal or abstract or syntactical process of the implemented computer program could not by themselves be sufficient to guarantee the presence of mental content or semantic content of the sort that is essential to human cognition (14). According to Searle The Chinese room Argument rests on two fundamental logic truths
1. Syntax is not semantics: The implemented syntactical or formal program of a computer is not constitutive of nor otherwise sufficient to guarantee the presence of semantic content.
2. Simulation is not duplication: We can simulate the cognitive process of the human mind but it doesn't mean by any means that we have achieved the creation of mental process. As we can simulate rain storms, digestion, or anything else we can describe precisely. But it doesn't mean that the simulation of digestion on a computer could thereby actually digest pizza. So it is ridiculous to think that a system that had a simulation of consciousness and other mental process thereby had a mental process

Plan of the paper: First I will introduce The Chinese Room Argument and other background materials. Then I will give other people work on trying to disprove CRA and reply by Searle on each counter argument. Then I will introduce my own idea under ``Fallacy of CRA" section which is based on logical argument. After that there is a section of Discussion on CRA which is informal. Finally conclusion of whole idea is made. References and Acknowledgments are given in last.
Turing Test: Consider two closed room and a judge who doesn't know what is inside the rooms. Now put a computer in one room and a person in other room. If judge start chatting with both person and computer (running natural language processing program) and is not able to distinguish clearly which one is computer and which is real person then the computer program is said to pass Turing Test. The idea behind the test is simple since we don't know exactly how mind/brain works how people think so this is an easy way out to show that a human made machine running some human made program is able to talk same like us. There may be problem with voice recognition so only text chatting is allowed because we are just checking for thought and not all human capabilities.
Strong AI: If a machine passes Turing test then we say that it has intelligence and is able to think(has mind).
Weak AI: According to Searle Computers can only simulate things. So, it can simulate thinking which can be used to fool people but it can never do actual thinking.
Chinese Room Experiment: The argument was really strong in the sense that even if we don't know how brain works, what do we mean by intelligence, what is thinking or even how children learn language, it tries to disprove existence of Strong AI. The argument is simple and based on just symbol manipulation (7). For visualizing the experiment consider a native English person who doesn't know Chinese at all he can't even tell whether given symbol is Chinese or not. He can make sense of Chinese symbols only based on their shape/sketch. But he has good knowledge of English and can read, write, understand it efficiently. Call this person P. Now consider a closed room full of Chinese database with English instruction to match them with other set of Chinese symbols. The room has two slots at two ends. Assume this person P is inside the room and questionnaire in Chinese are passed to him (call this Questionnaire input of the program) along with some instructions in English(call these instructions the computer program). Now the person P inside the room matches the symbols on the questionnaire with the help of English instruction to the Chinese database and write the corresponding Chinese symbols in other paper (call it the output)and pass it to other slot. Now Chinese persons who are passing the questionnaire (input) receive this output and thinks that the person inside the room is good at Chinese because he is able to answer their all query in Chinese. So the room is able to pass Turing test and still the person inside the room who is doing all manipulation doesn't know single world of Chinese.
Chinese Room and Functionalism: Function is defined by what something or somebody does e.g. a calculator operates on numbers given as input, our digestive system digest food.
Desire, belief can also be defined as functional form e.g. ``I am hungry" or I desire food. So here if I get food(input) i will be contend(output) no longer hungry or desire food.
Functionalism defined as inputs and outputs continued. Comparing two things with functionalism.
If both acts similar then they are same.
If on same input both give same result then they are same.
For mind also we can say the same. So if computer can act like mind that is it can think, thought, talk, decides. In similar situation gives similar results. Just like person takes part in linguistic exchange then we say that computer is as intelligent as a person. It has a mind.
Right now there are multiple chat bot on internet which tries to talk like human. e.g A.L.I.C.E. (1), Ella (2),Jabberwock, Carpenter George, Elbot (13).
In 1991 Dr. Hugh Loebner started the annual Loebner Prize competition, to the author of the computer program that performs the best on a Turing Test. (8)
Searle's Chinese Room passes the Turing Test. So acts like an intelligent person with brain/mind. But in actual Searle has only conducted symbol manipulation, with no understanding, yet he passes the Turing Test in Chinese. So, Searle claims that passing the Turing Test does not ensure understanding. In other words, although Searle's Chinese Room functions like a mind, he knows (and we in an analogous foreign-language room experiment would know) it is not a mind, and therefore functionalism is wrong.




Past Works


There have already been many attempt by many Computer Scientist and Philosopher to counter CRA but they all are not able to convince Searle about the fallacy of Chinese room. I am listing some famous counter examples and also Searle argument against them here:



The Systems Reply The systems reply says that the person inside the room may not be able to learn Chinese but he is just part of the closed room and since the room as a whole is interacting as a unit with outside world so the room as whole must be seen as the subject of argument and not the person alone. The systems reply claims that the room as a whole know Chinese. Searle has disprove this argument saying that consider a person which remembers everything inside the room in his head so assume that he has very good memory and he remember each page of Chinese database even if it doesn't make any sense to him he also remember all English instruction. Now remove the room from the picture and consider this person as subject he is still able to write answer of Questionnaire as it was done previously by doing all lookup searching inside his head. But still he doesn't know Chinese. So, the system also doesn't understand Chinese since there is nothing in system which is not in him.



The Robot Reply: In place of Chinese room consider a robot with sensors, motors etc just like human being. Then it can act and show intelligence as human being. So people with this argument think that Searle makes an error in the CRA by viewing strong AI as question-answering and symbol manipulation only. So disembodied room is not availing wide spectrum of other resources that we human get which is responsible for cognition and is link between world. (10) In reply to this Searle believes that the addition of sensors and all changes nothing. The program inside the robot continues to do same symbol manipulation and hence understand no Chinese. There is good discussion about this in an unpublished report by

Cutrona, Jr., Dr. Louis J. (2005) (3) So if we use a Zombie1 in Chinese room which is exactly similar to its counterpart in all respect but thinking. Still it will not learn Chinese.



The Virtual Mind Reply: (11) This states that a running system like Chinese room create an entity which is different from the person inside the room or the room itself. So the virtual entity is different from physical entity. This virtual entity will understand Chinese in case of Chinese room. So it states that the claim that the person inside Chinese room doesn't understand Chinese has nothing to do with strong AI existence.



The Brain Simulator Reply: (5)

It says that consider a computer which is quite different from the computer we see/encounter or we are able to create our new computer will be very similar to brain and does same procedure as our brain does so it will also works upon the idea of neuron firing. Now this computer will do exactly the same firing sequence as a native Chinese speaking person does when he understand some verse of Chinese. Now this computer which is similar in brain expect will understand Chinese as a native Chinese does. For this argument Searle reply is simple that simulation is not doing things in real. So if we replace the Chinese room with all that computer stuff with pipes, valves and tubes and the person inside the room acts as a prosecutor for all the commands which results in brain simulation. Not in this situation also tha person will not understand Chinese while he is able to simulate the brain.

Chinese room a logical Approach:


Let us try to represent our argument with logic by symbols. Let us call T is a theory, E as thought experiment and S is some setting which everyone knows that it is not correct. In terms of propositional logic we can say the following which is simply modus tollens :


(T E ) S
S
E


E T


In the Chinese room argument, we can say that T is strong AI is a theory proposed by Turing and E is the CRA the experiment which Searle proposed. The premise is that T and E together imply S by above propositional logic, namely that Searle understands Chinese.
So if strong AI is correct and also assuming that Chinese room argument is sound/valid then it follows that Searle understand Chinese. But, as everyone knows that Searle does not understand Chinese, or at least he(Searle) claims that he doesn't understand Chinese at all even after successful completion of the experiment.

S . Hence, T and strong AI is false. Some Modal operations are discussed in footnote 2 According to Sorensen (1992, Chapter 6) there are two typical structures for the class of thought experiment that he calls ``alethic refuters". By `refuters', he is focusing on destructive thought experiments that contradicts(or refutes) some theory. By alethic he refers to the modalities necessary and possible as in S5. The two kinds of structure are necessity `refuters' and possibility `refuters'. The necessity `refuter' structure is (Sorensen, 1992, pp. 135-6):


1. S : Modal source statement


2. S I: Modal extractor


3. ( I C ) W : Counterfactual 3


4. W : Absurdity


5. C : Content possibility


Our representation is different than Sorensen in our case symbols have different meaning.

According to Sorensen the subjunctive conditional is necessarily counter-factual, There are lot of materials on this statements and many not agree on the counter-factual. But this discussion will take us away from our original goal of disproving CRA and so we will not discuss about Sorensen arguments.

Sorensen asserts it to be obvious that Statements 1 to 5 are mutually contradictory.




The CRA as a necessity refuter :



REMOVED REMAINING(Important part) :) PART OF THE ARTICLE



Conclusion

In this article I have tried to attack Searle's long standing Chinese room argument in a new approach. There is already common belief shared by many logician that CRA is not correct. There are many proves against it. The major problem I faced during writing this article is there is no clear cut logical definition or description of either Turing test given by Alan Turing or the Chinese room Argument given by Searle. I have to use Sorensen idea of destructive thought experiment to devise my proof. Although I can also present my ideas without using Sorensen proof but that again will not be logic and I don't wish to enter in mind/brain argument. I am not qualified enough to do so. My idea is simple and clear. It is based on Turing test. My disagreement with Searle idea of Chinese room is on the point where Searle claims that his Chinese room is able to pass the turing test. I will say that ************************ so further claims and result that strong AI is false is absurd and doesn't make sense.



Discussion

If we assume mind as a hardware then there is also some kind of program running in mind which does all the stuff. Since hardware is never assumed a limit in proving thought. there are theories which assumes that mind is also hardware.

As we are seeing the progress of medical science we can see that now it is possible to replace artificial limbs like pacemaker, cornea etc. If the progress continue with same rate the day is not far when we are able to do gene replacement to elongate our life span. Only few genes need to be replaced to extend our life span by twice or thrice because as we see that only few gene difference between chimps and human is able to make such difference in everything and also in life span which is less than 30 years for chimps. There is also another possibility of limb replacement as our limbs grow old. Since we are not able to understand cause of natural death so we can't say with confidence that whether weary limb replacement be able to elongate our life. Replacement of mind seems to be tough since we need to copy memory also otherwise entity will not remain the same. So, if we are able to do replacement then there will be no difference between machine and human and so between Human AI and machine's AI.

There is one more argument called Chinese Gym (6) it states that brain function can't be simulated by chinese room or computer. For computer to just come near brain it must have lot of processors working parallel. So mind is like Chinese Gym where each person is doing some stuff brain has millions of neurons each does signal processing/manipulation of it's own and pass it to other.





Bibliography

1
Artificial linguistic internet computer entity (a.l.i.c.e.) http://alicebot.org/about.html.
2
Kevin Copple.
Ella.
2002.
3
Dr. Louis J. Cutrona, Jr.
Zombies in searle's chinese room: Putting the turing test to bed.
2005.
4
I. Robert Damper.
The logic of searle's chinese room argument.
Minds and Machines, 16:163-183, May 2006.
5
Eliana Colunga Francisco Calvo.
The statistical brain: Reply to marcusÕ the algebraic mind.
6
Eamon Fulcher.
Cognitive Psychology.
7
S. Harnad.
The symbol grounding problem.
Physica D, 42:335-346, 1990.
8
http://en.wikipedia.org/wiki/Loebnerprize.
Loebner prize.
9
http://plato.stanford.edu/entries/logic modal/.
The stanford encyclopedia of philosophy.
10
J. Christopher Maloney.
The right stuff.
Synthese, 70, Number 3:349-372, March 1987.
11
Ayse Pinar Saygin, Ilyas Cicekli, and Varol Akman.
Turing test: 50 years later.
Minds Mach., 10(4):463-518, 2000.
12
John Preston and Mark Bishop.
Views Into The Chinese Room.
Oxford University Press, University of Reading, 2002.
13
Fred Roberts.
Elbot : http://www.elbot.com/.
2008.
14
John R. Searle.
Twenty-one years in the chinese room.
15
John R. Searle.
Minds, brains, and programs.
The Behavioral and Brain Sciences, 3:417-457, 1980.


Saturday, April 17, 2010

Vi

@Case Insensitive Search: There it is, I've often wanted to search words with cse off in "/" search.
If \c appears anywhere in a pattern the whole pattern is assumed to be case insensitive(ignore case). It overrides usual settings like smartcase or ignore case e.g.
/\cname or /name\c
or best option is work with smart case option on :set scs
'smartcase' can be set to ignore case when the pattern contains lowercase
letters only.

Take a look at :help ignorecase in vim for more info.
I use the ignorecase and smartcase settings as default, and they work great for me. Any search with an uppercase character becomes a case sensitive search.

:set ic
If the 'ignorecase' option is on, the case of normal letters is ignored.

*/\c* */\C*

Thursday, April 15, 2010

lsof

Today's command lsof ========================== next command nl

LiSt Open Files.
Using Options
-c
Show us what files are opened by processes whose names starts by ____(bash,iTunes,S, . . . )
     lsof -c S
     lsof -c bash
     lsof -c iTunes
-t
list only Process Id's (PID) so ls -t list all unique process id running on system which is using some file.
+p
Show us what files are using the process whose PID is 318:
     lsof +p 318

+D
Search for all opened instances of directory ~/Project and all the files and directories it contains:
     lsof +D ~/Project

-i
Show all connections
lsof -i

Show only TCP connections
lsof -iTCP


Show only UDP connections
lsof -iUDP

-i :port shows all networking related to a given port
lsof -i :22

lsof -i| grep LISTEN
lsof -i| grep ESTABLISHED
Grepping for "ESTABLISHED" or "LISTEN" listening connections

Use -a option to combine search terms.
lsof -a -u nandan -i
"show me everything running for user nandan and using some kind of connection"

Use it to kill processes
kill -9 `lsof -a -u nandan -c VLC -t`

Monday, March 22, 2010

'init' comes first

init the most essential program for UNIX systems. Started as first process generally with PID 1, when system boots up. Nothing to worry about it because it is already configured to work in any system.init starts other processes directly or indirectly.
e.g. init starts a separate instance of getty(responsible for logins) when asked.
getty reads the username and runs the login program, which reads the password if every thing is fine then it runs the shell.


'init' dies last
When the system is shut down, it is init that is in charge of killing all other processes, unmounting all
filesystems and stopping the processor.

Saturday, March 20, 2010

Weka on NetBeans

Here is a very easy way out extract jar sorce file of weka you will probably get weka-src folder.
Now create a new java application project in NetBeans name is your choice. Let us say you have created a project named javaapplication then do following =>
just put folder weka-src/src/main/java/weka in src folder of your newly created project folder also put weka-src/lib inside the newly created project src folder.
So, your src folder in javaapplication folder contains lib folder from weka, weka from weka and javaapplication it already have this one. That's all start coding and using weka.
Now in javaapplication project you can add as many file as you wish and call weka classes by importing the class files you want to call. You can't call classifier directly because they are protected for classifiers use only. So you can't call directly Classifier.runClassifier(new REPTree(), argv) etc.
If you want something like this then just change the runClassifier from protected to public.
So it will be
changed from protected static void runClassifier(Classifier classifier, String[] options) {
to
public static void runClassifier(Classifier classifier, String[] options) {
Now you can just use following program to run REPTree with arguments.


package javaapplication;
import weka.classifiers.trees.REPTree;
import weka.classifiers.Classifier;

/**
*
* @author nandan
*/
public class Main {

/**
* @param args the command line arguments
*/
public static void main(String[] argv) {
// TODO code application logic here
Classifier.runClassifier(new REPTree(), argv);
}
}

make any class like this in javaapplication project put argument from run menu using customize main project specify something like -t trainingfile.arff.
trainingfile.arff should be inside javaapplication folder.

This also tells you how to pass command line argument to NetBeans main project. To change main project go to run menu then search for Set main project.

This is simplest solution. You can also add Weka as library the jar folder itself can be added as library.

Sunday, January 31, 2010

Many good links at one place

http://www.math.tifr.res.in/~pablo/download/comp-links.html
link

not every good link for computers but it has some worthy links compiled at one place.
It always remains at first place in my bookmark bar.

Tuesday, January 19, 2010

A good link

Tanya Khovanova
http://www.numbergossip.com/

this will tell you everything about a number. just enter a number not greater than 9999 and result will be all mathematical property and general gossip about that number.

Stupid Jokes

Collected from Internet

=========================================================================
Infosys , Bangalore : An employee applied for leave as follows:

"Since I have to go to my village to sell my land along with my wife ,
please sanction me one-week leave."

=========================================================================

From H.A.L. Administration Dept:

"As my mother-in-law has expired and I am only one responsible for it ,
please grant me 10 days leave."

=========================================================================

Another employee applied for half day leave as follows:

"Since I've to go to the cremation ground at 10 o-clock and I may not
return, please grant me half day casual leave"

=========================================================================

Covering note:

"I am enclosed herewith..."

=========================================================================

An incident of a leave letter:

"I am suffering from fever , please declare one-day holiday."

=========================================================================

A leave letter to the headmaster:

"As I am studying in this school I am suffering from headache. I request you
to leave me today"

=========================================================================

Another leave letter written to the headmaster:

"As my headache is paining , please grant me leave for the day."

=========================================================================

Another one:

"Dear Sir: with reference to the above , please refer to my below..."

=========================================================================

Oracle, Bangalore: From an employee who was performing the "mundan"
ceremony of his 10 year old son:

"as I want to shave my son's head , please leave me for two days.."

=========================================================================

CDAC: Leave letter from an employee who was performing his daughter's
wedding:

"as I am marrying my daughter , please grant a week's leave.."

=========================================================================

A candidate's job application:

"This has reference to your advertisement calling for a ' Typist and an
Accountant - Male or Female'... As I am both(!! )for the past several years
and I can handle both with good experience , I am applying for the post."

=========================================================================

A not so good game due to story(Prince of Persia 4)

Some time it really get on my nerves. Decided some time to delete the game in between. but have reached to very near to final. some time it seems that they have make the game to take more time of player. you can't end it quick. become boring in last and when it ends doesn't make any sense i was playing for story which comes out to be very bad really depressed after playing why why i have started this game.

Prince is very big fool. he talks any thing doesn't make sense at all. need to put more on story and talks . repeats much. it's better to be quiet than to repeat same thing get on nerve. i remember a conversation in which princess tell prince that how many times do you have said that line :) . what the hell can't they have a good story. the story they have is very small. in so big game. then some of the time the path to run/teleport is so tough that need to practice 5 to 10 times before comes to end.

Story:
started with prince inside desert searching for his donkey: how he come in desert why he is with donkey. he is like a donkey that for sure :) . so while searching you will met a girl she doesn't tell her name initially when you ask she simply runs away. whenever there has to be some story control is removed from you and then you have no command apart from escaping to menu. you can't control upon how much they talk. so some time they talk and talk which comes to nothing. Ok so you began to follow her. then you fight with her father. her part of story become clear. as you go to the temple guided by her. you will know what your goal is in game. there is this Ahrmas and Ozmad god of darkness and light . Ozmad has captured Ahrmas and put him in jail in tree. and there are guards called (Ahura) they guard the tree as time passes the guard's power lessens and then the father of Elka made Ahramas. father of Elka assumes Ahrmas authority. and set him loose but still he is not able to go outside the temple because of some remaining power of ahura so your aim is to reestablish Ahura power by fertilizing the grounds. there are lot of grounds to make fertile after you fertile a ground light seeds are generated which are scattered on path and you collect them to get next power power is nothing but opening gate of whole set of new corrupted ground. so you keep on doing this running like hell. with elka.
There are some major fights as I have said they are made so that you have to fight for long and also some guys keep meeting you and fly away when there health is lessened.

A Joke




FAQ on the Apache Server project's website, from 1996 to 2001, claimed that "The result after combining [the NCSA httpd patches] was a patchy server. So the name "APACHE" :).

Mac Tweak

Use terminal to write commands

1. Show hidden files

defaults write com.apple.finder AppleShowAllFiles true

Replace 'true' with 'false' to put things back to normal.

2. A very useful tip if you use lot of screen grabbing.
Change your screen grab format

defaults write com.apple.screencapture type jpg

Alternate formats are 'tiff' and 'pdf' or the default, 'png'. Logout and back in for changes to take effect.

Change your screen capture location

defaults write com.apple.screencapture location [path]

3. For Linux fan
Open Applications from terminal(command)

`open `

e.g.

open /Applications/Preview.app

or

open Desktop/image.jpg

If you use the "-a" option to the 'open' command, then you don't need to give a path - the system will find the application wherever it is.
E.g.:

open -a Preview
open -a Safari

Mac Benifits

You do not need to switch application in many case you have some control over application even working on different one. so you can change page (browse) on preview while working on terminal continuously. or use safari,
you can even do right click on some application(not on finder) while working on some other.
more specifically you can use all functionality of mouse by just taking it over any opened application without switching to it.

Mac Applications

Some very use full applications of mac must need
Adium: best im client ever build is for mac it is better than pidgin.
it support multiple im's. Also there are lot of ready made scripts for multiple jobs (mostly for quotes from movie or celebrity).
Adobe acrobat reader: you have preview but still you will need it some time because preview has it's own limitation . It make the portable document format not so portable. So when you open a document which is made from windows using words/power point you will not able to see exactly same as it is with preview.
Some fonts figures will not be displayed. It has really got on my nerves then i found that preview is best but i don't know why they have done this to preview. Why a portable claimed document is not portable why i need adobe reader while i have best reader preview which is so light weight so fast so easy to handle.
Gimp or adobe photoshop:even if you are not photo fan you will need it sometime.
Alarm clock.
app cleaner: i don't know why mac has so bad way of deleting files . when you delete some application many of its preferences saved profile still remains in multiple location like library etc. You have to search and remove them manually. it is good if you are removing something temporary and you will need it after some time then you wish that your history will remain but this kind of delete is very rare generally we want complete remove of program from computer so mac will not be able to do this so u will need some application App cleaner is best.

Aquaemacs: for emacs guys and for oz compilation.
BBedit best editor. as helper to textedit.
better in some ways than textedit. support many text file formats.

Colloqy: irc client
cover sutra:
desktop lyrics:

No good video player in mac. vlc also not provide all it's functionality as in windows(e.g. Subtitle synchronizing). This is worst thing. i miss Kmplayer i really don't have one good player in mac.

vlc media player:
mplayer:
djoplayer:not required
djvu: djvu file reader

Fluke.app: for listening un compressed .flac format music files

Gimmesometune: Automatically fetches lyrics and artwork for itunes.

ilovestar: If you wish to rate songs and see there rating from apple menu bar
ichm: .chm reader.
iscobller: last.fm scrobbler. Scrobbler from last.fm is unstable in mac. iscrobbler provides more facility like local user charts and history.
justlookin: light weight image viewer.
iwork/microsoft office
macfreepop's
name mangler:
opera: best browser. i got frustrated from safari . it is light weight loads fasts but still some pages some redirects don't work you really can't bear this.
picasa:
shakespear: OK DC++ substitute
skype:
Xtorrent: Best torrent client. Provide search and feed inside the client.
transmission: Good torrent client
tofu:
tweetdeck:
Adobe Lightroom:
Autorate:
Butler:
Bento:
Bookepedia:
FileZilla: Best Ftp client for mac. easy and friendly to use, light weight.
Dropbox:
Name Mangler:
Opera:
Stickies:
Unison: For newsgroup