DOC PREVIEW
Unix

This preview shows page 1 out of 4 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 4 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 4 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

IntroductionIf you are using the Unix, command line version of tlearn, you willneed to make several adjustments to the exercises and explanationsgiven in the text (which assumes a Macintosh version). The referencemanual for the line-oriented version is included here, and we giveseveral examples which illustrate the differences in how the simulatoris invoked. There is also one important difference in file formats (the.teach file); other files and options are identical across platforms,however.Configuration FilesThe four input files which are described in Appendix A are also usedin the Unix, command line version of tlearn. With one exception,these files are identical. (Rather than preparing these files within thesimulator itself, using tlearn’s built-in editor, you would preparethese with a Unix text editor sch as vi or emacs.)The one input file which differs from the Mac version is theteach file. In the Macintosh version of tlearn, this file begins with-the word “localist” or “distributed”, followed by a line with the num-ber of target patterns, followed by successive lines, each of which hasthe target pattern for the corresponding input pattern found in thedata file. In the Unix version, the first two lines are the same as inthe Mac version, but the actual patterns must be preceded (on theAppendix B [Unix]188 same line) by a number which tags that specific target pattern. Pat-terns are numbered incrementally starting with pattern 0 (zero). Thefollowing illustrates the differences between for the XOR problem.Note that in the Unix version, each line now has two numbers; thefirst is the number of the pattern and what follows is the actual target.Invoking the simulatorTo invoke tlearn on Unix, you give it as a shell command, fol-lowed by a list of the options and file names as required (these aredocumented in the attached Unix on-line manual page). For example, to run a training session on the XOR problem, wemight do the following (assuming % is your shell prompt, and youhave used xor as the fileroot for your files).% tlearn -f xor -s 5000 -R -r 0.3 -m 0.9 -E 100 (If you wish to run this command asynchronously, in the background,add an ampersand (&) to the end of the command-line.)This command will run the simulator for 5000 training patterns,chosen at random, with a learning rate of 0.3 and momentum of 0.9,and will save the error every 100 patterns in a file called xor.err. Itwill also generate a weights file called xor.5000.wts, which canteach files for the XOR problemMac versionUnix Versiondistributed distributed44000010121131Appendix B [Unix] 189then be loaded in to tlearn on subsequent invokations either inorder to test learning, or to continue with additional learning sweeps.% tlearn -f xor -l xor.5000.wts -s 4 -Vfor testing (“verifying”; notice that there is no -R flag, so the 4 pat-terns will be presented in the order in which they occur in the dataand teach files) or% tlearn -f xor -l xor.5000.wts -s 1000 -r 0.3 -m 0.9 -Rto continue training for an additional 1000 sweeps. This would yieldan additional weights file called xor.6000.wts.Additional filesIn the exercises as described in this handbook, it is assumed that youhave access to various data files for many of the exercises. In the Macversion, these are located in folders which come with the simulator. Inthe Unix version, they have been placed in directories namedChapter1, Chapter2, etc., within the following directory:~elman/cogs201f/exercises/on various machines (the tilde denotes the path to user elman’s homedirectory; the actual location of this directory varies from machine tmachine, so the tilde will find the correct location on any machine onwhich elman has an


Unix

Download Unix
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Unix and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Unix 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?