[Bio] / FigTutorial / SEED_administration_issues.html Repository:
ViewVC logotype

Annotation of /FigTutorial/SEED_administration_issues.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.12 - (view) (download) (as text)

1 : olson 1.2 <h1>SEED Administration</h1>
2 : gdpusch 1.8
3 :     <p>
4 :     This tutorial discusses a number of issues that you will need to know about
5 :     in order to install, share, and maintain your SEED installation.
6 :     It is organized as follows:
7 :     </p>
8 :    
9 :     <ul>
10 :     <li><A HREF="#backups">
11 :     Backing Up Your Data
12 :     </A>
13 :    
14 :     <li><A HREF="#copying">
15 :     Copying a Version of the SEED
16 :     </A>
17 :    
18 :     <li><A HREF="#multiple_copies">
19 :     Running Multiple Copies of the SEED
20 :     </A>
21 :    
22 :     <li><A HREF="#adding_genomes">
23 :     Adding a New Genome to an Existing SEED
24 :     </A>
25 :    
26 :     <li><A HREF="#sims">
27 :     Computing Similarities
28 :     </A>
29 :    
30 :     <li><A HREF="#deleting_genomes">
31 :     Deleting Genomes from a Version of the SEED
32 :     </A>
33 :    
34 :     <li><A HREF="#reintegrate_sims">
35 :     Periodic Reintegration of Similarities
36 :     </A>
37 :    
38 :     <li><A HREF="#pins_and_clusters">
39 :     Computing "Pins" and "Clusters"
40 :     </A>
41 :    
42 :     </ul>
43 :    
44 :    
45 :     <h2 id="backups">Backing Up Your Data</h2>
46 : olson 1.1 The data and code stored within the SEED are organized as follows:
47 :     <pre>
48 :     ~fig on a Mac: /Users/fig; on Linux: /home/fig
49 :     FIGdisk
50 :     dist source code
51 :     FIG
52 :     Tmp temporary files
53 :     Data data in readable form
54 :     </pre>
55 : olson 1.2 <ol><li>
56 : olson 1.1 The directory <b>FIGdisk</b> holds both the code and data for the
57 :     SEED. The data is loaded into a database system that stores the data
58 :     in a location external to FIGdisk, but otherwise a running SEED is
59 :     encapsulated within FIGdisk. A symbolic link to FIGdisk is maintained
60 :     in the directory ~fig.
61 :     <br>
62 :     <li>
63 :     Within FIGdisk there are a two key directories:
64 :     <br>
65 :     <br><ol><li>
66 :     <b>dist</b> contains the source code, and
67 :    
68 :     <li>
69 :     <b>FIG</b> contains the execution environment and Data.
70 :     </ol>
71 :     <br>
72 :     <li>
73 :     Within FIG, there are a number of directories. The most important are
74 :     <br>
75 :     <br>
76 :     <ol>
77 :     <li>
78 :     <b>Data</b>, which contains all of the data in a human-readable form,
79 :     and
80 :     <br>
81 :     <br>
82 :     <li>
83 :     <b>Tmp</b>, which contains the temporary files built by SEED in
84 :     response to commands.
85 :     </ol>
86 :     </ol>
87 :     <br>
88 :     Hence, to backup your data, you should simply copy the Data
89 :     directory. It should be backed up to a separate disk. Suppose that
90 :     /Volumes/Backup is a backup disk. Then,
91 :     <br>
92 :     <pre>
93 : overbeek 1.12 cp -pRP ~/FIGdisk/FIG/Data /Volumes/Backup/Data.Backup
94 : olson 1.1 gzip -r /Volumes/Backup/Data.Backup
95 :     </pre>
96 :     <br>
97 :     would be a reasonable way to make a backup. The copy preserves
98 :     permissions, copies recursively, and does not follow symbolic links.
99 :     <br>
100 : gdpusch 1.8 <h2 id="copying">Copying a Version of the SEED</h2>
101 : olson 1.1
102 :     To make a second copy of the SEED (either for a friend or for yourself), you should use tar
103 :     to preserve a few symbolic links (which are relative, not absolute; this means that they can
104 :     be copied while still preserving the integrity of the whole system).
105 :     So, suppose that you have a FIGdisk in /Volumes/From/FIGdisk.Jan8 and you wish to copy it
106 :     to /Volumes/To. Use
107 :     <pre>
108 :     cd /Volumes/From
109 :     tar cf - FIGdisk.Jan8 | (cd /Volumes/To; tar xf -)
110 :     </pre>
111 :     <p>This should produce the desired copy. In this case, suppose that we are in a
112 :     Mac OS X
113 :     environment, and <b>From</b> and <b>To</b> are firewire disks. To install the system on a friends
114 :     Mac, you would unmount <b>To</b>, plug it into the new machine, and then set the symbolic link to the active
115 :     FIGdisk using
116 :     <br>
117 :     </p>
118 :     <table border="1" bgcolor="#CCCCCC">
119 :     <tr>
120 :     <td width="403"><font face="Courier New, Courier, mono">cd ~fig</font></td>
121 :     <td width="285">&nbsp;</td>
122 :     </tr>
123 :     <tr>
124 :     <td><font face="Courier New, Courier, mono">rm FIGdisk</font></td>
125 :     <td># fails if there is no existing FIGdisk on the machine</td>
126 :     </tr>
127 :     <tr>
128 :     <td><font face="Courier New, Courier, mono">ln -s /Volumes/To/FIGdisk.Jan8 FIGdisk</font></td>
129 :     <td>&nbsp;</td>
130 :     </tr>
131 :     <tr>
132 : olson 1.2 <td><font face="Courier New, Courier, mono">bash</font></td>
133 :     <td>Switch to using the bash shell</td>
134 :     </tr>
135 :     <tr>
136 : olson 1.1 <td><font face="Courier New, Courier, mono">cd FIGdisk</font></td>
137 :     <td>&nbsp;</td>
138 :     </tr>
139 :     <tr>
140 : olson 1.2 <td height="23"><font face="Courier New, Courier, mono">cp CURRENT_RELEASE DEFAULT_RELEASE</font></td>
141 : olson 1.1 <td># Causes the new configuration to use the code that was running in the
142 :     original installation</td>
143 :     </tr>
144 : olson 1.2 <tr>
145 :     <td height="23"><font face="Courier New, Courier, mono">./configure <em>arch-name</em></font></td>
146 :     <td># Configure the new SEED disk for architecture <em>arch-name</em>. </td>
147 :     </tr>
148 :     <tr>
149 :     <td height="23"><font face="Courier New, Courier, mono"> source config/fig-user-env.sh <br>
150 :     </font></td>
151 :     <td># Set up the environment for using the SEED</td>
152 :     </tr>
153 :     <tr>
154 :     <td height="23"><font face="Courier New, Courier, mono">start-servers <br>
155 :     </font></td>
156 :     <td># Start the database server and registration servers</td>
157 :     </tr>
158 :     <tr>
159 :     <td height="23"><font face="Courier New, Courier, mono">init_FIG <br>
160 :     </font></td>
161 :     <td># Initialize a new relational database</td>
162 :     </tr>
163 :     <tr>
164 :     <td height="23"><font face="Courier New, Courier, mono">fig load_all</font></td>
165 :     <td># Load the database from the SEED data files. This may take several hours</td>
166 :     </tr>
167 :     </table>
168 :     <p>At this point, the new SEED copy should be ready to use. You only need to
169 :     perform the configure, init_FIG, and fig load_all steps once after installing
170 :     a new copy of the SEED. After a reboot or other clean start of the computer,
171 :     you will only have to do these steps:</p>
172 : olson 1.3 <table border="1" bgcolor="#EEEEEE">
173 : olson 1.2 <tr>
174 :     <td width="403"><font face="Courier New, Courier, mono">cd ~fig/FIGdisk</font></td>
175 :     <td width="285">&nbsp;</td>
176 :     </tr>
177 :     <tr>
178 :     <td><font face="Courier New, Courier, mono">bash</font></td>
179 :     <td>Switch to using the bash shell</td>
180 :     </tr>
181 :     <tr>
182 :     <td height="23"><font face="Courier New, Courier, mono"> source config/fig-user-env.sh <br>
183 :     </font></td>
184 :     <td># Set up the environment for using the SEED</td>
185 :     </tr>
186 :     <tr>
187 :     <td height="23"><font face="Courier New, Courier, mono">start-servers <br>
188 :     </font></td>
189 :     <td># Start the database server and registration servers</td>
190 :     </tr>
191 : olson 1.1 </table>
192 : olson 1.2 <p>Upon setting up a new computer for running SEED, you should read the full
193 :     documentation for SEED installation, as it has a number of platform-specific
194 :     modifications that need to be performed. This document can currently be found
195 :     at the following
196 :     location in the SEED Wiki: </p>
197 : olson 1.1 <blockquote>
198 :     <p><a href="http://www-unix.mcs.anl.gov/SEEDWiki/moin.cgi/SeedInstallationInstructions"> http://www-unix.mcs.anl.gov/SEEDWiki/moin.cgi/SeedInstallationInstructions</a></p>
199 :     </blockquote>
200 : gdpusch 1.8 <h2 id="multiple_copies">Running Multiple Copies of the SEED</h2>
201 : olson 1.1
202 :     For individual users that use the SEED to support comparative analysis, a single copy is completely
203 :     adequate. Adding genomes can usually be done without disrupting normal use, and a very occasional major
204 :     reorganization that runs over the weekend is not a big deal.
205 :     <p>
206 :     The situation is somewhat different when the system is being used to support a major sequencing/annotation
207 :     effort. In this case, you have a user community that is sensitive to disruptions of service, and you
208 :     have frequent demands to update versions of data. In this case, it is best to have two systems: the
209 :     <b>production system</b> is used to support the larger user community, and the <b>update system</b> is
210 : overbeek 1.7 used to prepare updated versions of the system.
211 :     New genomes are added to the update system, and then periodically a
212 :     revised Data directory is extracted to update the production system.
213 :     Even so, work stoppages of a few hours will occur when
214 :     new releases are swapped in.
215 :     <p>
216 :     This use of an "update" and a "production" system is quite analogous
217 :     to running a production system which is occasionally updated from new
218 :     Data DVDs (which FIG normally makes available about every 4-6 months).
219 :     That is, in both cases you are updating a production system from a
220 :     newly created <b>Data</b> directory that is lacking assignments and
221 :     annotations that exist on your production system. However, if you have
222 :     added new genomes to the production system (that are not part of the
223 :     releases you may acquire via DVDs), you should get the new release,
224 :     install the versions of your local genomes, and then do this update
225 :     procedure.
226 :     <p>
227 :     The plan we propose is to build a completely encapsulated new version
228 :     of the system, then capture updates from the old production system, update
229 :     the new production system, and then make the new version the actual
230 :     production system. This last step amounts to altering a symbolic link
231 :     to point at the new production system rather than the old. This has
232 :     the virtue of ease of recovery -- that is, if something goes wrong you
233 :     can flip back to the old system.
234 :     The actual steps are as follows:
235 : olson 1.1 <ol>
236 : gdpusch 1.9
237 :     <li> First, make sure that you are in the BASH shell by typing "echo $SHELL";
238 :     if the result is not "bash", type "bash" to enter the BASH shell.
239 : gdpusch 1.10 <p>
240 : gdpusch 1.9
241 :     <li> Next, check that the result of typing "which perl" is the version
242 :     of perl owned by the SEED; it should look something like
243 :     <pre>
244 :     /Users/fig/FIGdisk/env/mac/bin/perl
245 :     </pre>
246 :     although the exact results will depend on where your existing copy
247 :     of the SEED is installed, whether your platform is a Macintosh or LINUX,
248 :     etc. If the result does not look similar to the above, type:
249 :     <pre>
250 :     source Path_to_FIGdisk/config/fig-user-env.sh
251 :     </pre>
252 :     to setup your FIG environment properly.
253 : gdpusch 1.10 <p>
254 : gdpusch 1.9
255 :     <li> Next, make a copy of the Code Distribution Environment (from a DVD
256 : overbeek 1.7 or via the network). Suppose that we have made such a directory in
257 :     CodeDistEnv. Then use,
258 :     <pre>
259 :     cd CodeDistEnv
260 :     ./install-code TargetDirectory
261 :     </pre>
262 :     where <b>TargetDirectory</b> is where you wish to build the new
263 :     production version. We recommend calling it something like
264 :     <b>FIGdisk.July24</b>.
265 : gdpusch 1.10 <p>
266 : overbeek 1.7
267 : gdpusch 1.6 <li> Stop all work on the production machine for the duration of the update.
268 :     You do this by clicking on the "Seed Control Panel" link,
269 :     and then entering an explanatory message in the text box
270 :     and clicking on the "Disable SEED server" button.
271 : gdpusch 1.10 <p>
272 : gdpusch 1.9
273 : gdpusch 1.6 <li> You now need to capture the assignments, annotations and
274 :     subsystems work that has been done on the production machine.
275 :     To do this, you need to know when the last production release
276 :     was installed. Suppose that it was July 1, 2004.
277 : gdpusch 1.9 If that was the date, we recommend that you run
278 : gdpusch 1.6 <pre>
279 :     <b>extract_data_for_syncing_after_update 7/1/2004 /tmp/sync.data.july.1.2004</b>
280 :     </pre>
281 : gdpusch 1.9
282 : gdpusch 1.6 This will capture your updates and save them in the directory
283 : gdpusch 1.9 /tmp/sync.data.july.1.2004.<br>
284 : gdpusch 1.10 <p>
285 : gdpusch 1.9
286 : overbeek 1.7 <li>Now, you need to stop the existing production system using
287 :     <pre>
288 :     ~/FIGdisk/bin/stop-servers
289 :     </pre>
290 : gdpusch 1.10 <p>
291 : overbeek 1.7
292 :     <li>Now, you need to configure the runtime environment for the system
293 :     you are running on.
294 :     To do this, use
295 :     <pre>
296 :     cd TargetDirectory
297 :     ./configure MacOrLinux
298 :     </pre>
299 :     where <b>MacOrLinux</b> must be a currently supported environment.
300 :     Those that are supported on July 24, 2004 are <b>mac</b> for
301 :     Macintoshes running panther, <b>mac-jaguar</b> for those that have not
302 :     upgraded to panther, and <b>linux-postgres</b>.
303 : gdpusch 1.10 <p>
304 : overbeek 1.7
305 :     <li>Now, you need to insert the new Data directory into the newly
306 :     constructed version of the SEED. To do this use
307 :     <pre>
308 : gdpusch 1.9 chmod -R 777 TheNewData
309 : overbeek 1.7 cd TargetDirectory/FIG
310 :     ln -s TheNewData Data
311 :     </pre>
312 :     where TheNewData is the new Data directory, which normally comes from the
313 :     update system. If you acquired a new Data directory via Data DVDs, you
314 :     will need to unpack them using the README instructions, but what
315 :     results is a new version of the <b>Data</b> directory.
316 : gdpusch 1.10 <p>
317 : gdpusch 1.9
318 : overbeek 1.7 <li>Now, you need to start the servers in order to load the databases
319 :     with the new release using
320 :     <pre>
321 :     cd TargetDirectory/bin
322 :     ./start-servers
323 :     cd ..
324 :     source config/fig-user-env.sh
325 :     init_FIG
326 :     fig load_all
327 :     </pre>
328 :     This last command will run for several hours.
329 : gdpusch 1.10 <p>
330 : gdpusch 1.9
331 : gdpusch 1.11 (<b>WARNING:</b> Please note that, because the new SEED's databases
332 :     do not yet exist, the `init_FIG` command will generate two totally
333 :     harmless but rather terrrifying error messages the very first time it is executed,
334 :     so that its output will look something like this:
335 :    
336 :     <pre>
337 :     DBI connect('dbname=fig;port=10000','fig',...) failed: FATAL: Database "fig" does not exist in the system catalog. at /home2/FIGdisk.July22/dist/releases/snap-2004-0723/linux-postgres/lib/FigKernelPackages/DBrtns.pm line 21
338 :    
339 :     Initializing new SEED database fig
340 :    
341 :     ERROR: DROP DATABASE: database "fig" does not exist
342 :     dropdb: database removal failed
343 :     CREATE DATABASE
344 :     NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'file_table_pkey' for table 'file_table'
345 :     CREATE TABLE
346 :    
347 :     Complete. You will need to run "fig load_all" to load the data.
348 :     </pre>
349 :     We recognize that that generating the above two faux "FATAL" errors
350 :     constitutes a rather ugly and inelegant implementation,
351 :     but we have not yet found a more elegant database initialization method
352 :     that can avoid generating them.)
353 :     <p>
354 :    
355 : gdpusch 1.6 <li> Now, you need to capture the changes made to the old production
356 :     version using something like
357 :     <pre>
358 :     <b>sync_new_system /tmp/sync.data.july.1.2004 make-assignments</b>
359 :     </pre>
360 : gdpusch 1.10 <p>
361 :    
362 : overbeek 1.7 <li>Run
363 : gdpusch 1.10 <pre>
364 : overbeek 1.7 index_annotations
365 :     index_subsystems
366 :     make_indexes
367 : gdpusch 1.10 </pre>
368 :     <p>
369 : gdpusch 1.9
370 :     <li> Now, finally, you should alter the symbolic link in <i>~fig</i> to
371 : overbeek 1.7 the current FIGdisk using something like:
372 :     <pre>
373 :     cd ~fig
374 :     rm FIGdisk # should be removing a symbolic link to the current SEED
375 :     ln -s TargetDirectory FIGdisk
376 :     </pre>
377 :     That should make the new SEED the one available through the Web interface.
378 : gdpusch 1.10 <p>
379 : gdpusch 1.9
380 : gdpusch 1.6 <li> You should now bring your update system to the same state as the
381 :     production system. This can be done by making sure that
382 :     <b>/tmp/sync.data.july.1.2004</b> is accessible to the update system.
383 :     If the production and update systems are run on the same machine, then
384 :     the directory is already there. If not, copy it to <b>/tmp</b> on the
385 :     update machine. Then run
386 :     <br>
387 :     <pre>
388 :     <b>sync_new_system /tmp/sync.data.july.1.2004 make-assignments</b>
389 :     </pre>
390 :     <br>
391 :     on the update machine.
392 : olson 1.1 </ol>
393 : overbeek 1.7 <p>
394 :    
395 : olson 1.1 Our experience is that anytime a group wishes to share a common production environment,
396 : overbeek 1.4 this 2-system approach is the way to do it. You can, if necessary,
397 :     put both systems on the same physical machine. This does require some
398 :     special handling in setting up two different <b>FIGdisk</b>
399 :     directories. We recommend using <b>FIGdisk.production</b> and
400 :     <b>FIGdisk.update</b>. However, in general it makes sense to use two
401 :     separate physical machines, for backup if nothing else. The update
402 :     system can usually be run on a $2000 (or less) box, although it is
403 :     desirable to spend a little more and get at least 1 gigabyte of main
404 :     memory and 200 gigabytes of external disk.
405 : olson 1.1 <br>
406 : gdpusch 1.8 <h2 id="adding_genomes">Adding a New Genome to an Existing SEED</h2>
407 : olson 1.1 To add a new genome to a running SEED is fairly easy, but there are a
408 :     number of details that do have to be handled with care.
409 :     <p>
410 :     The first thing to note is that the SEED does not include tools to call genes -- you are expected
411 :     to provide gene calls. This may change at some point, but for now you must call your own genes. A
412 :     number of good tools now exist in the public domain, and you will need to find one that seems adequate
413 :     for your needs.
414 :     <p>
415 :     Let us now
416 :     cover how to prepare the actual data. You need to construct a directory (in somewhere like ~fig/Tmp)
417 :     of the following form:
418 :     <br>
419 :     <table width="100%">
420 :     <tr>
421 :     <td><tt>GenomeId</tt></td>
422 :     <td></td>
423 :     <td></td>
424 :     <td></td>
425 :     <td>of the form xxxx.y where xxxx is the taxon ID and y is an integer</td>
426 :     </tr>
427 :    
428 :     <tr>
429 :     <td></td>
430 :     <td><tt>PROJECT</tt></td>
431 :     <td></td>
432 :     <td></td>
433 :     <td> a file containg a description of the source of the data</td>
434 :     </tr>
435 :    
436 :     <tr>
437 :     <td></td>
438 :     <td><tt>GENOME</tt></td>
439 :     <td></td>
440 :     <td></td>
441 :     <td>a file containing a single line identifying the genus, species and strain</td>
442 :     </tr>
443 :    
444 :     <tr>
445 :     <td></td>
446 :     <td><tt>TAXONOMY</tt></td>
447 :     <td></td>
448 :     <td></td>
449 :     <td>a file containing a single line containing the NCBI taxonomy</td>
450 :     </tr>
451 :    
452 :     <tr>
453 :     <td></td>
454 :     <td><tt>RESTRICTIONS</tt></td>
455 :     <td></td>
456 :     <td></td>
457 :     <td>a file containing a description of distribution restrictions (optional)</td>
458 :     </tr>
459 :    
460 :     <tr>
461 :     <td></td>
462 :     <td><tt>CONTIGS</tt></td>
463 :     <td></td>
464 :     <td></td>
465 :     <td>contigs in fasta format</td>
466 :     </tr>
467 :    
468 :     <tr>
469 :     <td></td>
470 :     <td><tt>assigned_functions</tt></td>
471 :     <td></td>
472 :     <td></td>
473 :     <td>function assignments for the protein-encoding genes (optional)</td>
474 :     </tr>
475 :    
476 :     <tr>
477 :     <td></td>
478 :     <td><tt>Features</tt></td>
479 :     </tr>
480 :    
481 :     <tr>
482 :     <td></td>
483 :     <td></td>
484 :     <td><tt>peg</tt></td>
485 :     </tr>
486 :    
487 :     <tr>
488 :     <td></td>
489 :     <td></td>
490 :     <td></td>
491 :     <td><tt>tbl</tt></td>
492 :     <td>describes locations and aliases for the protein-encoding genes</td>
493 :     </td>
494 :     </tr>
495 :    
496 :     <tr>
497 :     <td></td>
498 :     <td></td>
499 :     <td></td>
500 :     <td><tt>fasta</tt></td>
501 :     <td>fasta file of translations of the protein-encoding genes</td>
502 :     </td>
503 :     </tr>
504 :    
505 :     <tr>
506 :     <td></td>
507 :     <td></td>
508 :     <td><tt>rna</tt></td>
509 :     </tr>
510 :    
511 :     <tr>
512 :     <td></td>
513 :     <td></td>
514 :     <td></td>
515 :     <td><tt>tbl</tt></td>
516 :     <td>describes locations and aliases for the rna-encoding genes</td>
517 :     </td>
518 :     </tr>
519 :    
520 :     <tr>
521 :     <td></td>
522 :     <td></td>
523 :     <td></td>
524 :     <td><tt>fasta</tt></td>
525 :     <td>fasta file of the DNA corresponding to the genes</td>
526 :     </td>
527 :     </tr>
528 :    
529 :    
530 :     </table>
531 :    
532 :     <!--
533 :    
534 :     <pre>
535 :     GenomeID of the form xxxx.y where xxxx is the taxon ID and y is an integer
536 :    
537 :     PROJECT a file containg a description of the source of the data
538 :    
539 :     GENOME a file containing a single line identifying the genus, species and strain
540 :    
541 :     TAXONOMY a file containing a single line containing the NCBI taxonomy
542 :    
543 :     RESTRICTIONS a file containing a description of distribution restrictions (optional)
544 :    
545 :     contigs contigs in fasta format
546 :    
547 :     assigned_functions function assignments for the protein-encoding genes (optional)
548 :    
549 :     Features
550 :    
551 :     peg
552 :     tbl descibes locations and aliases for the protein-encoding genes
553 :    
554 :     fasta fasta file of translations of the protein-encoding genes
555 :    
556 :     rna
557 :     tbl describes locations and aliases for the rna-encoding genes
558 :    
559 :     fasta fasta file of the DNA corresponding to the genes
560 :     </pre>
561 :     -->
562 :     <br>
563 :     <br>
564 :     Let us expand on this very brief description:
565 :     <ol>
566 :     <li>
567 :     The name of the directory must be of the form xxxx.y where xxxx is the
568 :     taxon ID, and y is a sequence number. For example, 562.1 might be
569 :     used for <i>E.coli</i>, since 562 is the NCBI taxon ID for
570 :     <i>Escherichia coli</i>. The sequence number (y) is used to
571 :     distinguish multiple genomes having the same taxon ID.
572 :     <br><br>
573 :     <li>
574 :     The assigned_functions file contains assignments of function for the
575 :     protein-encoding genes. is of the form
576 :     <pre>
577 :     Id\tFunction\tConfidence (\t stands for a tab character)
578 :     </pre>
579 :     The Id must be a valid PEG Id. These are of the form:
580 :     <pre>
581 :     fig|xxxx.y.peg.z
582 :     </pre>
583 :     where xxxx.y is the genome Id, and z is an integer that uniquely distinguishes
584 :     the peg (protein-encoding gene).
585 :     <br>
586 :     <i>Confidence</i> is a single character code:
587 :     <br>
588 :     <ul>
589 :     <li>a space for "normal"
590 :     <li>w for "weak"
591 :     <li>e for experimentally verified
592 :     <li>s for "strong evidence (but not experimental)"
593 :     </ul>
594 :     The second tab and the confidence code can be omitted (it will default to a space).
595 :     The assigned_functions file is optional. You can leave it blank and, after adding the genome
596 :     to the SEED, ask for automated assignments.
597 :     <br><br>
598 :     <li>
599 :     The tbl files specify the locations of genes, as well as any aliases. Each line in a tbl line
600 :     is of the form
601 :     <br>
602 :     <pre>
603 :     Id\tLocation\tAliases (the aliases are separated by tabs)
604 :     </pre>
605 :     The Id must conform to the fig|xxxx.y.peg.z format described above. The <i>Location</i> is of the form
606 :     <br>
607 :     <pre>
608 :     L1,L2,L3...Ln
609 :    
610 :     where each Li describes a region on a contig and is of the form
611 :    
612 :     <i>Contig_Begin_End</i> where
613 :    
614 :     Contig is the Id of the contig,
615 :     Begin is the position of the first character, and
616 :     End is the position of the last character
617 :     </pre>
618 :     <ul>
619 :     <li>if Begin > End, the region being described is on the complementary strand, and
620 :     <li>the End position is the last character preceding the stop codon (i.e., the region
621 :     corresponding to a protein-encoding gene is thought of as including all bases from the
622 :     first base of the start codon to the last base before the stop codon.
623 :     </ul>
624 :     For example,
625 :     <pre>
626 :     fig|562.1.peg.15 Escherichia_coli_K12_14168_15295 dnaJ b0015 sp|P08622 gi|16128009
627 :     </pre>
628 :     describes the <i>dnaJ</i> gene encoded on the positive strand from 14168 through 15295 on the contig Escherichia_coli_K12.
629 :     The gene is from the genome 562.1, and it has 4 specified aliases.
630 :     <li>
631 :     The fasta files must have gene Ids that match tbl file entries. The <i>peg</i> fasta file contains translations,
632 :     while the <i>rna</i> fasta file contains DNA sequences.
633 :     <li>
634 :     Both the <i>peg</i> and the <i>rna</i> subdirectories are optional.
635 :     </ol>
636 :     <br>
637 :     The SEED provides a utility that can be used to produce such a directory from a GenBank entry. Thus,
638 :     <br>
639 :     <pre>
640 :     parse_genbank 562.4 ~/Tmp/562.4 < genbank.entry.for.a.new.E.coli.genome
641 :     </pre>
642 :     would attempt to produce a properly formatted directory (~/Tmp/562.4) containing
643 :     the data encoded in the GenBank entry from the file <i>genbank.entry.for.a.new.E.coli.genome</i>.
644 :     This script is far from perfect, and there is huge variance in encodings in GenBank
645 :     files. So, use it at your own risk (and, manually check the output).
646 :     <p>
647 :     You would be well advised to look at some of the subdirectories included in the FIGdisk/FIG/Data/Organisms directory
648 :     to see examples of how it should be done.
649 :     <p>
650 :     So, supposing that you have built a valid directory (say, <i>/Users/fig/Tmp/562.4</i>), you can add the genome using
651 :     <pre>
652 :     fig add_genome /Users/fig/Tmp/562.4
653 :     </pre>
654 :     <br>
655 :     The <i>add_genome</i> request will add your new genome and queue a computational request that similarities
656 :     be computed for the protein-encoding genes.
657 :    
658 : gdpusch 1.8 <h2 id="sims">Computing Similarities</h2>
659 : olson 1.1
660 :     Adding a genome does not automatically get similarities computed for the new genome; it queues the request.
661 :     To get the similarities actually computed, you need to establish a computational environment on which
662 :     the blast runs will be made, and then initiate a request on the machine running the SEED.
663 :     <p>
664 :     This is not a completely trivial process because there are a variety of different ways to compute
665 :     similarities:
666 :     <ol>
667 :     <li> You can just compute them on the system running the SEED. This can take several days, but this
668 :     is often a perfectly reasonable way to get the job done.
669 :     <li>Alternatively, you may be in an environment where you have a set of networked machines (say, 4-5 machines),
670 :     and you wish to just exploit these machines to do the blast runs.
671 :     <li> Finally, you may be dealing with a large genome or genomes (and, hence, the need for many days of computation).
672 :     In this case, it makes sense to utilize a large computational resource, and this resource may either
673 :     be a local cluster or a service provided over the net.
674 :     </ol>
675 :     <br>
676 :     To establish the flexibility needed to support all of these alternatives, we implemented the following
677 :     approach:
678 :     <ul>
679 :     <li>
680 :     The user can describe one or more <b>similarity computational environments</b>
681 :     in a configuration file called <i>similarities.config</i>. The details of this encoding
682 :     are beyond the scope of this document.
683 :     These environments all represent potential ways to compute similarities.
684 :     <br>
685 :     <li>
686 :     When a SEED systems administrator (usually, the normal SEED user) wishes to run similarities,
687 :     he runs a program specifying a specific similarity computational environment. This causes all
688 :     the queued similarity requests to be batched up and sent off to the specified server (which may simply
689 :     be on the same machine). He would use the <b>generate_similarities</b> command specifying two parameters: the
690 :     first specifies a similarities computational environment, and the second specifies whether or not automated assignments
691 :     should be computed as the similarity computations complete and the results are installed.
692 :     As the similarities complete, they will automatically be installed. Further, if a set of similarities arrive
693 :     for a given protein-encoding gene, and if there is no current assignment of function for the gene,
694 :     an automated assignment may be computed. Whether or not such automated assignments are computed is determined
695 :     by the second parameter in the command used by the systems administrator to initiate the request. For example,
696 :     <pre>
697 :     generate_similarities local auto-assignments
698 :     </pre>
699 :     specifies a similarity computational environment labeled <i>local</i>, which presumably means "run the blast
700 :     requests on this machine", and requests automated assignments for all protein-encoding genes that currently either
701 :     have no assigned function or have an assigned function that is "hypothetical".
702 :     </ul>
703 :     <br>
704 :    
705 :     We anticipate that at least one major center (Argonne National Lab) and, perhaps, more will create well-defined
706 :     interfaces for handling high-volume requests. At FIG, we will maintain a set of instructions on how to set up
707 :     your configuration to exploit these resources.
708 : overbeek 1.12 <p>
709 :     No matter how you produce the new similarities, they need to be added
710 :     as a file in the <b>FIGdisk/FIG/Data/NewSims</b> directory. Then, you
711 :     need to index these similarities using
712 :     <pre>
713 :     index_sims ~/FIGdisk/FIG/Data/NewSims/XXXX
714 :     </pre>
715 :     where XXXX is the file you added. If you have more than one such
716 :     file, just put in several arguments for the command. This will
717 :     "index" the similarities in that any of the new PEGs which have
718 :     similarities connecting them to other PEGs from the existing genomes
719 :     can now be displayed. However, the connection from the existing
720 :     genomes to the new PEGs does not yet exist (we call these the "flips"
721 :     of the computed sims). To get this ability, you need to go through a
722 :     process that will make your system unavailable for a period (and, it
723 :     will produce a substantial load on your system for a day or so, while
724 :     the SEED sorts, sifts, inserts, and generally plays with the "flips").
725 :     <br>
726 :     The extra steps you need to take to make a fully functional version
727 :     are as follows:
728 :     <ol>
729 :     <li>
730 :     First, you need to run
731 :     <pre>
732 :     update_sims ~/FIGdisk/FIG/Data/Global/peg.synonyms 300 ~/FIGdisk/FIG/Data/Sims ~/Tmp/FlippedSims ~/FIGdisk/FIG/Data/NewSims/*
733 :     </pre>
734 :     This should produce updated similarity files in a VERY BIG directory
735 :     that we happened to put at <i>~/Tmp/Flipped</i> (but, which you could
736 :     put anywhere). This may run as much as a day or so (and you can watch
737 :     its progress as it updates the similarity files).
738 :     <li>The next step is to replace the existing similarity files with the
739 :     newly computed ones. You need to make the SEED unavailable (via the
740 :     <b>SEED Control Panel</b>.
741 :     <li>Then, blow away the existing similarities using something like
742 :     <pre>
743 :     rm ~/FIGdisk/FIG/Data/Sims/*
744 :     rm ~/FIGdisk/FIG/Data/NewSims/*
745 :     cp ~/Tmp/FlippedSims/* ~/FIGdisk/FIG/Data/Sims
746 :     rm -r ~/Tmp/FlippedSims
747 :     </pre>
748 :     There are several ways to do this. You might want to save the old
749 :     similarities somewhere. You might be able to move (rather than copy),
750 :     the similarities. Whatever suits you.
751 :     <li> Then run
752 :     <pre>
753 :     index_sims
754 :     </pre>
755 :     to re-index all of the similarities, and you should be fully
756 :     operational.
757 :     </ol>
758 :     <br>
759 : olson 1.1
760 : gdpusch 1.8 <h2 id="deleting_genomes">Deleting Genomes from a Version of the SEED</h2>
761 : olson 1.1
762 :     There are two common instances in which one wishes to delete genomes from a running version of the SEED: one is
763 :     when you wish to replace an existing version of a genome (in which case the replacement is viewed as first
764 :     deleting the existing copy and then adding the new copy), and the second is when you wish to create a copy
765 :     of the SEED containing a subset of the entire collection of genomes.
766 :     <p>
767 :     To delete a set of genomes from a running version of the SEED, just use
768 :     <pre>
769 :     fig delete_genomes G1 G2 ...Gn (where G1 G2 ... Gn designates a list of genomes)
770 :     </pre>
771 :     For example,
772 :     <pre>
773 :     fig delete_genomes 562.1
774 :     </pre>
775 :     could be used to delete a single genome with a genome ID of 562.1.
776 :     <p>
777 :     To make a copy with some genomes deleted to give to someone else requires a little different approach.
778 :     To extract a set of genomes from an existing version of the SEED, you need to run the command
779 :     <pre>
780 :     extract_genomes Which ExistingData ExtractedData
781 :     </pre>
782 :    
783 :     The first argument is either the word "unrestricted" or the name of a file containing a list of
784 :     genome IDs (the genomes that are to be retained in the extraction). The second argument is
785 :     the path to the current Data directory. The third argument specifies the name of a directory
786 :     that is created holding the extraction. Thus,
787 :     <pre>
788 : overbeek 1.12 extract_genomes unrestricted ~/FIGdisk/FIG/Data /Volumes/Tmp/ExtractedData
789 : olson 1.1 </pre>
790 :     would created the extracted Data directory for you. If you wish to then produce a fully distributable
791 :     version of the SEED from the existing version and the extracted Data directory, you would
792 :     use
793 :     <pre>
794 : overbeek 1.12 make_a_SEED ~/FIGdisk /Volumes/Tmp/ExtractedData /Volumes/MyFriend/FIGdisk.ReadyToGo
795 : olson 1.1 rm -rf /Volumes/Tmp/ExtractedData
796 :     </pre>
797 :    
798 : gdpusch 1.8 <h2 id="reintegrate_sims">Periodic Reintegration of Similarities</h2>
799 : olson 1.1
800 :     When the initial SEED was constructed, similarities were computed. For most similarities of the form
801 :     "Id1 and Id2 are similar", entries were "recorded" for both Id1 and Id2. This is not always true,
802 :     since we truncate the number of similarities associated with any single Id (leaving us in a situation
803 :     in which we may have similarity recorded for Id1, but not Id2). When a genome is added, if Id1 was an added
804 :     protein-encoding gene (peg), then the similarity is "recorded" for Id1 but not Id2. This means that when looking
805 :     at genes from previously existing organisms, you never get links back to the added pegs. This is not totally
806 :     satisfactory.
807 :     <p>
808 :     Periodically, it is probably a good idea to "reinitegrate the similarities". This can be done by
809 :     just running
810 :     <pre>
811 :     reintegrate_sims
812 :     # update_sims /dev/null /dev/null ~/FIGdisk/FIG/Data/NewSims/* ; rm -f ~/FIGdisk/FIG/Data/NewSims/* index_sims
813 :     </pre>
814 :     The job will probably run for quite a while (perhaps as much as a day or two).
815 :    
816 : gdpusch 1.8 <h2 id="pins_and_clusters">Computing "Pins" and "Clusters"</h2>
817 : olson 1.1
818 :     The SEED displays potentially significant clusters on prokaryotic chromosomes. In the
819 :     process of finding preserved contiguity, it computes "pins", which are simply a set of genes
820 :     that are believed to be orthologs that cluster with similar genes. If you add your own genome,
821 :     you will probably want to compute and enter these into the active database. This can be done
822 :     using
823 :     <pre>
824 :     compute_pins_and_clusters G1 G2 G3 ...
825 :     </pre>
826 :     where the arguments are genome Ids. Thus,
827 :     <pre>
828 :     compute_pins_and_clusters 562.4
829 :     </pre>
830 :     would compute and add entries for all of the <i>pegs</i> in genome 562.4.

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3