cctools-4.0-source/0000751060042600000500000000000012175446362013157 5ustar btovardipcctools-4.0-source/.gitignore0000640060042600000500000000013212175446362015143 0ustar btovardip*.a *.dylib *.dSYM *.gz *.html *.o *.swp cctools.test.log configure.rerun Makefile.config cctools-4.0-source/COPYING0000640060042600000500000004310312175446362014213 0ustar btovardip GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. , 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. cctools-4.0-source/CREDITS0000640060042600000500000000670112175446362014203 0ustar btovardip This package is developed primarily by member of the Cooperative Computing Lab at the University of Notre Dame. Many people have contributed features, bug fixes, documentation, and other items. In alphabetical order: Michael Albrecht University of Notre Dame Created the Parrot-S3 module and contributed to Work Queue and Makeflow. Chris Bauschka Purdue University Contributed to Work Queue and the Sweeper abstraction. John Bent University of Wisconsin Debugged early versions of parrot on many applications with NeST. Dan Bradley University of Wisconsin Contributed the Parrot-CVMFS module and a variety of bug fixes. Christophe Blanchet IBCP Developed new support for Parrot to work with the EGEE software and bioinformatics applications. Brian Bockelman University of Nebraska-Lincoln Contributed the Parrot "Paranoid" shutdown mode. Hoang Bui University of Notre Dame Created the chirp_distribute and chirp_matrix modules. Peter Bui University of Notre Dame Created the Parrot-HDFS module and many improvements to Makeflow and Work Queue. Benjamin Couturier CERN Provided patches to work with the CASTOR name space. Patrick Donnelly University of Notre Dame Contributed to Chirp, Parrot, HDFS Support, and ticket authentication. Iheanyi Ekuchuku University of Notre Dame Contributed to Work Queue and the Sweeper abstraction. Michael Ernst, Patrick Fuhrmann, and Tigran Mkrtchyan Fermi National Labs and DESY Provided invaluable help installing, configuring, and using dcache for use with Parrot. Jamie Frey University of Wisconsin Debugged and deployed ftp_lite. Jeffrey Hemmes University of Notre Dame Developed support for distributed access control lists. Miron Livny University of Wisconsin Provided excellent strategic and technical advice as my Ph.D. advisor. Zach Miller University of Wisconsin Tested and deployed parrot with BLAST. Chris Moretti University of Notre Dame Contributed extensively to the implementation of Chirp, abstractions for distributed computing, and the SAND assembler. Kevin Partington University of Notre Dame Contributed features to Makeflow and Work Queue. Francesco Prelz INFN Milan Contributed numerous bug fixes and performance improvements to Parrot. Dinesh Rajan University of Notre Dame Contributed to Work Queue and multiple elastic applications. Sander Klous NIKHEF Tested and deployed parrot with BaBar and Objectivity. Csaba Kos Contributed bug fixes to Parrot and Chirp. Peter Kunszt CERN Patches to run on variations of Linux Glite-IO module. Paul Madrid University of Notre Dame Implemented the reservation ACL feature. Michael Olson University of Notre Dame Contributed to the design and implementation of SAND. Kevin Partington University of Notre Dame Contributed to features in Makeflow. Alain Roy University of Wisconsin Tested and deployed ftsh with the Virtual Data Toolkit. Hugh Sasse De Montfort University, U.K. Contributed to the Fault Tolerant Shell Ulrich Schwickerath FZH Hamburg Contributed RFIO driver and Infiniband support for Parrot. Igor Sfiligoi, Aureliano Rama, Simone Pagan Griso, Donatella Lucchesi INFN Padova and Fermi National Laboratory Contributed to the Design and implementation of the GROW filesystem. Andrew Thrasher University of Notre Dame Contributed to SAND and several Work Queue applications. Li Yu Notre Dame Contributed to work queue, makeflow, all-pairs, and SAND. Thanks to one and all! cctools-4.0-source/Makefile0000640060042600000500000000077612175446362014631 0ustar btovardipinclude Makefile.config include Makefile.rules all clean: Makefile.config for p in ${CCTOOLS_PACKAGES} ; do cd $$p && ${MAKE} $@ && cd .. ; done test: Makefile.config ./run_all_tests.sh install: all Makefile.config for p in ${CCTOOLS_PACKAGES} ; do cd $$p && ${MAKE} $@ && cd .. ; done mkdir -p ${CCTOOLS_INSTALL_DIR}/etc cp Makefile.config ${CCTOOLS_INSTALL_DIR}/etc/Makefile.config cp COPYING ${CCTOOLS_INSTALL_DIR}/doc Makefile.config: @echo "You must run 'configure' before '${MAKE}'." @exit 1 cctools-4.0-source/Makefile.rules0000640060042600000500000000041612175446362015751 0ustar btovardip# # Rules for building various sorts of files # .c.o: ${CCTOOLS_CC} ${CCTOOLS_INTERNAL_CCFLAGS} -c $< -o $@ .cc.o: ${CCTOOLS_CXX} ${CCTOOLS_INTERNAL_CXXFLAGS} -c $< -o $@ .C.o: ${CCTOOLS_CXX} ${CCTOOLS_INTERNAL_CXXFLAGS} -c $< -o $@ .o.a: ${CCTOOLS_AR} rv $@ $^ cctools-4.0-source/README0000640060042600000500000000403112175446362014035 0ustar btovardip The Cooperative Computing Tools (cctools) is a software package for enabling large scale distributed computing on clusters, clouds, and grids. It is used primarily for attacking large scale problems in science and engineering. You can read more about this software at: http://www.nd.edu/~ccl/software The software is developed by members of the Cooperative Computing Lab at the University of Notre Dame, led by Prof. Douglas Thain. The file CREDITS lists the many people that have contributed to the software over the years. For complete instructions on how to build, install, and use the software, see here: http://www.nd.edu/~ccl/software/manuals If you are impatient, the following commands will build and install the software in your home directory: ./configure --prefix $HOME/cctools make install export PATH=$HOME/cctools/bin chirp_status ------------------------------------------------------------ This software package is Copyright (c) 2003-2004 Douglas Thain Copyright (c) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. ------------------------------------------------------------ This product includes software developed by and/or derived from the Globus Project (http://www.globus.org/) to which the U.S. Government retains certain rights. ------------------------------------------------------------ This product includes code derived from the RSA Data Security, Inc. MD5 Message-Digest Algorithm. ------------------------------------------------------------ This product includes public domain code for the SHA1 algorithm written by Peter Gutmann, David Ireland, and A. M. Kutchman. ------------------------------------------------------------ The Glite module of Parrot is Copyright (c) Members of the EGEE Collaboration. 2004. See http://eu-egee.org/partners/ for details on the copyright holders. For license conditions see the license file or http://eu-egee.org/license.html ------------------------------------------------------------ cctools-4.0-source/README.debian0000640060042600000500000000075012175446362015262 0ustar btovardipRequired packages: * build-essential * zlib1g-dev Optional packages: * doxygen (documentation) * libfuse-dev (fuse chirp module) * libglobus-common-dev (globus support) * libglobus-gss-assist-dev (gssapi support) * libkrb5-dev (kerberos support) * libmysqlclient-dev (mysql support) * libreadline-dev (readline support) * python-dev (python package) * m4 (manpages) Debian Package page: * http://packages/debian.org/source/sid/cctools cctools-4.0-source/allpairs/0000751060042600000500000000000012175446362014766 5ustar btovardipcctools-4.0-source/allpairs/Makefile0000640060042600000500000000025212175446362016425 0ustar btovardipinclude ../Makefile.config include ../Makefile.rules all test install clean: for p in src test; do cd $$p && $(MAKE) $@ && cd .. ; done .PHONY: all install test clean cctools-4.0-source/allpairs/src.tpds/0000751060042600000500000000000012175446362016526 5ustar btovardipcctools-4.0-source/allpairs/src.tpds/Makefile0000640060042600000500000000175012175446362020171 0ustar btovardipCCTOOLS_HOME = ../../../ include ${CCTOOLS_HOME}/Makefile.config include ${CCTOOLS_HOME}/Makefile.rules TARGETS = allpairs allpairs_status allpairs_wait allpairs_cleanup LOCAL_LDFLAGS=-lchirp -ldttools ${CCTOOLS_INTERNAL_LDFLAGS} all: ${TARGETS} allpairs: allpairs.o ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} -lm #-lefence allpairs_status: allpairs_status.o ${CCTOOLS_HOME}/chirp/src/libchirp.a ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} allpairs_wait: allpairs_wait.o ${CCTOOLS_HOME}/chirp/src/libchirp.a ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} allpairs_cleanup: allpairs_cleanup.o ${CCTOOLS_HOME}/chirp/src/libchirp.a ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} test: clean: rm -f core *~ *.o *.a ${TARGETS} install: all mkdir -p ${CCTOOLS_INSTALL_DIR}/bin cp allpairs ${CCTOOLS_INSTALL_DIR}/bin cp allpairs_wait ${CCTOOLS_INSTALL_DIR}/bin cp allpairs_status ${CCTOOLS_INSTALL_DIR}/bin cp allpairs_cleanup ${CCTOOLS_INSTALL_DIR}/bin cp allpairs_wrapper.sh ${CCTOOLS_INSTALL_DIR}/bin cctools-4.0-source/allpairs/src.tpds/allpairs.c0000640060042600000500000015246412175446362020515 0ustar btovardip/* Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "chirp_reli.h" #include "chirp_protocol.h" #include "chirp_acl.h" #include "chirp_group.h" #include "chirp_matrix.h" #include "catalog_query.h" #include "nvpair.h" #include "link.h" #include "stringtools.h" #include "debug.h" #include "timestamp.h" #include "auth_all.h" #include "stringtools.h" #include "xxmalloc.h" #include "list.h" #include "domain_name_cache.h" #include "md5.h" #include "macros.h" #include "ragged_array.h" const int MAXFILENAME = 256; const int MAXRESULTLINE = 1024; int limit; static time_t stoptime=0; static void show_help(const char *cmd) { printf("Use: %s [options] \n", cmd); printf("where options are:\n"); printf(" -a Explicit authentication mode.\n"); printf(" -d Enable debugging for this subsystem. (Try -d all to start.)\n"); printf(" -t Timeout, e.g. 60s\n"); printf(" -R Force remote execution, even if it is modeled to be slower.\n"); printf(" -L Force local execution, do not distribute and submit batch jobs.\n"); printf(" -p Index into SetA of the first comparison. (Default: 0)\n"); printf(" -q Index into SetB of the first comparison. (Default: 0)\n"); printf(" -r Index into SetA of the last comparison. (Default: last index of SetA)\n"); printf(" -s Index into SetB of the last comparison. (Default: last index of SetB)\n"); printf(" -l Prefix for local state (default: /tmp/WorkloadID/)\n"); printf(" -H Hostname for remote matrix metadata (default: sc0-00.cse.nd.edu)\n"); printf(" -P Path for remote matrix metadata (default: /userid/matrixmeta/HOSTNAME_DATE_WorkloadID)\n"); printf(" -v Show version string\n"); printf(" -h Show this help screen\n"); } /* Cygwin does not have 64-bit I/O, while Darwin has it by default. */ #if CCTOOLS_OPSYS_CYGWIN || CCTOOLS_OPSYS_DARWIN || CCTOOLS_OPSYS_FREEBSD #define fopen64 fopen #define open64 open #define lseek64 lseek #define stat64 stat #define fstat64 fstat #define lstat64 lstat #define fseeko64 fseeko #define ftruncate64 ftruncate #define truncate64 truncate #define statfs64 statfs #define fstatfs64 fstatfs #endif static INT64_T do_put_recursive( const char *source_file, const char *target_host, const char *target_file ); static INT64_T do_put_one_dir( const char *source_file, const char *target_host, const char *target_file, int mode ); static INT64_T do_put_one_link( const char *source_file, const char *target_host, const char *target_file ); static INT64_T do_put_one_file( const char *source_file, const char *target_host, const char *target_file, int mode, INT64_T length ); static INT64_T do_put_one_dir( const char *source_file, const char *target_host, const char *target_file, int mode ) { char new_source_file[CHIRP_PATH_MAX]; char new_target_file[CHIRP_PATH_MAX]; struct list *work_list; const char *name; int result; struct dirent *d; DIR *dir; //printf("Putting directory %s onto %s at %s\n",source_file, target_host, target_file); work_list = list_create(); result = chirp_reli_mkdir(target_host,target_file,mode,stoptime); if(result==0 || errno==EEXIST ) { result = 0; dir = opendir(source_file); if(dir) { while((d=readdir(dir))) { if(!strcmp(d->d_name,".")) continue; if(!strcmp(d->d_name,"..")) continue; list_push_tail(work_list,xxstrdup(d->d_name)); } closedir(dir); while((name=list_pop_head(work_list))) { sprintf(new_source_file,"%s/%s",source_file,name); sprintf(new_target_file,"%s/%s",target_file,name); result = do_put_recursive(new_source_file,target_host,new_target_file); free((char*)name); if(result<0) break; } } else { result = -1; } } else { result = -1; } while((name=list_pop_head(work_list))) free((char*)name); list_delete(work_list); return result; } static INT64_T do_put_one_link( const char *source_file, const char *target_host, const char *target_file ) { char linkdata[CHIRP_PATH_MAX]; int result; //printf("Putting link %s onto %s at %s\n",source_file, target_host, target_file); result = readlink(source_file,linkdata,sizeof(linkdata)); if(result>0) { linkdata[result] = 0; //complete_local_path(linkdata,linkdatafull); chirp_reli_unlink(target_host,target_file,stoptime); result = chirp_reli_symlink(target_host,linkdata,target_file,stoptime); if(result>=0) result = 0; } return result; } static INT64_T do_put_one_file( const char *source_file, const char *target_host, const char *target_file, int mode, INT64_T length ) { FILE *file; int save_errno; file = fopen64(source_file,"r"); if(!file) return -1; //printf("Putting file %s onto %s at %s\n",source_file, target_host, target_file); length = chirp_reli_putfile(target_host,target_file,file,mode,length,stoptime); if(length<0) { save_errno = errno; fclose(file); errno = save_errno; return -1; } if(length>=0) { fclose(file); return length; } else { save_errno = errno; fclose(file); errno = save_errno; return -1; } fclose(file); } static INT64_T do_put_recursive( const char *source_file, const char *target_host, const char *target_file ) { int result; struct stat64 info; //printf("Putting %s onto %s at %s\n",source_file, target_host, target_file); result = lstat64(source_file,&info); if(result<0) { result = -1; } else { if(S_ISLNK(info.st_mode)) { //printf("link %s\n",target_file); result = do_put_one_link(source_file,target_host,target_file); } else if(S_ISDIR(info.st_mode)) { //printf("dir %s\n",target_file); result = do_put_one_dir(source_file,target_host,target_file,0700); } else if(S_ISREG(info.st_mode)) { //printf("file %s [%sB]\n",target_file,string_metric(info.st_size,-1,0)); result = do_put_one_file(source_file,target_host,target_file,info.st_mode,info.st_size); //if( result >= 0 ) // xfer_bytes += result; } else { //printf("??? %s\n",target_file); result = 0; } //if( result >= 0 ) // xfer_items++; } if(result<0) { printf("couldn't put %s: %s\n",source_file,strerror(errno)); } return result; } struct ragged_array getsetarray(char *setdir) { char* setfile; struct ragged_array nullset = ragged_array_initialize(0); setfile = (char*) malloc((strlen(setdir)+1+strlen("set.list")+1)*sizeof(char)); if(setfile == NULL) {fprintf(stderr,"Allocating set name failed!\n"); return nullset;} sprintf(setfile,"%s/set.list",setdir); return ragged_array_populate(setfile,setdir,strlen(setdir)+CHIRP_PATH_MAX); } int compare_entries( struct nvpair **a, struct nvpair **b ) { int result; const char *x, *y; x = nvpair_lookup_string(*a,"type"); if(!x) x = "unknown"; y = nvpair_lookup_string(*b,"type"); if(!y) y = "unknown"; result = strcmp(x,y); if(result!=0) return result; x = nvpair_lookup_string(*a,"name"); if(!x) x = "unknown"; y = nvpair_lookup_string(*b,"name"); if(!y) y = "unknown"; return strcmp(x,y); } struct ragged_array predist_hosts(double constraint) { struct catalog_query *q; struct nvpair *n; time_t timeout=60, stoptime; const char * catalog_host = 0; int i; int count=0; struct nvpair *table[10000]; INT64_T minavail=constraint; struct ragged_array nullset; nullset.arr = NULL; nullset.row_count = 0; nullset.array_size = 0; struct ragged_array retset = ragged_array_initialize(10); if(retset.array_size == 0) {fprintf(stderr,"Allocating set failed!\n"); return nullset;} stoptime = time(0)+timeout; q = catalog_query_create(catalog_host,0,stoptime); if(!q) { fprintf(stderr,"couldn't query catalog: %s\n",strerror(errno)); return nullset; } while((n = catalog_query_read(q,stoptime))) { table[count++] = n; } qsort(table,count,sizeof(*table),(void*)compare_entries); for(i=0;invpair_lookup_integer(table[i],"avail")) { continue; } } const char *t = nvpair_lookup_string(table[i],"type"); if(t && !strcmp(t,"chirp")) { // if(1) { /*replace line below to access all nodes in chirp pool */ if(strstr(nvpair_lookup_string(table[i],"name"),"sc0-") != NULL) { if(ragged_array_add_line(&retset,nvpair_lookup_string(table[i],"name")) < 0) { fprintf(stderr,"Allocating set[%i] failed!\n",retset.row_count+1); return nullset; } } } } return retset; } struct ragged_array postdist_hosts(FILE* fd) { int len = MAXRESULTLINE; char* line; struct ragged_array nullset; nullset.arr = NULL; nullset.row_count = 0; nullset.array_size = 0; struct ragged_array retset = ragged_array_initialize(10); if(retset.array_size == 0) {fprintf(stderr,"Allocating set failed!\n"); return nullset;} line = (char *) malloc(MAXFILENAME * sizeof(char)); if(line == NULL) {fprintf(stderr,"Allocating line failed!\n"); return retset;} fgets(line, len, fd); if (line != NULL) { size_t last = strlen(line) - 1; if (line[last] == '\n') line[last] = '\0'; } while(!feof(fd)) { if((strpos(line,'Y') == 0)&&(strpos(line,'E') == 1)&&(strpos(line,'S') == 2)&&(strpos(line,' ') == 3)) {// a YES verification if(ragged_array_add_line(&retset,&(line[4])) < 0) { fprintf(stderr,"Allocating set[%i] failed!\n",retset.row_count+1); return nullset; } } // else, do nothing, we just throw away the line. // get next line fgets(line, len, fd); if (line != NULL) { size_t last = strlen(line) - 1; if (line[last] == '\n') line[last] = '\0'; } } /* teststr=`$parrot ls /chirp/$w/${wai}_${fname} 2> /dev/null | wc -l` # test that the data is actually there */ /* if [ $teststr == $gcount ]; then */ /* goodset=$goodset" "$w # add it to the list */ /* ((gsc=$gsc+1)) */ /* echo "$gsc: $w $teststr" */ /* else #if not there, remove any aborted attempt on the chirp server */ /* $parrot rm -rf /chirp/$w/${wai}_${fname} */ /* fi */ return retset; } void msn_prefix(char* shortstr, char * longstr) { char* firstdot = NULL; strcpy(shortstr,longstr); firstdot = strchr(shortstr,'.'); if(firstdot != NULL) firstdot[0]='\0'; } double getTime() { struct timeval t; gettimeofday(&t,0); return t.tv_sec + t.tv_usec/1000000.0; } #define LOG2(x) ( log(x) / log(2) ) double findT(double n,double m,double t,double b,double s,double d, int c, int h) { if(h <= 0 || c <= 0 || h > 400 || (h*c) > (n*m) || (c*t) > limit) return -1; double T = ((((n*m)/c)*(d+(c*t)))/h) + (d*h) + ((((n+m)*s)/b)*LOG2(h)); //printf("\tWith h:%i c:%i c*t: %.0f T:%.0f\n",h,c,c*t,T); return T; } int getbest(double arr[],double T) { int i; double provT = T; int provi = -1; for(i=0;i<8;i++) { if(arr[i] > 0 && arr[i] < provT) { provT=arr[i]; provi=i; } } return provi; } int getch(int *chosen_h, int *chosen_c, double *predicted_T, int n, int m, double t, double b, double s, double d) { double newchoices[8]; int newindex; // pick initial h = 1 int h=1; // pick initial c = 1 row int c=(int) m; limit=3600; double T=-1; int done; while(T == -1) { // find initial T. T=findT(n,m,t,b,s,d,c, h); done = 0; while(!done) { newchoices[0]=findT(n,m,t,b,s,d,c+m, h); newchoices[1]=findT(n,m,t,b,s,d,c-m, h); newchoices[2]=findT(n,m,t,b,s,d,c+m, h+1); newchoices[3]=findT(n,m,t,b,s,d,c-m, h+1); newchoices[4]=findT(n,m,t,b,s,d,c+m, h-1); newchoices[5]=findT(n,m,t,b,s,d,c-m, h-1); newchoices[6]=findT(n,m,t,b,s,d,c, h+1); newchoices[7]=findT(n,m,t,b,s,d,c, h-1); newindex=getbest(newchoices,T); if(newindex == -1) done=1; else { T=newchoices[newindex]; switch(newindex) { case 0: c=c+m; break; case 1: c=c-m; break; case 2: c=c+m; h=h+1; break; case 3: c=c-m; h=h+1; break; case 4: c=c+m; h=h-1; break; case 5: c=c-m; h=h-1; break; case 6: h=h+1; break; case 7: h=h-1; break; default: printf("Error!\n"); exit(1); } //printf("Now at h:%i c:%i c*t: %.0f T:%.0f\n",h,c,c*t,T); } } //printf("%i %i %.0f\n",h,c/n,T); limit*=2; } *chosen_h = h; *chosen_c = c; *predicted_T = T; return 0; } int getchLocal(double *predicted_T, int n, int m, double t) { double T = (n*m*t); *predicted_T = T; return 0; } int makeStatusScript(char* id, int numjobs) { FILE* fp; char* filename = (char*) malloc((strlen(id)+strlen(".APStatus")+1)*sizeof(char)); sprintf(filename,"allpairs_status.sh"); fp = fopen(filename,"w"); if(fp == NULL) return 1; fprintf(fp,"#!/bin/bash\nallpairs_status %s.logfile %i",id,numjobs); fclose(fp); return 0; } int makeWaitScript(char* id) { FILE* fp; char* filename = (char*) malloc((strlen(id)+strlen(".APWait")+1)*sizeof(char)); sprintf(filename,"allpairs_wait.sh"); fp = fopen(filename,"w"); if(fp == NULL) return 1; fprintf(fp,"#!/bin/bash\nallpairs_wait %s.logfile",id); fclose(fp); return 0; } int makeLocalCleanupScript(char* id, char* local_dir, char* mat_host, char* mat_path, char* fun_path) { FILE* fp; char* filename = (char*) malloc((strlen(id)+strlen(".APCleanup")+strlen(".finalize")+1)*sizeof(char)); sprintf(filename,"%s.finalize",id); fp = fopen(filename,"w"); if(fp == NULL) return 1; fprintf(fp,"wID=%i %s\n",(int) strlen(id),id); fprintf(fp,"local_dir=%i %s\n",(int) strlen(local_dir),local_dir); fprintf(fp,"mat_host=%i %s\n",(int) strlen(mat_host), mat_host); fprintf(fp,"mat_path=%i %s\n",(int) strlen(mat_path), mat_path); if(fun_path[0]) fprintf(fp,"fun_path=%i %s\n",(int) strlen(fun_path), fun_path); fclose(fp); return 0; } int makeRemoteCleanupScript(char* id, char* local_dir, char* mat_host, char* mat_path, char* remote_dir, char* node_list, char* hostname, char* fun_path) { FILE* fp; char* filename = (char*) malloc((strlen(id)+strlen(".APCleanup")+strlen(".finalize")+1)*sizeof(char)); sprintf(filename,"%s.finalize",id); fp = fopen(filename,"w"); if(fp == NULL) return 1; fprintf(fp,"wID=%i %s\n",(int) strlen(id),id); fprintf(fp,"local_dir=%i %s\n",(int) strlen(local_dir),local_dir); fprintf(fp,"mat_host=%i %s\n",(int) strlen(mat_host), mat_host); fprintf(fp,"mat_path=%i %s\n",(int) strlen(mat_path), mat_path); fprintf(fp,"remote_dir=%i %s\n",(int) strlen(remote_dir), remote_dir); fprintf(fp,"node_list=%i %s\n",(int) strlen(node_list), node_list); fprintf(fp,"host=%i %s\n",(int) strlen(hostname), hostname); if(fun_path[0]) fprintf(fp,"fun_path=%i %s\n",(int) strlen(fun_path), fun_path); fclose(fp); return 0; } int main(int argc, char** argv) { /**************************************************************************************** main function Section 0 General Declarations, Initializations, Environment, and Command Line Options ****************************************************************************************/ int i; // multipurpose counters. signed char cl; // command line argument selector int retval; // multipurpose return value int did_explicit_auth = 0; // flag for whether the command line specified a particular authentication method int LOCALorREMOTE = -1; // flag for whether the command line specified forced local computation or remote submission int blacoord, blbcoord; // starting indices into the matrix of the first comparison (to allow for potentially larger results super-matrix) int abase, bbase; // starting indices into the set files int abaseend, bbaseend; // ending indices into the set files blacoord = blbcoord = 0; abase = bbase = 0; abaseend = bbaseend = -1; time_t timeout; /* declare and initialize the environment: hostname */ char* hostname= (char*) malloc(MAXFILENAME*sizeof(char)); // allocate space for the source host. if(hostname == NULL) { fprintf(stderr,"Allocating hostname memory failed!\n"); return 1; } char* addr= (char*) malloc(MAXFILENAME*sizeof(char)); // allocate space for the source host's IP address. if(addr == NULL) { fprintf(stderr,"Allocating IP address memory failed!\n"); return 1; } gethostname(hostname,MAXFILENAME); // get hostname, this may not have domain name, though! if(hostname == NULL) { // if that failed fprintf(stderr,"Could not get hostname!\n"); return 2; } domain_name_lookup( hostname, addr ); // so get the IP address of the hostname. if (addr != NULL) { // if that worked domain_name_lookup_reverse(addr, hostname); // do a canonical reverse lookup that will include the domain name } else //otherwise, give a warning. { fprintf(stderr, "Warning: no IP information. Hostname (%s) may not have a domain name!\n", hostname); } free(addr); addr=NULL; /* declare and initialize the environment: userid */ struct passwd *pw = NULL; // a password file structure uid_t uid; // a userid container uid = geteuid(); // get the current uid pw = getpwuid(uid); // pass the current uid to fill the password structure if (!pw) // if the password structure wasn't populated: couldn't get username. { printf("getpwuid() failed. Could not determine username!\n"); return 3; } //postcondition: pw->pw_name contains the userid of the user executing this program. int local_prefix_chosen = 0; // flag for whether the location of local state is specified char* local_prefix = (char*) malloc(CHIRP_PATH_MAX*sizeof(char)); // /var/tmp for example ... where to place local state? if(local_prefix == NULL) { fprintf(stderr,"Allocating local prefix path string memory failed!\n"); return 1; } int matrix_host_chosen = 0; // flag for whether the host of the remote matrix is specified char* matrix_host = (char*) malloc(CHIRP_PATH_MAX*sizeof(char)); // a hostname if(matrix_host == NULL) { fprintf(stderr,"Allocating matrix host string memory failed!\n"); return 1; } char* dateString = (char*) malloc(6*sizeof(char)); // a string to store a date of the form MMMdd if(dateString == NULL) { fprintf(stderr,"Allocating date string memory failed!\n"); return 1; } if(getDateString(dateString) != 1) { // Store the current date, sub in a default value if this fails fprintf(stderr,"Warning, getting date failed. Jan0 will be used instead.\n"); strcpy(dateString,"Jan00"); } int matrix_path_chosen = 0; // flag for whether the path of the remote matrix is specified char* matrix_path = (char*) malloc(CHIRP_PATH_MAX*sizeof(char)); // a path if(matrix_path == NULL) { fprintf(stderr,"Allocating matrix path string memory failed!\n"); return 1; } /* Get and process command line options and arguments */ while((cl=getopt(argc,argv,"+a:d:t:LRx:y:p:q:r:s:l:H:P:hv")) > -1) { switch(cl) { case 'a': auth_register_byname(optarg); did_explicit_auth = 1; break; case 'd': debug_flags_set(optarg); break; case 't': timeout = string_time_parse(optarg); break; case 'L': // force LOCAL execution if(LOCALorREMOTE == 1) { printf("Cannot have -L and -R!\n"); exit(1); } LOCALorREMOTE=0; break; case 'R': // force REMOTE submission if(LOCALorREMOTE == 0) { printf("Cannot have -L and -R!\n"); exit(1); } LOCALorREMOTE=1; break; case 'x': blbcoord=atoi(optarg); break; case 'y': blacoord=atoi(optarg); break; case 'p': abase=atoi(optarg); break; case 'q': bbase=atoi(optarg); break; case 'r': abaseend=atoi(optarg); break; case 's': bbaseend=atoi(optarg); break; case 'l': // explicitly choose location for local state local_prefix_chosen = 1; strcpy(local_prefix,optarg); break; case 'H': matrix_host_chosen = 1; // explicitly choose host for remote matrix metadata strcpy(matrix_host,optarg); break; case 'P': matrix_path_chosen = 1; // explicitly choose path for remote matrix metadata strcpy(matrix_path,optarg); break; case 'h': show_help(argv[0]); exit(0); break; case 'v': cctools_version_print(stdout, argv[0]); exit(0); break; } } cctools_version_debug(D_DEBUG, argv[0]); /* Declare and initialize indices for where on the command line certain required arguments are. Initialize default values for options that were not explicitly chosen. */ int base_index = optind -1 ; int setA_index = base_index+1; // the name of the set file for set 1 int setB_index = base_index+2; // the name of the set file for set 2 int funcdir_index = base_index+3; // the directory defining the function int workloadID_index = base_index+4; // the workload name identifier if(local_prefix_chosen == 0) // if the local state wasn't specified via command line argument sprintf(local_prefix,"/tmp/%s/",argv[workloadID_index]); // default value: /tmp/WORKLOADID for(i=1; i < strlen(local_prefix); i++) // create the prefix hierarchy as necessary if(local_prefix[i] == '/') { local_prefix[i] = '\0'; mkdir(local_prefix, S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH); local_prefix[i] = '/'; } if(matrix_host_chosen == 0) // if the remote matrix host wasn't specified via command line argument strcpy(matrix_host, "sc0-00.cse.nd.edu"); // default value: a well-known ND host -- sc0-00.cse.nd.edu if(matrix_path_chosen == 0) // if the remote matrix path wasn't specified via command line argument sprintf(matrix_path,"%s/matrixmeta/%s_%s_%s",pw->pw_name,hostname,dateString,argv[workloadID_index]);// default value: /USERID/matrixmeta/HOSTNAME_DATE_WORKLOADID if(matrix_host_chosen != matrix_path_chosen) // if one of the two matrix properties was specified, warn the user, as thy may have made a mistake fprintf(stderr,"Warning: Only one of output host or output path was specified. The matrix metadata will be stored at: /chirp/%s/%s\n",matrix_host,matrix_path); if(argc != optind+4) { fprintf(stderr,"After all options, there must be the names of the two sets, the directory defining the function, and the workload ID.\n"); show_help(argv[0]); return 4; } // FIXME: other checks: prefix dir must already exist. stoptime = time(0) + 3600; // initial stoptime for general operations: 1 hour debug_config(argv[0]); // indicate what string to use as the executable name when printing debugging information if(!did_explicit_auth) auth_register_all(); // if an authentication mechanism wasn't chosen, default register all. char starting_directory[CHIRP_PATH_MAX]; getcwd(starting_directory,sizeof(starting_directory)); /**************************************************************************************** main function Section 1 Read sets in to ragged arrays, measure data to determine total set size Determine function directory and function name Create Matrix using proper environments, etc. or default values. ****************************************************************************************/ struct stat64 abuf; // a buffer for stat calls double tsize = 0.0; // total size of a set double asize = 0.0; // size of a set element // read aset into ragged array struct ragged_array setA = getsetarray(argv[setA_index]); if(setA.arr == NULL) { // if no lines in the array fprintf(stderr,"Error reading setA!\n"); return 5; } if(abase >= setA.row_count || abaseend >= setA.row_count) { fprintf(stderr,"Error: -p (%i) or -r (%i) argument larger than size of set %s (%i)!\n", abase, abaseend, argv[setA_index], setA.row_count); return 5; } if(abaseend == -1) abaseend = setA.row_count - 1; const int WL_HEIGHT = abaseend - abase + 1; // Get the total/average size of the items. for(i=abase; i <= abaseend; i++) { stat64(setA.arr[i], &abuf); // stat each item tsize+=abuf.st_size; // add each item's size to the total size } // read bset into array struct ragged_array setB = getsetarray(argv[setB_index]); if(setA.arr == NULL) { // if no lines in the array fprintf(stderr,"Error reading setB!\n"); return 6; } if(bbase >= setB.row_count || bbaseend >= setB.row_count) { fprintf(stderr,"Error: -p (%i) or -r (%i) argument larger than size of set %s (%i)!\n", bbase, bbaseend, argv[setB_index], setB.row_count); return 6; } if(bbaseend == -1) bbaseend = setB.row_count - 1; const int WL_WIDTH = bbaseend - bbase + 1; // Get the total/average size of the items. for(i=bbase; i <= bbaseend; i++) { stat64(setB.arr[i], &abuf); // stat each item tsize+=abuf.st_size; // add each item's size to the total size } asize = tsize/(WL_WIDTH+WL_HEIGHT); //printf("Average item size: %f bytes = %f Mb\n",asize,((asize * 8)/(1024*1024))); /* for(i = 0; i < setA.row_count; i++) { printf("%i: %s (%i)\n", i, setA.arr[i], (int) strlen(setA.arr[i])); } for(i = 0; i < setB.row_count; i++) { printf("%i: %s (%i)\n", i, setB.arr[i], (int) strlen(setB.arr[i])); } */ /* Echo the geometry for general use. */ printf("GEOMETRY (x,y): %i %i\n",WL_WIDTH,WL_HEIGHT); char* function_directory = (char *) malloc((strlen(argv[funcdir_index])+1)*sizeof(char)); // allocate space for function directory string if(function_directory == NULL) { fprintf(stderr,"Allocating function_directory string memory failed!\n"); return 1; } char* func_name = (char *) malloc((strlen(argv[funcdir_index])+1+4)*sizeof(char)); // allocate space for function name string if(func_name == NULL) { fprintf(stderr,"Allocating func_name string memory failed!\n"); return 1; } char* fq_func_name = (char *) malloc((strlen(argv[funcdir_index])+1+4)*sizeof(char)); // allocate space for function name string if(fq_func_name == NULL) { fprintf(stderr,"Allocating fq_func_name string memory failed!\n"); return 1; } short INTERNAL_FUNCTION; if( stat64(argv[funcdir_index], &abuf) ) { // no such directory ... must be an internal function, copy it exactly. INTERNAL_FUNCTION=1; strcpy(fq_func_name,argv[funcdir_index]); strcpy(func_name,argv[funcdir_index]); free(function_directory); function_directory = NULL; } else { // funcdir exists ... not an internal function INTERNAL_FUNCTION=0; /* determine function directory and strip any ending /s off end of directory */ strcpy(function_directory, argv[funcdir_index]); // copy function directory string from command line argument into allocated string while(strlen(function_directory) > 0 && function_directory[strlen(function_directory)-1] == '/') // for all trailing slashes function_directory[strlen(function_directory)-1] = '\0'; // change the trailing slash to a null byte. /* determine function name (without the path) */ int last_slash_index = strrpos(function_directory,'/'); // determine position of the final slash in function directory if(last_slash_index == -1) // if no slash, function name IS the function directory name strcpy(func_name,function_directory); else // otherwise, function name is what comes after the final slash. Ex: quux in /foo/bar/baz/quux strcpy(func_name,&(function_directory[last_slash_index+1])); strcat(func_name,".exe"); //quux.exe sprintf(fq_func_name,"%s/%s",function_directory,func_name); // /foo/bar/baz/quux/quux.exe } /* Determine Chirp Servers to Use for Matrix and Create Matrix*/ struct chirp_matrix *mat = NULL; mat=chirp_matrix_open( matrix_host, matrix_path, stoptime); if(mat == NULL) { char host_file[CHIRP_LINE_MAX]; if(getenv("CHIRP_HOSTS")) { sprintf(host_file,"%s",getenv("CHIRP_HOSTS")); fprintf(stderr,"Using CHIRP_HOSTS -> %s\n",host_file); } else { if(getenv("HOME")) { sprintf(host_file,"%s/.chirp/",getenv("HOME")); if( stat64(host_file, &abuf) ) { // NO .chirp directory defined. fprintf(stderr,"Making .chirp directory\n"); if(mkdir(host_file, S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH)) { // make that directory fprintf(stderr,"mkdir failed to make: %s,using './chirp_matrix_hosts'\n",host_file); sprintf(host_file,"./chirp_matrix_hosts"); } else { sprintf(host_file,"%s/.chirp/chirp_hosts",getenv("HOME")); fprintf(stderr,"mkdir succeeded, using %s\n",host_file); } } else { sprintf(host_file,"%s/.chirp/chirp_hosts",getenv("HOME")); fprintf(stderr,"HOME/.chirp was defined. Using %s\n",host_file); } } else { sprintf(host_file,"./chirp_hosts"); fprintf(stderr,"HOME undefined, using %s\n",host_file); } } if(stat64(host_file, &abuf)) { // it's not defined. fprintf(stderr,"%s doesn't exist, creating it\n",host_file); FILE* hfp = fopen(host_file,"w"); if(hfp == NULL) { fprintf(stderr, "Couldn't determine or assert matrix hosts.\n"); return 7; } fprintf(hfp,"sc0-00.cse.nd.edu\n"); fprintf(hfp,"sc0-01.cse.nd.edu\n"); fprintf(hfp,"sc0-02.cse.nd.edu\n"); fprintf(hfp,"sc0-03.cse.nd.edu\n"); fclose(hfp); } fprintf(stderr,"Creating matrix: %s %s %i %i\n",matrix_host,matrix_path,blbcoord+WL_WIDTH,blacoord+WL_HEIGHT); mat=chirp_matrix_create( matrix_host, matrix_path, blbcoord+WL_WIDTH, blacoord+WL_HEIGHT, 8, 1, stoptime); if(mat == NULL) { fprintf(stderr, "Couldn't create matrix.\n"); return 8; } int rv = chirp_matrix_setacl(matrix_host,matrix_path,"hostname:*.nd.edu","rwl",stoptime); if(rv < 0) { fprintf(stderr, "Couldn't set matrix ACLs.\n"); return 9; } } else { int rv = chirp_matrix_setacl(matrix_host,matrix_path,"hostname:*.nd.edu","rwl",stoptime); if(rv < 0) { fprintf(stderr, "Couldn't set matrix ACLs.\n"); return 10; } chirp_matrix_close(mat, stoptime); } /**************************************************************************************** main function Section 2 Handle local execution if explicitly specified. Do a benchmark using local execution to fill in function time for the model. Handle local execution time if called for by the model. ****************************************************************************************/ char* localexecute = NULL; printf("allpairs_multicore -w %i -i %i -X %i -Y %i -p %i -q %i -r %i -s %i %s %s %s %s %s\n",blbcoord+WL_WIDTH,blacoord+WL_HEIGHT,blbcoord,blacoord,abase,bbase,abaseend,bbaseend,argv[setA_index],argv[setB_index],fq_func_name,matrix_host,matrix_path); fflush(stdout); if(LOCALorREMOTE==0) { // if LOCAL execution was explicitly specified // run local tool printf("FORCE LOCAL!\n\n"); localexecute = (char *) xxmalloc(1024*sizeof(char)); if(localexecute == NULL) { fprintf(stderr,"Allocating local execution string memory failed!\n"); return 1; } sprintf(localexecute,"allpairs_multicore -w %i -i %i -X %i -Y %i -p %i -q %i -r %i -s %i %s %s %s %s %s",blbcoord+WL_WIDTH,blacoord+WL_HEIGHT,blbcoord,blacoord,abase,bbase,abaseend,bbaseend,argv[setA_index],argv[setB_index],fq_func_name,matrix_host,matrix_path); int retval; retval = system(localexecute); exit(retval); } char full_function_directory[CHIRP_PATH_MAX]; if(INTERNAL_FUNCTION == 0) { /* change to the function directory */ chdir(function_directory); getcwd(full_function_directory,sizeof(full_function_directory)); } else { full_function_directory[0] = 0; } /* # This is function dependent: getch n m t b s d */ /* # n - the number of setA elements */ /* # m - the number of setB elements */ /* # t - the time to complete one comparison (1s for Tim's Faces, <.05 for Karen's Irises) */ /* # b - the bandwidth of the network, in Mbps (100 or 1000) */ /* # s - the size of each setA/setB element in Mb (10 for Tim's 1.25MB faces, .16 for Karen's 20KB templates) */ /* # d - the dispatch time for the batch system (10 seconds is v. v. conservative) */ double func_time, bandwidth, element_size, dispatch; double bench_start, bench_end; /* Determine the function execution time with a 16 cell benchmark using the local tool*/ /* FIXME: doesn't work for multi-file functions */ chdir(starting_directory); localexecute = (char *) malloc(6*CHIRP_PATH_MAX*sizeof(char)); if(localexecute == NULL) { fprintf(stderr,"Allocating local execution string memory failed!\n"); return 1; } sprintf(localexecute,"allpairs_multicore -w %i -i %i -X %i -Y %i -p %i -q %i -r %i -s %i %s %s %s %s %s",blbcoord+WL_WIDTH,blacoord+WL_HEIGHT,blbcoord,blacoord,abase,bbase,abase+3,bbase+3,argv[setA_index],argv[setB_index],fq_func_name,matrix_host,matrix_path); bench_start = getTime(); // get the starting mark retval = system(localexecute); bench_end = getTime(); // get the starting mark if(retval != 0) { fprintf(stderr,"Benchmarking run failed with exit status %i.\nBenchmark run was:\n%s\n",retval,localexecute); return 11; } free(localexecute); localexecute=NULL; if(full_function_directory[0]) // if not an internal function, move back to the function directory. chdir(full_function_directory); func_time = (bench_end-bench_start)/16; fprintf(stderr,"Function time: %lf\n",func_time); if(func_time < .001) func_time = .001; bandwidth = 1000; element_size = ((asize * 8)/(1024*1024)); dispatch = 10; int h, c; double T,TL; getch(&h, &c, &T, WL_HEIGHT, WL_WIDTH, func_time, bandwidth, element_size, dispatch); /* GET NUMBER OF ROWS PER JOB int apj; if(c%setB.row_count == 0) apj = c/setB.row_count; else apj = (c/setB.row_count) + 1; */ /* GET BOX SIZE PER JOB*/ int apj = (int) sqrt(c); apj++; // casting on the line above truncates, incrementing "overassigns" amount of work to do per job, rather than underassigning. getchLocal(&TL, WL_HEIGHT, WL_WIDTH, func_time); fprintf(stderr,"H: %i\nCPJ: %i\nAPJ: %i\nRT: %.2f\nLT: %.2f\n",h,c,apj,T,TL); if( (LOCALorREMOTE!=1) && (TL <= T)) { // run local tool fprintf(stderr,"Local execution chosen (%.2f < %.2f)\n",TL,T); chdir(starting_directory); makeLocalCleanupScript(argv[workloadID_index],local_prefix,matrix_host,matrix_path,full_function_directory); char* localexecute = (char *) malloc(CHIRP_PATH_MAX*sizeof(char)); if(localexecute == NULL) { fprintf(stderr,"Allocating local execution string memory failed!\n"); return 1; } sprintf(localexecute,"allpairs_multicore -w %i -i %i -X %i -Y %i -p %i -q %i -r %i -s %i %s %s %s %s %s",blbcoord+WL_WIDTH,blacoord+WL_HEIGHT,blbcoord,blacoord,abase,bbase,abaseend,bbaseend,argv[setA_index],argv[setB_index],fq_func_name,matrix_host,matrix_path); // note: can change abase and bbase to abase+4 and bbase+4 because the benchmarking already did these squares retval = system(localexecute); exit(retval); } fprintf(stderr,"Remote execution chosen (%.2f > %.2f)\n",TL,T); /**************************************************************************************** main function Section 3 Copy the two sets onto the local chirp server Distribute the sets from the local chirp server to the pool Determine which servers have the data ****************************************************************************************/ int chirp_acl_string_len = strlen(hostname)+strlen("hostname:*.nd.edu"); // determine maximum length of an ACL identity char* chirp_acl_string = (char*) malloc(chirp_acl_string_len*sizeof(char)); // allocate space for the ACL identity if(chirp_acl_string == NULL) { fprintf(stderr,"Allocating chirp acl string memory failed!\n"); return 1; } char* chirp_dirname = (char *) malloc(sizeof(char)*(strlen(pw->pw_name)+strlen(argv[workloadID_index])+6+2)); // allocate space for the chirp directory name string if(chirp_dirname == NULL) { fprintf(stderr,"Allocating chirp directory name string memory failed!\n"); return 1; } sprintf(chirp_dirname,"/%s_%s",pw->pw_name,argv[workloadID_index]); // initialize the directory name string to the "parent" directory: USERID_WORKLOADID printf("Chirp_dirname:%s\n",chirp_dirname); chirp_reli_mkdir(hostname,chirp_dirname,0700,stoptime); // create the parent directory // now do two set subdirectories // first subdir sprintf(chirp_dirname,"/%s_%s/%s",pw->pw_name,argv[workloadID_index],"set1"); //printf("Chirp_dirname:%s\n",chirp_dirname); // copy setA directory to local chirp server. do_put_recursive( argv[setA_index], hostname, chirp_dirname); // set acl for that directory on local chirp server sprintf(chirp_acl_string,"hostname:%s", hostname); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rwlda",stoptime); strcpy(chirp_acl_string,"hostname:*.nd.edu"); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rl",stoptime); strcpy(chirp_acl_string,"system:localuser"); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rl",stoptime); if(strcmp(argv[setA_index],argv[setB_index])) { // second subdir sprintf(chirp_dirname,"/%s_%s/%s",pw->pw_name,argv[workloadID_index],"set2"); //printf("Chirp_dirname:%s\n",chirp_dirname); // copy setB directory to local chirp server. do_put_recursive( argv[setB_index], hostname, chirp_dirname); // set acl for that directory on local chirp server sprintf(chirp_acl_string,"hostname:%s", hostname); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rwlda",stoptime); strcpy(chirp_acl_string,"hostname:*.nd.edu"); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rl",stoptime); strcpy(chirp_acl_string,"system:localuser"); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rl",stoptime); } sprintf(chirp_dirname,"/%s_%s",pw->pw_name,argv[workloadID_index]); //printf("Chirp_dirname:%s\n",chirp_dirname); // set acl for the parent directory on local chirp server sprintf(chirp_acl_string,"hostname:%s", hostname); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rwlda",stoptime); strcpy(chirp_acl_string,"hostname:*.nd.edu"); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rl",stoptime); strcpy(chirp_acl_string,"system:localuser"); chirp_reli_setacl(hostname,chirp_dirname,chirp_acl_string,"rl",stoptime); // distribute, starting from the the parent directory, to hosts in the hostset. // determine the available hosts from the catalogue struct ragged_array available_hosts = predist_hosts(tsize); // prepare to allocate the string for all available hosts int host_set_string_length = 0; for(i = 0; i < available_hosts.row_count; i++) host_set_string_length+=(strlen(available_hosts.arr[i])+2); // allocate the string for all available hosts char *host_set_string = (char *) malloc(host_set_string_length * sizeof(char)); if(host_set_string == NULL) { fprintf(stderr,"Allocating host set string memory failed!\n"); return 1; } // fill the string for all available hosts (space delimited). strcpy(host_set_string,available_hosts.arr[0]); for(i = 1; i < available_hosts.row_count; i++) { strcat(host_set_string," "); strcat(host_set_string,available_hosts.arr[i]); } makeRemoteCleanupScript(argv[workloadID_index],local_prefix,matrix_host,matrix_path,chirp_dirname, host_set_string,hostname,full_function_directory); // set timeouts for the distribution int bigT = 7200; int smallT = 600; // allocate and build the distribute command. // command will be used as a general purpose string throughout. char *command = (char *) malloc(strlen("chirp_distribute -a hostname -D -Y -N ")+10+strlen(" -T NNNNN -t NNNNN ")+strlen(hostname)+1+strlen(pw->pw_name)+1+strlen(argv[workloadID_index])+1+strlen(host_set_string)+1); if(command == NULL) { fprintf(stderr,"Allocating distribute command string memory failed!\n"); return 1; } sprintf(command,"chirp_distribute -a hostname -D -Y -N %i -T %i -t %i %s %s %s",h,bigT,smallT,hostname,chirp_dirname,host_set_string); printf("%s\n",command); // Finally actually do the distribution. FILE* cd_pipe=popen(command,"r"); // determine the actual set of nodes to which the sets were distributed struct ragged_array goodset = postdist_hosts(cd_pipe); printf("Distribution Complete to %i Nodes\n",goodset.row_count); free(command); // free the command string command = NULL; // reset the command string if(goodset.row_count == 0) { fprintf(stderr,"Did not distribute to any nodes! Cannot build jobs!\n"); return 12; } /**************************************************************************************** main function Section 4 Build strings to specify lists of prestaged hosts If not internal function: Create function tarball of all items necessary to actually complete the comparison ****************************************************************************************/ // Build string of nodes with prestaged data -- one forward, one backward. Each has a limit of 2047 characters. char* shortstring = (char *) malloc(2048*sizeof(char)); if(shortstring == NULL) { fprintf(stderr,"Allocating MachineShortName string memory failed!\n"); return 1; } char* goodstring1 = (char *) malloc(2048*sizeof(char)); // forward list of all prestaged hosts if(goodstring1 == NULL) { fprintf(stderr,"Allocating forward list string memory failed!\n"); return 1; } goodstring1[0]='\0'; for(i = 0; i < goodset.row_count; i++) { msn_prefix(shortstring,goodset.arr[i]); if((strlen(goodstring1)+strlen(shortstring)+1)<2047) { strcat(goodstring1,shortstring); strcat(goodstring1,","); } } char* goodstring2 = (char *) malloc(2048*sizeof(char)); // backward list of all prestaged hosts if(goodstring2 == NULL) { fprintf(stderr,"Allocating backward list string memory failed!\n"); return 1; } goodstring2[0]='\0'; for(i = goodset.row_count-1; i >= 0; i--) { msn_prefix(shortstring,goodset.arr[i]); if((strlen(goodstring2)+strlen(shortstring)+1)<2047) { strcat(goodstring2,shortstring); strcat(goodstring2,","); } } fprintf(stderr,"GS1: %s\n",goodstring1); fprintf(stderr,"GS2: %s\n",goodstring2); char* goodstring = (char *) malloc(2048*sizeof(char)); // allocate string for list of hosts (may not be full list due to space constraints) char* reqstring = (char *) malloc(2048*sizeof(char)); // allocate string for entire requirements clause char* reqclose = (char *) malloc(2048*sizeof(char)); // allocate string for post-hosts requirements char* tokenstring = (char *) malloc(2048*sizeof(char)); // allocate string for tokenizing char* nexthost; // pointer to the next host if(goodstring == NULL || reqstring == NULL || reqclose == NULL || tokenstring == NULL) { fprintf(stderr,"Allocating requirements string memory failed!\n"); return 1; } if(full_function_directory[0]) { // create a file called exclude.list to be used by tar to indicate items not to be included in tarball FILE* excludep = fopen("exclude.list","w"); if(!excludep) { fprintf(stderr,"Could not open exclusion list for writing.\n"); return 13; } fprintf(excludep,"exclude.list\n"); // write the exclude list into itself. Duh. fprintf(excludep,"%s.func.tar\n",argv[workloadID_index]); // write the function tarball itself into the exclude list. fclose(excludep); // allocate and fill strings for command to create the function tarball, then do it command = (char *) malloc((strlen("tar -X exclude.list -f .func.tar -r ./* 2> /dev/null")+strlen(argv[workloadID_index]))*sizeof(char)); if(command == NULL) { fprintf(stderr,"Allocating tar command string memory failed!\n"); return 1; } sprintf(command,"tar -X exclude.list -f %s.func.tar -r ./* 2> /dev/null",argv[workloadID_index]); system(command); // actually create the function tarball free(command); // free the command string command = NULL; // reset the command string } /**************************************************************************************** main function Section 5 Create a local directory for each job. Measure the disk requirements to include in the submit file requirements Create the submit file, including custom list of hosts for requirements limits Actually Submit Job!!! ****************************************************************************************/ int a, b; // counters for setA (a) and setB (b) //int bpj = WL_WIDTH; // items in set 2 per job ... initialize as 1 full row. int bpj = apj; // square box. char* job_directory = (char *) malloc((strlen(local_prefix) + 1 + strlen(argv[workloadID_index]) + 1 + 8 + 1 + 8)*sizeof(char)); // string for the directory for a given job int ffdl; if(full_function_directory[0]) ffdl = strlen(full_function_directory); else ffdl = 1; command = (char *) malloc((ffdl+strlen(argv[workloadID_index])+strlen("condor_submit .submit")+MAXFILENAME)*sizeof(char)); // general purpose string if(job_directory == NULL) { fprintf(stderr,"Allocating job directory string memory failed!\n"); return 1; } if(command == NULL) { fprintf(stderr,"Allocating condor_submit command string memory failed!\n"); return 1; } int rsl; // length of requirements string. int token_counter = 0; int jobcount = 0; int jobdircount = -1; // for each job, build a submit file and submit the job for(a=abase; a<=abaseend; a+=apj) { // for each element in set a, incrementing by the number of those elements per job for(b=bbase; b<=bbaseend; b+=bpj) { // for each element in set b, incrementing by the number of those elements per job if(jobcount % 10000 == 0) { jobdircount++; sprintf(job_directory,"%s/%i/",local_prefix, jobdircount); // initialize the name of the job superdirectory: PREFIX/COUNT/ mkdir(job_directory, S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH); // make that directory } sprintf(job_directory,"%s/%i/%s.%i.%i",local_prefix, jobdircount, argv[workloadID_index], a , b); // initialize the name of the job directory: PREFIX/COUNT/WORKLOADID.A.B mkdir(job_directory, S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH); // make that directory INT64_T diskreq = 0; // determine the disk requirements if(full_function_directory[0]) { sprintf(command,"%s/%s.func.tar",full_function_directory,argv[workloadID_index]); stat64(command, &abuf); // measure the size of the function tarball diskreq = abuf.st_size; // initialize the overall disk requirement to the size of the function tarball, as this is really all that's transferred diskreq /= 1000; // convert to KB. } diskreq += 100000; //100MB cushion for safety and output and what have you //printf("dr:%lld ; dr2: %lld\n",diskreq,diskreq2); // move to the newly created job directory chdir(job_directory); // create a file called WORKLOADID.submit and begin filling it. sprintf(command,"%s.submit",argv[workloadID_index]); FILE *subp = fopen(command,"w"); fprintf(subp,"universe = vanilla\n"); // set condor universe fprintf(subp,"executable = %s/allpairs_wrapper.sh\n",starting_directory); // set executable -- it's a wrapper. if(strcmp(argv[setA_index],argv[setB_index])) { // if setA != setB fprintf(subp,"arguments = %s %s /chirp/localhost/%s/set1 /chirp/localhost/%s/set2 %s %s %i %i %i %i %i %i %i %i\n",argv[workloadID_index],func_name,chirp_dirname,chirp_dirname,matrix_host,matrix_path,blacoord+WL_HEIGHT,blbcoord+WL_WIDTH,blacoord,blbcoord,a,b,MIN((a+apj-1),abaseend),MIN((b+bpj-1),bbaseend)); } else { // setA == SetB, so we only distributed one copy. fprintf(subp,"arguments = %s %s /chirp/localhost/%s/set1 /chirp/localhost/%s/set1 %s %s %i %i %i %i %i %i %i %i\n",argv[workloadID_index],func_name,chirp_dirname,chirp_dirname,matrix_host,matrix_path,blacoord+WL_HEIGHT,blbcoord+WL_WIDTH,blacoord,blbcoord,a,b,MIN((a+apj-1),abaseend),MIN((b+bpj-1),bbaseend)); } // set first "third" of requirements string /* //Lines below allows jobs to run on either VM/Slot 1 or 2; this is disabled when using Li's multicore functionality. sprintf(reqstring,"Requirements = (Arch==\"INTEL\" || Arch == \"X86_64\") && (Disk > %lld) && (Memory >= 450) && (MachineGroup != \"itm\") && (Machine != \"%s\") && ( (VirtualMachineID == 1) || ((VirtualMachineID == 2) && (Disk > %lld)) ) && ( stringListIMember(MachineShortName, \"",diskreq,hostname,diskreq2); INT64_T diskreq2 = diskreq*2; // double the requirement for dual-processor machines. */ sprintf(reqstring,"Requirements = (Arch==\"INTEL\" || Arch == \"X86_64\") && (Disk > %lld) && (Memory >= 450) && (MachineGroup != \"itm\") && (Machine != \"%s\") && ( (VirtualMachineID == 1)) && ( stringListIMember(MachineShortName, \"",diskreq,hostname); sprintf(reqclose,"\") )\n"); // set third "third" of requirements string rsl = strlen(reqstring)+2+strlen(reqclose); // measure the length of the requirements string's 1st and 3rd parts if(token_counter++%2 == 0) // if "forward" job strcpy(tokenstring,goodstring1); else strcpy(tokenstring,goodstring2); goodstring[0]='\0'; nexthost = strtok(tokenstring,","); // go through "forward" full set until we exhaust the character limit. while(nexthost != NULL && ((strlen(nexthost)+1+rsl)<2046)) { //printf("Goodstring:%s\n",goodstring); if(goodstring[0] != '\0') strcat(goodstring,","); strcat(goodstring,nexthost); nexthost = strtok(NULL,","); } nexthost = NULL; printf("Goodstring:%s\n",goodstring); strcat(reqstring,goodstring); // build full reqstring from three thirds. strcat(reqstring,reqclose); fprintf(subp,"%s\n",reqstring); // print it to the submit file // finish off the submit file fprintf(subp, "Rank = Memory\n"); if(full_function_directory[0]) fprintf(subp, "transfer_input_files = %s/%s.func.tar, %s/allpairs_multicore\n",full_function_directory,argv[workloadID_index],starting_directory); else fprintf(subp, "transfer_input_files = %s/allpairs_multicore\n",starting_directory); fprintf(subp, "output = %s.output\n",argv[workloadID_index]); fprintf(subp, "error = %s.error\n",argv[workloadID_index]); fprintf(subp, "transfer_files = always\n"); fprintf(subp, "log = %s/%s.logfile\n",starting_directory,argv[workloadID_index]); fprintf(subp, "on_exit_remove = (ExitBySignal == False) && (ExitCode == 0)\n"); fprintf(subp, "notification = never\n"); fprintf(subp, "getenv = true\n"); fprintf(subp, "queue\n"); fclose(subp); // close the submit file sprintf(command,"condor_submit %s.submit",argv[workloadID_index]); // build job submission command system(command); // FINALLY SUBMIT JOB! printf("Cluster: %i:%i %i:%i\n",a,b,MIN((a+apj-1),abaseend),MIN((b+bpj-1),bbaseend)); // print job submission notification jobcount++; // increment total number of jobs chdir(starting_directory); // change back to starting directory -- not really necessary. if(full_function_directory[0]) chdir(full_function_directory); // change to the fully qualified function directory to go again. } } chdir(starting_directory); makeStatusScript(argv[workloadID_index], jobcount); makeWaitScript(argv[workloadID_index]); return 0; } /* # Due to a bug with condor_wait, we don't actually clean up here, rather just create a script that will do it for us when we run it manually. */ /* echo "#!/bin/bash */ /* #Cleaning up: */ /* dir=$dir */ /* execdir=$execdir */ /* fname=$fname */ /* #for((p=0; $p<$pcount; p=$p+$ppj)); do */ /* # cat $prefix/$fname.$p.$g/$fname.error >> $dir/$fname.error */ /* # cat $prefix/$fname.$p.$g/$fname.output >> $dir/$fname.output */ /* #done */ /* #cp $dir/$fname.output $dir/$fname.results */ /* rm -rf $prefix/$fname.* */ /* cd $dir */ /* rm $execdir/exclude.list */ /* rm $execdir/$fname.func.tar */ /* rm $execdir/$fname.gal */ /* rm -rf $gallery_location$gallery_dirname/ */ /* rm -rf $prefix/working/$fname/ */ /* echo \"Cleaning up distributed copies\" */ /* chirp_distribute -X -R `hostname` `whoami`_$fname $goodset */ /* $parrot rm -rf /chirp/`hostname`/`whoami`_$fname */ /* " > $dir/$fname.finalize */ /* chmod u+x $dir/$fname.finalize */ /* echo "notification = never" >> $fname.submit # don't e-tase me, bro. */ /* echo "queue" >> $fname.submit */ /* submitout=`condor_submit $fname.submit` #Go! */ /* echo $submitout */ /* cluster=${submitout##*cluster } */ /* cluster=${cluster%%\.} */ /* echo "CLUSTER $cluster $p:$g $p:$((gcount-1))" #append to the output to be a bit more descriptive for this actual application */ /* ((jobcount=$jobcount+1)) */ /* cd $dir */ /* cd $execdir */ /* done */ /* #if we got here, we've submitted all the jobs; now we must just do a condor_wait and then cleanup */ /* ((cmpcount=$pcount*$gcount)) */ /* echo "$jobcount total jobs to complete $cmpcount comparisons" */ /* for((j=1; $j<=$jobcount;j=$j+1)); do */ /* condor_wait -num $j $dir/$fname.logfile */ /* done */ /* condor_wait -num $jobcount $dir/$fname.logfile #wait again, just for the fun of it. */ cctools-4.0-source/allpairs/src.tpds/allpairs_cleanup.c0000640060042600000500000002107412175446362022214 0ustar btovardip/* Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include #include #include #include #include "auth_all.h" #include "debug.h" #include "chirp_matrix.h" void printUsage(char* cmd) { printf("Use: %s -F [finalize file]",cmd); printf(" where options are:\n"); printf(" -a Explicit authentication mode.\n"); printf(" -d Enable debugging for this subsystem. (Try -d all to start.)\n"); //printf(" -t Timeout, e.g. 60s\n"); printf(" -D Download Results Matrix to a file.\n"); printf(" -R Remove remote state.\n"); printf(" -L Remove local state.\n"); printf(" -M Remove results matrix.\n"); printf(" -h Show this help screen\n"); } int main(int argc, char** argv) { signed char cl; int did_explicit_auth = 0; int download,rm_local,rm_remote,rm_mat,file_provided; int rm_remote_error = 0; char matrix_target[CHIRP_PATH_MAX]; char finalize_file[CHIRP_PATH_MAX]; time_t stoptime = time(0)+3600; download=rm_local=rm_remote=rm_mat=file_provided=0; while((cl=getopt(argc,argv,"+a:d:hD:LRMF:")) > -1) { switch(cl) { case 'a': auth_register_byname(optarg); did_explicit_auth = 1; break; case 'd': debug_flags_set(optarg); break; case 'h': printUsage(argv[0]); exit(0); break; case 'D': // download matrix data to local disk download=1; strcpy(matrix_target,optarg); break; case 'L': // force LOCAL state removal rm_local=1; break; case 'R': // force REMOTE state removal (chirp_distribute -X) rm_remote=1; break; case 'M': // force REMOTE MATRIX state removal rm_mat=1; break; case 'F': file_provided=1; strcpy(finalize_file,optarg); break; } } if(!file_provided) { fprintf(stderr,"Please provide argument -F [finalize file]\n"); printUsage(argv[0]); exit(1); } if(!did_explicit_auth) auth_register_all(); // if an authentication mechanism wasn't chosen, default register all. debug_config(argv[0]); // indicate what string to use as the executable name when printing debugging information // first, parse finalize file to get information. char* cmd; char* wID; char* local_dir; char* mat_host; char* mat_path; char* remote_dir; char* node_list; char* hn; char* fun_path; int strlentmp; FILE* fp = fopen(finalize_file,"r"); if(!fp) { fprintf(stderr,"Finalize file not readable.\n"); exit(1); } // 0th item is workload id if(fscanf(fp, " wID=%i ",&strlentmp) == 1) { wID = malloc((strlentmp+1)*sizeof(char)); if(!wID) { fprintf(stderr,"Could not allocate %i bytes for workload ID\n",strlentmp); exit(1); } if(fscanf(fp, " %s ", wID) != 1) { fprintf(stderr,"Could not read in workload ID\n"); exit(2); } } // first item is local prefix -- remove everything. if(fscanf(fp, " local_dir=%i ",&strlentmp) == 1) { local_dir = (char*) malloc((strlentmp+1)*sizeof(char)); if(!local_dir) { fprintf(stderr,"Could not allocate %i bytes for local directory\n",strlentmp); exit(1); } if(fscanf(fp," %s ", local_dir) != 1) { fprintf(stderr,"Could not read in local directory\n"); exit(2); } } // second item is matrix host -\ remove // third item is matrix path -/ matrix if(fscanf(fp, " mat_host=%i ",&strlentmp) == 1) { mat_host = (char *) malloc((strlentmp+1)*sizeof(char)); if(!mat_host) { fprintf(stderr,"Could not allocate %i bytes for matrix host\n",strlentmp); exit(1); } if(fscanf(fp," %s ", mat_host) != 1) { fprintf(stderr,"Could not read in matrix host\n"); exit(2); } } if(fscanf(fp, " mat_path=%i ",&strlentmp) == 1) { mat_path = (char *) malloc((strlentmp+1)*sizeof(char)); if(!mat_path) { fprintf(stderr,"Could not allocate %i bytes for matrix path\n",strlentmp); exit(1); } if(fscanf(fp," %s ", mat_path) != 1) { fprintf(stderr,"Could not read in matrix path\n"); exit(2); } } // 4th item is chirp_dirname if(fscanf(fp, " remote_dir=%i ",&strlentmp) == 1) { remote_dir = (char *) malloc((strlentmp+1)*sizeof(char)); if(!remote_dir) { fprintf(stderr,"Could not allocate %i bytes for remote path\n",strlentmp); exit(1); } if(fscanf(fp," %s ", remote_dir) != 1) { fprintf(stderr,"Could not read in remote path\n"); exit(2); } } if(rm_remote==1) { fprintf(stderr,"Asked to remove remote state, but there is no remote state specified.\n"); rm_remote_error = 1; } // 7th item is full goodstring if(fscanf(fp, " node_list=%i ",&strlentmp) == 1) { node_list = (char *) malloc((strlentmp+1)*sizeof(char)); if(!node_list) { fprintf(stderr,"Could not allocate %i bytes for remote hosts\n",strlentmp); exit(1); } if(fread(node_list,1,strlentmp,fp) != strlentmp) { fprintf(stderr,"Could not read in remote hosts\n"); exit(2); } } if(rm_remote==1 && rm_remote_error == 0) { fprintf(stderr,"Asked to remove remote state, but there is no remote state specified.\n"); rm_remote_error = 1; } // 9th item is hostname if(fscanf(fp, " host=%i ",&strlentmp) == 1) { hn = malloc((strlentmp+1)*sizeof(char)); if(!hn) { fprintf(stderr,"Could not allocate %i bytes for hostname\n",strlentmp); exit(1); } if(fscanf(fp, " %s ", hn) != 1) { fprintf(stderr,"Could not read in hostname\n"); exit(2); } } if(rm_remote==1 && rm_remote_error == 0) { fprintf(stderr,"Asked to remove remote state, but there is no remote state specified.\n"); rm_remote_error = 1; } // 10th item is full function directory -- remove tarball, exception list if(fscanf(fp, " fun_path=%i ",&strlentmp) == 1) { fun_path = (char *) malloc((strlentmp+1)*sizeof(char)); if(!fun_path) { fprintf(stderr,"Could not allocate %i bytes for function directory\n",strlentmp); exit(1); } if(fscanf(fp," %s ", fun_path) != 1) { fprintf(stderr,"Could not read in function directory\n"); exit(2); } cmd = (char *) malloc((strlen(fun_path)+strlen("rm -f ")+strlen(wID)+strlen(".func.tar")+12)*sizeof(char)); if(!cmd) { fprintf(stderr,"Could not allocate memory for command\n"); exit(1); } sprintf(cmd,"rm -f %s/%s.func.tar",fun_path,wID); if(system(cmd)) { fprintf(stderr,"Could not remove %s/%s.func.tar\n",fun_path,wID); exit(1);} sprintf(cmd,"rm -f %s/exclude.list",fun_path); if(system(cmd)) { fprintf(stderr,"Could not remove %s/exclude.list\n",fun_path); exit(1);} free(cmd); cmd=NULL; } else { // internal function fun_path = NULL; } // end parsing finalize file // next, download if desired. if(download) { fprintf(stderr,"Download Matrix Mode\n"); FILE* mt = fopen(matrix_target, "w"); struct chirp_matrix* m = chirp_matrix_open( mat_host, mat_path, stoptime); if(m) { int w = chirp_matrix_width( m ); int h = chirp_matrix_height( m ); //int e = chirp_matrix_element_size( m ); double* buf = malloc(w*sizeof(double)); int x,y; for(y=0; y < h; y++) { chirp_matrix_get_row( m , y, buf, stoptime ); for(x=0; x #include #include #include "chirp_protocol.h" void printUsage(char* cmd) { printf("Use: %s [options] \n", cmd); } int main(int argc, char** argv) { if(argc < 3) { printUsage(argv[0]); return 1; } FILE *statusPipe; char* command = (char *) malloc((strlen("condor_userlog_job_counter ")+strlen(argv[1]))*sizeof(char)); char event[256]; int j, k; int tjobs = atoi(argv[2]); sprintf(command,"condor_userlog_job_counter %s",argv[1]); statusPipe = popen(command, "r"); if(statusPipe == NULL) {fprintf(stderr,"Popen failed!\n"); return 1;} while(!feof(statusPipe)) { //fscanf(fname,"%c",&in); k = fscanf(statusPipe, " Log event: %s",event); if(k != 1) { k=fscanf(statusPipe," outcome: %s",event); if(k != 1) printf("Failed string1: %s\n",event); else ;//printf("Successful string1: %s\n",event); } else ;//printf("Successful string1: %s\n",event); if(strcmp(event,"ULOG_NO_EVENT") != 0) { k=fscanf(statusPipe," Queued Jobs: %d",&j); if(k != 1) { fscanf(statusPipe,"%s",event); printf("Failed string2: %s\n",event); } else { ;//printf("Successful string2: %d\n",j); } } else break; } if(j < 0) { printf("Warning: %i more jobs have finished than started! (%.2f%% of total jobs)\n",-j,-100*((float)j/tjobs)); } else { printf("%i (%.2f%%) jobs have not finished.\n",j,100*((float)j/tjobs)); } return 0; } cctools-4.0-source/allpairs/src.tpds/allpairs_wait.c0000640060042600000500000000101412175446362021521 0ustar btovardip/* Copyright (C) 2008- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include #include #include int main(int argc, char** argv) { if(argc != 2) { fprintf(stderr,"Usage: %s \n",argv[0]); return 1; } char* command = (char *) malloc((strlen("condor_wait ")+strlen(argv[1]))*sizeof(char)); sprintf(command,"condor_wait %s",argv[1]); system(command); return 0; } cctools-4.0-source/allpairs/src.tpds/allpairs_wrapper.sh0000751060042600000500000000375512175446362022446 0ustar btovardip#!/bin/bash # Command Line Input: # $1: FNAME # $2: FUN.exe # $3: Chirp A Directory on this node /chirp/localhost/DIR # $4: Chirp B Directory on this node /chirp/localhost/DIR # $5: Matrix Host # $6: Matrix Path # $7: Matrix Height # $8: Matrix Width # $9: Matrix Y Offset # $10: Matrix X Offset # $11: First B Index (p) # $12: First A Index (q) # $13: Last B Index (r) # $14: Last A Index (s) host=`hostname` chirp="/afs/nd.edu/user37/ccl/software/devel/bin/chirp" parrot="/afs/nd.edu/user37/ccl/software/devel/bin/parrot" mkdir $1 if [ $? -ne 0 ]; then exit 96; fi; cd $1 if [ $? -ne 0 ]; then exit 97; fi; if [ -f ../$1.func.tar ]; then tar xf ../$1.func.tar; if [ $? -ne 0 ]; then exit 98; fi; rm ../$1.func.tar if [ $? -ne 0 ]; then exit 99; fi; if [ ! -f $2 ]; then pwd ls ls .. exit 100 fi; fi echo "Command: ../allpairs_multicore -i $7 -w $8 -Y $9 -X ${10} -p ${11} -q ${12} -r ${13} -s ${14} $3 $4 ./$2 $5 $6" ../allpairs_multicore -i $7 -w $8 -Y $9 -X ${10} -p ${11} -q ${12} -r ${13} -s ${14} $3 $4 ./$2 $5 $6 retval=$? # Uncomment these lines to send output and error text for each job back to the files set up by condor. #HACK to fix a bug with Condor eviction that only appears with Karen's jobs. #OIFS=$IFS #IFS=" #"; #for i in `ps xU cmoretti -o "%p %t %a" | grep karen.exe | grep -v grep`; do # j=`echo ${i} | awk -F: '{sub(/^ */,""); print;}'` # j=${j%% *}; # ps -p $j -o "%t" | grep -q "-" # rv=$? # if((($rv == 0) && ($j != $$))); then # echo "killing off $j on `hostname`: $i" # tcsh -c "kill -HUP $j"; # fi #done #IFS=$OIFS #/HACK! # If we didn't get a 0 return, remove our waste and exit with a status to requeue if [ $retval -ne 0 ]; then #echo "Returned $retval" echo "CLA returned $retval. Cleaning up and exiting" cd ..; echo "Contents of execution directory upon exit:" ls rm -rf $1 rm -rf ./parrotdir #sleep 300 exit $retval fi cd .. # Do some cleanup rm -rf $1 rm -rf ./parrotdir exit $retval cctools-4.0-source/allpairs/src/0000751060042600000500000000000012175446362015555 5ustar btovardipcctools-4.0-source/allpairs/src/.gitignore0000640060042600000500000000015712175446362017550 0ustar btovardipallpairs_master allpairs_multicore allpairs_wait allpairs allpairs_status allpairs_workqueue allpairs_cleanup cctools-4.0-source/allpairs/src/Makefile0000640060042600000500000000137512175446362017223 0ustar btovardipCCTOOLS_HOME = ../../ include ${CCTOOLS_HOME}/Makefile.config include ${CCTOOLS_HOME}/Makefile.rules TARGETS = allpairs_multicore allpairs_master LOCAL_LDFLAGS=../../sand/src/libsandtools.a -lwork_queue -ldttools ${CCTOOLS_INTERNAL_LDFLAGS} all: ${TARGETS} allpairs_multicore: allpairs_multicore.o allpairs_compare.o ${CCTOOLS_HOME}/dttools/src/libdttools.a ${CCTOOLS_LD} -o $@ allpairs_multicore.o allpairs_compare.o -lpthread ${LOCAL_LDFLAGS} allpairs_master: allpairs_master.o allpairs_compare.o ${CCTOOLS_HOME}/dttools/src/libdttools.a ${CCTOOLS_LD} -o $@ allpairs_master.o allpairs_compare.o ${LOCAL_LDFLAGS} test: clean: rm -f core *~ *.o *.a ${TARGETS} install: all mkdir -p ${CCTOOLS_INSTALL_DIR}/bin cp ${TARGETS} ${CCTOOLS_INSTALL_DIR}/bin cctools-4.0-source/allpairs/src/allpairs_compare.c0000640060042600000500000001214312175446362021237 0ustar btovardip/* Copyright (C) 2010- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include #include #include #include #include "allpairs_compare.h" #include "../../sand/src/matrix.h" #include "../../sand/src/align.h" static pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER; /* If you have a custom comparison function, implement it in allpairs_compare_CUSTOM. Arguments data1 and data2 point to the objects to be compared. Arguments size1 and size2 are the length of each object in bytes. When the comparison is complete, output name1, name2, and the result of the comparison. The result may take any form that you find useful. Note that pthread_mutex_lock/unlock is needed around the printf for safety in a multithreaded program. */ static void allpairs_compare_CUSTOM( const char *name1, const char *data1, int size1, const char *name2, const char *data2, int size2 ) { int result = 5; pthread_mutex_lock(&mutex); printf("%s\t%s\t%d\n",name1,name2,result); pthread_mutex_unlock(&mutex); } /* This is a simple bitwise comparison function that just counts up the number of bytes in each object that are different. */ static void allpairs_compare_BITWISE( const char *name1, const char *data1, int size1, const char *name2, const char *data2, int size2 ) { unsigned int i, count = 0; unsigned int minsize; minsize = size1 - size2 ? size2 : size1; count = 0; for(i = 0; i < minsize; i++) { if(data1[i] != data2[i]) { count++; } } pthread_mutex_lock(&mutex); printf("%s\t%s\t%d\n",name1,name2,count); pthread_mutex_unlock(&mutex); } /* This function aligns two DNA sequences using the Smith-Waterman algorithm, and if the quality is sufficiently good, displays the alignment. */ static void allpairs_compare_SWALIGN( const char *name1, const char *data1, int size1, const char *name2, const char *data2, int size2 ) { char *stra = strdup(data1); char *strb = strdup(data2); stra[size1-1] = 0; strb[size2-1] = 0; struct matrix *m = matrix_create(size1-1,size2-1); struct alignment *aln = align_smith_waterman(m,stra,strb); pthread_mutex_lock(&mutex); printf("> %s %s\n",name1,name2); alignment_print(stdout,stra,strb,aln); pthread_mutex_unlock(&mutex); free(stra); free(strb); matrix_delete(m); alignment_delete(aln); } /* This function compares two iris templates in the binary format used by the Computer Vision Research Lab at the University of Notre Dame. */ static void allpairs_compare_IRIS( const char *name1, const char *data1, int size1, const char *name2, const char *data2, int size2 ) { int i, j, count = 0; int size, band, inner, outer, quality; const int power2[8] = { 1, 2, 4, 8, 16, 32, 64, 128 }; // Start processing data in mmap1 sscanf(data1, "%d %d %d %d %d", &size, &band, &inner, &outer, &quality); data1 = strchr(data1, '\n'); // Let data1 points to the start of code data data1++; if(size1 - (data1 - (char *) data1) != size / 8 * 2) { fprintf(stderr, "allpairs_multicore: Image 1 data size error!\n"); exit(1); } int code1[size]; int mask1[size]; count = 0; for(i = 0; i < size / 8; i++) { for(j = 0; j < 8; j++) { if(data1[i] & power2[j]) { code1[count] = 1; count++; } else { code1[count] = 0; count++; } } } // Let data1 now points to the start of mask data data1 += i; count = 0; for(i = 0; i < size / 8; i++) { for(j = 0; j < 8; j++) { if(data1[i] & power2[j]) { mask1[count] = 1; count++; } else { mask1[count] = 0; count++; } } } sscanf(data2, "%d %d %d %d %d", &size, &band, &inner, &outer, &quality); data2 = strchr(data2, '\n'); // Let data2 points to the start of code data data2++; if(size2 - (data2 - (char *) data2) != size / 8 * 2) { fprintf(stderr, "allpairs_multicore: Image 2 data size error!\n"); exit(1); } int code2[size]; int mask2[size]; count = 0; for(i = 0; i < size / 8; i++) { for(j = 0; j < 8; j++) { if(data2[i] & power2[j]) { code2[count] = 1; count++; } else { code2[count] = 0; count++; } } } // Let data1 now points to the start of mask data data2 += i; count = 0; for(i = 0; i < size / 8; i++) { for(j = 0; j < 8; j++) { if(data2[i] & power2[j]) { mask2[count] = 1; count++; } else { mask2[count] = 0; count++; } } } int codes[size]; int masks[size]; int results[size]; int distance = 0; int total = 0; for(i = 0; i < size; i++) { codes[i] = code1[i] ^ code2[i]; masks[i] = mask1[i] & mask2[i]; results[i] = codes[i] & masks[i]; distance = distance + results[i]; total = total + masks[i]; } pthread_mutex_lock(&mutex); printf("%s\t%s\t%lf\n",name1,name2,distance/(double)total); pthread_mutex_unlock(&mutex); } allpairs_compare_t allpairs_compare_function_get( const char *name ) { if(!strcmp(name,"CUSTOM")) { return allpairs_compare_CUSTOM; } else if(!strcmp(name,"BITWISE")) { return allpairs_compare_BITWISE; } else if(!strcmp(name,"SWALIGN")) { return allpairs_compare_SWALIGN; } else if(!strcmp(name,"IRIS")) { return allpairs_compare_IRIS; } else { return 0; } } cctools-4.0-source/allpairs/src/allpairs_compare.h0000640060042600000500000000065412175446362021250 0ustar btovardip/* Copyright (C) 2010- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #ifndef ALLPAIRS_COMPARE_H #define ALLPAIRS_COMPARE_H typedef void (*allpairs_compare_t) ( const char *name1, const char *data1, int size1, const char *name2, const char *data2, int size2 ); allpairs_compare_t allpairs_compare_function_get( const char *name ); #endif cctools-4.0-source/allpairs/src/allpairs_master.c0000640060042600000500000003112612175446362021106 0ustar btovardip/* Copyright (C) 2008- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include #include #include #include #include #include "cctools.h" #include "debug.h" #include "work_queue.h" #include "envtools.h" #include "text_list.h" #include "hash_table.h" #include "stringtools.h" #include "xxmalloc.h" #include "macros.h" #include "envtools.h" #include "fast_popen.h" #include "list.h" #include "timestamp.h" #include "getopt_aux.h" #include "allpairs_compare.h" #define ALLPAIRS_LINE_MAX 4096 static const char *progname = "allpairs_master"; static char allpairs_multicore_program[ALLPAIRS_LINE_MAX] = "allpairs_multicore"; static char allpairs_compare_program[ALLPAIRS_LINE_MAX]; static char *output_filename = NULL; static double compare_program_time = 0.0; static const char * extra_arguments = ""; static int use_external_program = 0; static struct list *extra_files_list = 0; static int xcurrent = 0; static int ycurrent = 0; static int xblock = 0; static int yblock = 0; static int xstop = 0; static int ystop = 0; static void show_help(const char *cmd) { fprintf(stdout, "Usage: %s [options] \n", cmd); fprintf(stdout, "The most common options are:\n"); fprintf(stdout, " %-30s The port that the master will be listening on.\n", "-p,--port="); fprintf(stdout, " %-30s Extra arguments to pass to the comparison function.\n", "-e,--extra-args="); fprintf(stdout, " %-30s Extra input file needed by the comparison function. (may be given multiple times)\n", "-f,--input-file="); fprintf(stdout, " %-30s Write debugging output to this file (default to standard output)\n", "-o,--debug-file="); fprintf(stdout, " %-30s Estimated time to run one comparison. (default chosen at runtime)\n", "-t,--estimated-time="); fprintf(stdout, " %-30s Width of one work unit, in items to compare. (default chosen at runtime)\n", "-x,--width="); fprintf(stdout, " %-30s Height of one work unit, in items to compare. (default chosen at runtime)\n", "-y,--height="); fprintf(stdout, " %-30s Set the project name to \n", "-N,--project-name="); fprintf(stdout, " %-30s Priority. Higher the value, higher the priority.\n", "-P,--priority="); fprintf(stdout, " %-30s Enable debugging for this subsystem. (Try -d all to start.)\n", "-d,--debug="); fprintf(stdout, " %-30s Show program version.\n", "-v,--version"); fprintf(stdout, " %-30s Display this message.\n", "-h,--help"); fprintf(stdout, " %-30s Select port at random and write it to this file.\n", "-Z,--random-port="); } /* Run the comparison program repeatedly until five seconds have elapsed, in order to get a rough measurement of the execution time. No very accurate for embedded functions. */ double estimate_run_time( struct text_list *seta, struct text_list *setb ) { char line[ALLPAIRS_LINE_MAX]; timestamp_t starttime, stoptime; int x,y; fprintf(stdout, "%s: sampling execution time of %s...\n",progname,allpairs_compare_program); starttime = timestamp_get(); for(x=0;x5000000) break; } if(stoptime-starttime>5000000) break; } double t = (double)(stoptime - starttime) / (x * ystop + y + 1) / 1000000; if(t<0.01) t = 0.01; return t; } /* After measuring the function run time, try to choose a squarish work unit that will take just over one minute to complete. */ void estimate_block_size( struct text_list *seta, struct text_list *setb, int *xblock, int *yblock ) { if(compare_program_time==0) { if(use_external_program) { compare_program_time = estimate_run_time(seta,setb); } else { compare_program_time = 0.1; } } fprintf(stdout, "%s: %s estimated at %.02lfs per comparison\n",progname,allpairs_compare_program,compare_program_time); int block_limit = 60; double block_time; *xblock = *yblock = 1; while(1) { block_time = *xblock * *yblock * compare_program_time; if(block_time>block_limit) break; if(*xblock < text_list_size(seta)) (*xblock)++; if(*yblock < text_list_size(setb)) (*yblock)++; if(*xblock==text_list_size(seta) && *yblock==text_list_size(setb)) break; } } /* Convert a text_list object into a single string that we can pass as a buffer to a remote task via work queue. */ char * text_list_string( struct text_list *t, int a, int b ) { static int buffer_size = 128; char *buffer = malloc(buffer_size); int buffer_pos = 0; int i; for(i=a;i= buffer_size) { buffer_size *= 2; buffer = realloc(buffer,buffer_size); } buffer_pos += sprintf(&buffer[buffer_pos],"%s\n",str); } buffer[buffer_pos] = 0; return buffer; } /* Create the next task in order to be submitted to the work queue. Basically, bump the current position in the results matrix by xblock, yblock, and then construct a task with a list of files on each axis, and attach the necessary files. */ struct work_queue_task * ap_task_create( struct text_list *seta, struct text_list *setb ) { int x,y; char *buf, *name; if(xcurrent>=xstop) { xcurrent=0; ycurrent+=yblock; } if(ycurrent>=ystop) return 0; char cmd[ALLPAIRS_LINE_MAX]; sprintf(cmd,"./%s -e \"%s\" A B %s%s",string_basename(allpairs_multicore_program),extra_arguments,use_external_program ? "./" : "",string_basename(allpairs_compare_program)); struct work_queue_task *task = work_queue_task_create(cmd); if(use_external_program) { work_queue_task_specify_file(task,allpairs_compare_program,string_basename(allpairs_compare_program),WORK_QUEUE_INPUT,WORK_QUEUE_CACHE); } work_queue_task_specify_file(task,allpairs_multicore_program,string_basename(allpairs_multicore_program),WORK_QUEUE_INPUT,WORK_QUEUE_CACHE); const char *f; list_first_item(extra_files_list); while((f = list_next_item(extra_files_list))) { work_queue_task_specify_file(task,f,string_basename(f),WORK_QUEUE_INPUT,WORK_QUEUE_CACHE); } buf = text_list_string(seta,xcurrent,xcurrent+xblock); work_queue_task_specify_buffer(task,buf,strlen(buf),"A",WORK_QUEUE_NOCACHE); free(buf); buf = text_list_string(setb,ycurrent,ycurrent+yblock); work_queue_task_specify_buffer(task,buf,strlen(buf),"B",WORK_QUEUE_NOCACHE); free(buf); for(x=xcurrent;x<(xcurrent+xblock);x++) { name = text_list_get(seta,x); if(!name) break; work_queue_task_specify_file(task,name,string_basename(name),WORK_QUEUE_INPUT,WORK_QUEUE_CACHE); } for(y=ycurrent;y<(ycurrent+yblock);y++) { name = text_list_get(setb,y); if(!name) break; work_queue_task_specify_file(task,name,string_basename(name),WORK_QUEUE_INPUT,WORK_QUEUE_CACHE); } /* advance to the next row/column */ xcurrent += xblock; return task; } void task_complete( struct work_queue_task *t ) { FILE *output = stdout; if(output_filename) { output = fopen(output_filename, "a"); if(!output) { fprintf(stderr, "Cannot open %s for writing. Output to stdout instead.\n", output_filename); output = stdout; } } string_chomp(t->output); fprintf(output, "%s\n",t->output); if(output != stdout) fclose(output); work_queue_task_delete(t); } int main(int argc, char **argv) { signed char c; struct work_queue *q; int port = WORK_QUEUE_DEFAULT_PORT; static const char *port_file = NULL; int work_queue_master_mode = WORK_QUEUE_MASTER_MODE_STANDALONE; char *project = NULL; int priority = 0; debug_config("allpairs_master"); extra_files_list = list_create(); struct option long_options[] = { {"debug", required_argument, 0, 'd'}, {"help", no_argument, 0, 'h'}, {"version", no_argument, 0, 'v'}, {"port", required_argument, 0, 'p'}, {"random-port", required_argument, 0, 'Z'}, {"extra-args", required_argument, 0, 'e'}, {"width", required_argument, 0, 'x'}, {"height", required_argument, 0, 'y'}, {"advertise", no_argument, 0, 'a'}, //deprecated, left here for backwards compatibility {"project-name", required_argument, 0, 'N'}, {"debug-file", required_argument, 0, 'o'}, {"input-file", required_argument, 0, 'f'}, {"estimated-time", required_argument, 0, 't'}, {"priority", required_argument, 0, 'P'}, {0,0,0,0} }; while((c = getopt_long(argc, argv, "ad:e:f:hN:p:P:t:vx:y:Z:o:", long_options, NULL)) >= 0) { switch (c) { case 'a': work_queue_master_mode = WORK_QUEUE_MASTER_MODE_CATALOG; break; case 'd': debug_flags_set(optarg); break; case 'e': extra_arguments = optarg; break; case 'f': list_push_head(extra_files_list,optarg); break; case 'o': free(output_filename); output_filename=xxstrdup(optarg); break; case 'h': show_help(progname); exit(0); break; case 'N': work_queue_master_mode = WORK_QUEUE_MASTER_MODE_CATALOG; free(project); project = xxstrdup(optarg); break; case 'p': port = atoi(optarg); break; case 'P': priority = atoi(optarg); break; case 't': compare_program_time = atof(optarg); break; case 'v': cctools_version_print(stdout, progname); exit(0); break; case 'x': xblock = atoi(optarg); break; case 'y': yblock = atoi(optarg); break; case 'Z': port_file = optarg; port = 0; break; default: show_help(progname); return 1; } } cctools_version_debug(D_DEBUG, argv[0]); if((argc - optind) < 3) { show_help(progname); exit(1); } struct text_list *seta = text_list_load(argv[optind]); if(!seta) { fprintf(stderr,"%s: couldn't open %s: %s\n",progname,argv[optind+1],strerror(errno)); return 1; } fprintf(stdout, "%s: %s has %d elements\n",progname,argv[optind],text_list_size(seta)); struct text_list *setb = text_list_load(argv[optind+1]); if(!setb) { fprintf(stderr,"%s: couldn't open %s: %s\n",progname,argv[optind+1],strerror(errno)); return 1; } fprintf(stdout, "%s: %s has %d elements\n",progname,argv[optind+1],text_list_size(setb)); if (!find_executable("allpairs_multicore","PATH",allpairs_multicore_program,sizeof(allpairs_multicore_program))) { fprintf(stderr,"%s: couldn't find allpairs_multicore in path\n",progname); return 1; } debug(D_DEBUG,"using multicore executable %s",allpairs_multicore_program); xstop = text_list_size(seta); ystop = text_list_size(setb); if(allpairs_compare_function_get(argv[optind+2])) { strcpy(allpairs_compare_program,argv[optind+2]); debug(D_DEBUG,"using internal function %s",allpairs_compare_program); use_external_program = 0; } else { if(!find_executable(argv[optind+2],"PATH",allpairs_compare_program,sizeof(allpairs_compare_program))) { fprintf(stderr,"%s: %s is neither an executable nor an internal comparison function.\n",progname,allpairs_compare_program); return 1; } debug(D_DEBUG,"using comparison executable %s",allpairs_compare_program); use_external_program = 1; } if(!xblock || !yblock) { estimate_block_size(seta,setb,&xblock,&yblock); } fprintf(stdout, "%s: using block size of %dx%d\n",progname,xblock,yblock); if(work_queue_master_mode == WORK_QUEUE_MASTER_MODE_CATALOG && !project) { fprintf(stderr, "allpairs: allpairs master running in catalog mode. Please use '-N' option to specify the name of this project.\n"); fprintf(stderr, "allpairs: Run \"%s -h\" for help with options.\n", argv[0]); return 1; } q = work_queue_create(port); //Read the port the queue is actually running, in case we just called //work_queue_create(LINK_PORT_ANY) port = work_queue_port(q); if(!q) { fprintf(stderr,"%s: could not create work queue on port %d: %s\n",progname,port,strerror(errno)); return 1; } if(port_file) opts_write_port_file(port_file, port); // advanced work queue options work_queue_specify_master_mode(q, work_queue_master_mode); work_queue_specify_name(q, project); work_queue_specify_priority(q, priority); fprintf(stdout, "%s: listening for workers on port %d...\n",progname,work_queue_port(q)); while(1) { struct work_queue_task *task = NULL; while(work_queue_hungry(q)) { task = ap_task_create(seta,setb); if(task) { work_queue_submit(q, task); } else { break; } } if(!task && work_queue_empty(q)) break; task = work_queue_wait(q,5); if(task) task_complete(task); } work_queue_delete(q); return 0; } cctools-4.0-source/allpairs/src/allpairs_multicore.c0000640060042600000500000002161312175446362021616 0ustar btovardip/* Copyright (C) 2009- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include #include #include #include #include #include #include #include #include #include "allpairs_compare.h" #include "cctools.h" #include "debug.h" #include "stringtools.h" #include "xxmalloc.h" #include "fast_popen.h" #include "text_list.h" #include "memory_info.h" #include "load_average.h" #include "macros.h" #include "full_io.h" #include "getopt_aux.h" static const char *progname = "allpairs_multicore"; static const char *extra_arguments = ""; static int block_size = 0; static int num_cores = 0; static void show_help(const char *cmd) { fprintf(stdout, "Usage: %s [options] \n", cmd); fprintf(stdout, "where options are:\n"); fprintf(stdout, " %-30s Block size: number of items to hold in memory at once. (default: 50%% of RAM\n", "-b,--block-size="); fprintf(stdout, " %-30s Number of cores to be used. (default: # of cores in machine)\n", "-c,--cores="); fprintf(stdout, " %-30s Extra arguments to pass to the comparison program.\n", "-e,--extra-args="); fprintf(stdout, " %-30s Enable debugging for this subsystem.\n", "-d,--debug="); fprintf(stdout, " %-30s Show program version.\n", "-v,--version"); fprintf(stdout, " %-30s Display this message.\n", "-h,--help"); } static int get_file_size( const char *path ) { struct stat info; if(stat(path,&info)==0) { return info.st_size; } else { return 0; } } /* block_size_estimate computes how many items we can effectively get in memory at once by measuring the first 100 elements of the set, and then choosing a number to fit within 1/2 of the available RAM. */ int block_size_estimate( struct text_list *seta ) { int count = MIN(100,text_list_size(seta)); int i; UINT64_T total_data = 0,free_mem,total_mem; int block_size; memory_info_get(&free_mem, &total_mem); for(i=0;i=total_mem) { block_size = text_list_size(seta) * total_mem / total_data; if(block_size<1) block_size = 1; if(block_size>text_list_size(seta)) block_size = text_list_size(seta); } else { block_size = text_list_size(seta); } return block_size; } /* Load the named file into memory, returning the actual data of the file, and filling length with the length of the buffer in bytes. The result should be free()d when done. */ char * load_one_file( const char *filename, int *length ) { FILE *file = fopen(filename,"r"); if(!file) { fprintf(stderr,"%s: couldn't open %s: %s\n",progname,filename,strerror(errno)); exit(1); } fseek(file,0,SEEK_END); *length = ftell(file); fseek(file,0,SEEK_SET); char *data = malloc(*length); if(!data) { fprintf(stderr,"%s: out of memory!\n",progname); exit(1); } full_fread(file,data,*length); fclose(file); return data; } /* pthreads requires that we pass all arguments through as a single pointer, so we are forced to use a little structure to send all of the desired arguments. */ struct thread_args { allpairs_compare_t func; char **xname; char **xdata; int *xdata_length; char *yname; char *ydata; int ydata_length; }; /* A single thread will loop over a whole block-row of the results, calling the comparison function once for each pair of items. */ static void * row_loop_threaded( void *args ) { int i; struct thread_args *targs = args; for(i=0;ifunc(targs->xname[i],targs->xdata[i],targs->xdata_length[i],targs->yname,targs->ydata,targs->ydata_length); } return 0; } /* The threaded main loop loads an entire block of objects into memory, then forks threads, one for each row in the block, until done. This only applies to functions loaded via dynamic linking. Up to num_cores threads will be running simultaneously. */ static int main_loop_threaded( allpairs_compare_t funcptr, struct text_list *seta, struct text_list *setb ) { int x,i,j,c; char *xname[block_size]; char *xdata[block_size]; int xdata_length[block_size]; char *yname[num_cores]; char *ydata[num_cores]; int ydata_length[num_cores]; struct thread_args args[num_cores]; pthread_t thread[num_cores]; /* for each block sized vertical stripe... */ for(x=0;x -1) { switch (c) { case 'b': block_size = atoi(optarg); break; case 'c': num_cores = atoi(optarg); break; case 'e': extra_arguments = optarg; break; case 'd': debug_flags_set(optarg); break; case 'v': cctools_version_print(stdout, progname); exit(0); break; default: case 'h': show_help(progname); exit(0); break; } } cctools_version_debug(D_DEBUG, argv[0]); if((argc - optind) < 3) { show_help(progname); exit(1); } const char * setapath = argv[optind]; const char * setbpath = argv[optind+1]; const char * funcpath = argv[optind+2]; struct text_list *seta = text_list_load(setapath); if(!seta) { fprintf(stderr, "allpairs_multicore: cannot open %s: %s\n",setapath,strerror(errno)); exit(1); } struct text_list *setb = text_list_load(setbpath); if(!setb) { fprintf(stderr, "allpairs_multicore: cannot open %s: %s\n",setbpath,strerror(errno)); exit(1); } if(num_cores==0) num_cores = load_average_get_cpus(); debug(D_DEBUG,"num_cores: %d\n",num_cores); if(block_size==0) block_size = block_size_estimate(seta); debug(D_DEBUG,"block_size: %d elements",block_size); allpairs_compare_t funcptr = allpairs_compare_function_get(funcpath); if(funcptr) { result = main_loop_threaded(funcptr,seta,setb); } else { if(access(funcpath,X_OK)!=0) { fprintf(stderr, "%s: %s is neither an executable program nor an internal function.\n",progname,funcpath); return 1; } result = main_loop_program(funcpath,seta,setb); } return result; } cctools-4.0-source/allpairs/test/0000751060042600000500000000000012175446362015745 5ustar btovardipcctools-4.0-source/allpairs/test/Makefile0000640060042600000500000000032712175446362017407 0ustar btovardipCCTOOLS_HOME = ../.. include ${CCTOOLS_HOME}/Makefile.config include ${CCTOOLS_HOME}/Makefile.rules all: test: @echo running allpairs tests @${CCTOOLS_HOME}/dttools/src/test_runner.sh TR_*.sh clean: install: cctools-4.0-source/allpairs/test/README0000640060042600000500000000056112175446362016627 0ustar btovardipTR_allpairs_composite.sh Computes the list of composite numbers by brute force. We form the pairs of all numbers from 2 to 50, and check if the first one is properly divisible by the second one. TR_allpairs_bitwise.sh Compare the source of allpairs with the hard coded BITWISE function. This test could be better, since we only count the number of lines generated. cctools-4.0-source/allpairs/test/TR_allpairs_bitwise.sh0000751060042600000500000000245312175446362022252 0ustar btovardip#!/bin/sh . ../../dttools/src/test_runner.common.sh TEST_INPUT="./set.list" TEST_OUTPUT=bitwise.output PIDMASTER_FILE=allpairs.pid PIDWORKER_FILE=worker.pid PORT_FILE=WORKER.PORT prepare() { rm -f $TEST_OUTPUT rm -f $PIDMASTER_FILE rm -f $PIDWORKER_FILE rm -f $PORT_FILE ln -s ../src/allpairs_multicore . (PATH=.:$PATH ../src/allpairs_master -x 1 -y 1 -o $TEST_OUTPUT -Z $PORT_FILE $TEST_INPUT $TEST_INPUT BITWISE )& pid=$! echo $pid > $PIDMASTER_FILE wait_for_file_creation $PORT_FILE 5 exit 0 } run() { ../../work_queue/src/work_queue_worker localhost `cat $PORT_FILE` & pid=$! echo $pid > $PIDWORKER_FILE wait_for_file_creation $TEST_OUTPUT 5 wait_for_file_modification $TEST_OUTPUT 3 in_files=`cat "$TEST_INPUT" | awk -F"/" '{print $3}'` howmany() { echo $#;} num_files=$(howmany $in_files) for i in $in_files; do count=`awk '{print $1}' $TEST_OUTPUT | grep -c $i` if [[ $num_files != $count ]]; then exit 1 fi count=`awk '{print $2}' $TEST_OUTPUT | grep -c $i` if [[ $num_files != $count ]]; then exit 1 fi done exit 0 } clean() { kill -9 `cat $PIDMASTER_FILE` kill -9 `cat $PIDWORKER_FILE` rm -f $TEST_OUTPUT rm -f $PIDMASTER_FILE rm -f $PIDWORKER_FILE rm -f $PORT_FILE rm -f allpairs_multicore exit 0 } dispatch $@ cctools-4.0-source/allpairs/test/TR_allpairs_composite.sh0000751060042600000500000000242612175446362022606 0ustar btovardip#!/bin/sh . ../../dttools/src/test_runner.common.sh TEST_INPUT=integer.list TEST_OUTPUT_STEP=composite_step.output TEST_OUTPUT=composite.output TEST_TRUTH=composites.txt PIDMASTER_FILE=allpairs.pid PIDWORKER_FILE=worker.pid PORT_FILE=worker.port prepare() { rm -f $TEST_INPUT rm -f $TEST_OUTPUT_STEP rm -f $TEST_OUTPUT rm -f $PIDMASTER_FILE rm -f $PIDWORKER_FILE rm -f $PORT_FILE ./gen_ints.sh $TEST_INPUT 20 ln -s ../src/allpairs_multicore . (PATH=.:$PATH ../src/allpairs_master -x 1 -y 1 -o $TEST_OUTPUT_STEP -Z $PORT_FILE $TEST_INPUT $TEST_INPUT ./divisible.sh )& pid=$! echo $pid > $PIDMASTER_FILE wait_for_file_creation $PORT_FILE 5 exit 0 } run() { ../../work_queue/src/work_queue_worker localhost `cat $PORT_FILE` & pid=$! echo $pid > $PIDWORKER_FILE wait_for_file_creation $TEST_OUTPUT_STEP 5 wait_for_file_modification $TEST_OUTPUT_STEP 3 awk '$3 ~ /^0$/{print $1}' $TEST_OUTPUT_STEP | sort -n | uniq > $TEST_OUTPUT diff $TEST_TRUTH $TEST_OUTPUT exit $? } clean() { kill -9 `cat $PIDMASTER_FILE` kill -9 `cat $PIDWORKER_FILE` xargs rm < $TEST_INPUT rm -f $TEST_INPUT rm -f $TEST_OUTPUT_STEP rm -f $TEST_OUTPUT rm -f $PIDMASTER_FILE rm -f $PIDWORKER_FILE rm -f $PORT_FILE rm -f allpairs_multicore exit 0 } dispatch $@ cctools-4.0-source/allpairs/test/composites.txt0000640060042600000500000000003212175446362020666 0ustar btovardip4 6 8 9 10 12 14 15 16 18 cctools-4.0-source/allpairs/test/divisible.sh0000751060042600000500000000016212175446362020255 0ustar btovardip#!/bin/sh # is $1 properly divisible by $2? if [ $1 -gt $2 ]; then echo $(( $1 % $2)) else echo $1 fi exit 0 cctools-4.0-source/allpairs/test/gen_ints.sh0000751060042600000500000000024612175446362020114 0ustar btovardip#! /bin/sh filename=${1:-integer.list} N=${2:-50} rm -f $filename touch $filename I=2 while [ $I -lt $N ]; do echo $I > $I echo $I >> $filename ((I++)) done cctools-4.0-source/allpairs/test/lc_compare.sh0000751060042600000500000000016712175446362020414 0ustar btovardip#!/bin/sh lc_a=$(wc -l "$1" | awk '{print $1}') lc_b=$(wc -l "$2" | awk '{print $1}') echo $(($lc_a - $lc_b)) exit 0 cctools-4.0-source/allpairs/test/set.list0000640060042600000500000000011712175446362017434 0ustar btovardip../src/allpairs_compare.c ../src/allpairs_master.c ../src/allpairs_multicore.c cctools-4.0-source/apps/0000751060042600000500000000000012175446362014122 5ustar btovardipcctools-4.0-source/apps/Makefile0000640060042600000500000000027412175446362015565 0ustar btovardipinclude ../Makefile.config include ../Makefile.rules all test install clean: @for p in replica_exchange_protomol; do cd $$p && $(MAKE) $@ && cd .. ; done .PHONY: all test install clean cctools-4.0-source/apps/atlas/0000751060042600000500000000000012175446362015226 5ustar btovardipcctools-4.0-source/apps/atlas/PhysicsAnalysis.tar.gz0000640060042600000500000006643112175446362021515 0ustar btovardip‹ÂÚQì¦tPŽ<¢¤iggS)V h’°A€‹CǤ¼¿}ß{Ýh4.R”-ÍV­Q‰Et¿~ýî~}ábq:V¸ïq~„íïáéÀó¢ßÿ®³×íô÷:ôÞé«¿òù®Ûëîí=ïw_<‡òî±þc“â0âcßÙÑ‚;^5œí¬ž‚œ§~.rúO~úË¥ï}sØ^ÿý{Ï¿éÿ)ž úŠà‹cÃ=õÿÓOýçÝüîô:{ý½oúŠgý‡õ Ø^ÿÝîóÞ7ý?ų­þ-¹ò=áE[„ƒíõ¿·×{ñMÿOñ|þͺ)”Ž[Öím¡Múµ§ãÿ9ÀuzPÄ:O!€ÿçúÿ«ãYnl VϨ:ù1þ$\ù^kQ¯U€^ îñˆ› ì[ÛÎßEà ·}$,—â˜[‘Ü •É üÑððtÿr8Ý?}{~y2ùu4=Þ?œœ_þ£Áò¤°uÐyjZƒ+ éðlry27˜ÉÛaÖ+ .% ®¤ëϵڿZÁž¯åÿ®ÏíRçÿn³ÿƒïgý¿÷¢ßùæÿOò”;ê)h³è¥§çûG'2­`§öýÿu{ÿödŸmý¿00Tø¼ù¬õÿ.ä|Ïû9ÿïcøÍÿŸàiõ‡Õð=¬†ÊP¨”»¡Ïf~Àl'„°rGÂf<·|¹rE(ÄÑÂìï"×Ûo±ý0äK>çÕÁÙi“½‹Ý;Öë5ØËs,¦ª£áøðòäbrr~6Ð…“ôéG2øÁ½´Û„B¶ @‚Å`ò̉YÂPÇP¢ÁáEÆÊ`y{¢HÓçZ|bïÀÄ ›¬ëv¦ÛIÉ›9®` ²+!<G$¼ÚKßvf+„x-˜9à}ì$bžÃÂ…²;?fðƒE>ã–%B)Iô|8H~©Ú]bÅzaþŒùW……M&ZóüëÂ[à{P°ŒéÏGAµ‘µ„U“¹ŠÃæÏfÐô Ͱñ>rÜ­¸õ‰Ï…¡à‡qÅ)íÂöEÈük¸|űô¯¹«á/\ÁCÁB-¢hÚíèÆùä´,±ZÖB¾µ¯¯}툛ö~ª¾üv;æ~óƒO¾ÿiÿü()ºn·ÿ×ß'r¼ù$Lýoš¨}JĒ銈#Gp9¢´á7‘×í'?ÅS«=BOU¹û(œ#0»ev*`‚ì»s•4TÜL|ß_[¹YÂZ‰·<mý«4¼g<+në_ÙŽòG„Às¾\rªl•ú(ÔAWt4·Z!_€G-Ä,Ì>² &r,WHèIÁ-)Êôo4úpûA‘¸m¸­ 1ÁøÀ»Jñ¥À‡ÜõeïøëÐ…qOU}£ÓKàQ|/ ],ü¨0â±â›ÇïDT5Š@\ÔŽ“ŸxŽœà|8QÄ%¯9òÏøõ18ðÈ_¶O6ˆÅ…ßΜ_¹â9¼þx™¥£Ò¤…ÑL™k 2™Bätpúëð¢ýA @Ž@ÿ”o9ô ‚ Ÿ“%“­$¦n¢‡¨ói'âЧڇ˜¿¼ üx•ƒÜ8±Ïa5ÌÊ™ƒÊÖ*ó!š6¡Žd4½d÷bïBAW] «&a{"ÇBmhÓËó“{@—€»‹0ãHˆPy¶3¿ô#Z³RŠÝªA•éoÖ ¦^N ½‚†J€x¬¢AòÄ;J¼R¿R°©rŒWÜû0†.–oŒBH:­…Y2‹=jÍ]³ÔñCbÞÔj•«"xa™A ^É–ÿÅ^³_º­î/ÏÞŠ/³0{06ÚÿÏéÅþåääðt8à^çe­cŒ`_в¡SÓ—…°ž—1¦Ò¸ ÿ³C$5ˆÑãkµ¼+ù’†d-ŒìÁóeoþïDm“@¸9õ-ˆž±Uú²Ã5ÆÎ&Ó}HÄ<¾Ãq¹IC64a›ºÔ‘°a8¾×Yj,”Þ±º‘ .™ºBK#ã,i›«-´>—yááBXŸ@%J ª°\Ê䲉 qD2à6¤g …œ/Ð-m_“è^¨BÇ»aãM$(r7êÃã)„²îOÎÔõýPL{{{õÚŸ5€o?{ÆÂ'²#C †¹‹Kɶž™D ˆþóûè_1…¢ Ù³66·åÂ+äÃ+È)î Zn²ì“³ ¶ór-’¬â›$™ú ¸ò†ÐÌáÊÕoÀVfÍõfu?Œ¦…4×›X‚¹4³PöÖHPr䣶“y3סƒ’ê…—8ùÒ3ˆ ¯50ÌˆÒØ˜Yæ4ŸÍâŽJóZìbq}¼²ÜÑa½TifwN3Ñzs9]f‹$£ádz)fLj[1޾~`ÅQ“k[ÌxìF ¤ ,©]‰t 3ðÍR?nÄ/G<î0Žˆ;;SuZ½ fø­lOí–É5ùž”nnÛƒ’zœ_ê¹7’¶F­Ã(! †h(“4u;­ŽŽå„¥myÚ˜§­{­þú† T¡Í_$O% ¹)G ¾ˆE|>ÇѶœ)ù-šž\ì?tÚT©³Ú³Ãë®$ñ§ry1›ª÷u|)°\+%ʾ¥bNY$NLóYgÍ„Ø0exÝëäñRì†ö#÷˜Ã€_Žô$Tõ¸É„X³àuý˜»¡H|¢­‘ŽèÀ󣿕ڹO DgËŸ9D@žåÇ\yñòJ¸X„kA £ â Hœξ†ê¿ÿr˜ ‰*ùŒãðRÓ‘–H‚7 @ôýœ€’%¬•ÄPø(j¥Ç&oD!Â2Á¤Ö+¢Ñ2KÕ”çP…7£Pº0íCy¨riì7 ÇZ`ÌY˜’RŽ ã¼Vtu’˨§|rYøñu¤£Ï”±Ê¥T‘ä« \ GI¯Ø·àŽq×ÅLÒQ‹»6&­˜ŽÜpacôBðUYæû?…Ôw‡ýùHœ±'„)î:ÿ”k¹Ž~ezŠ*æº8[pÏãQL¤ &GvåûŸx[äϾ k5´ ¦µ¶(씟§]0¹4têû«†Ü‰Ö nlyêÏ Ó0äs1Áµc‰ÆN“¦,ÝØ«Wl4~; Þ¿Å·ºæãVa'»qE]3}CÖ¹Ú©c+áÙøï$w¯Sß±UâAüKO;T#­Ã‚BŒâš9øI{mêF-aó4 HƇK€¢$«@ÿs§§0v_ÝAç+ ðHI„ÐÜvhAüH߃ñûÃÃáxLÜ83Ö0ã‚Úô‡‡šé¤«•ðÜ §eªehµœð˜;nàU[–“þðòòü’¤Ƚ"²¡Ô‚ŠÓCâ„ì3ä¡`{…jßú[¢­áÿRØ©ù“Št|åab¦€MÂÒ(‚"0†äõ›qSéÑa CÙEb˜þÓ¯Ýdü$ã€~hŽ{Mka¯Œùî›Á€æÀSèÁI+s"d:o8‘V™ŽÊ­+4ÐTþ¥X ò€:Àñã;5#ÏÆè}A¼ÿþ̉þÀ¤†ìÌ <ÐûËÚg¶S“?|FÌlÜš¥Q)5‹P»5äkB«ywRžÖ¨›‹ó4P…Iù :IÖG´Dû#ß«ñÙOãÍÊwÐ ±,Óq¶eÆÆ …Iƒ'¾W×1 3õÍE‚Ò0 =u‹(í¼è¬yNÖð±’3â€ÆÙMLe¦âÎ\˜ôFä܋˽¹éþ£S¼2öEJsɢ£Óì›ZªÓ/%ÞX¿x2ÚÕžïýI/:ég“r{èÀNs²% E2岡-ÙÄ‘™þB¾ÿ={”ã_t\‹–ñðËîúSkt\%=·¶ùüÇL!~À.Ƥ“6ŒóIz£h–ç NÏ–8ðÉÙñ9ùïx²?aÉY§±n‚.AÞ«5BÐxnÏ…[+9–€çn¶:¬óŽè¬çNÛQÓáéÛDû3'’œ%ì–ö!€Fþtqh(j›’ªÿÛNN2Ÿ7Xó#Ò”wŠ\Áét&ýE+DC¾Âã[›í•)c%ÇùÉ‹C»tsHm¥KïMö_åñ(c_u÷“–®¢’B½cjÔéJÚŸ|m N6¿ »]ÐL§•VÑžbY·TQ^.7Ó:u6(Û²­jÒ‘Û8Õ‡ÃÌ-H¢Ñ Pm.Òéø´teE'÷5Bƒ˜d¿. ¯·ØJ8L÷ëÖUÊm)Sü¹.GqI—¸V…Uo[U¬¡)Ý*«†P;\Y›1d•ÙÂÊIÜܘbeuj¿)©“ƒs*¹·dZƒÜ&z½ÛÍõ¨hÓ¨ö(7öÑq‡·ÂŠ#Ð ¶Ës¶[ÐûŒ[B6а¥Cã?ÒkùÙ“ÕIþÀbæ¼az+"RŸµPŸ´À“>t\Q-1S’'ó.ãÚ‘3¬äöQ¨,q¹ÓÁ+Ýàw+p™[ÝÆ¤ØxS"ÝEPx!ùºÂ$q‰7Âñ; “ÆOmÜpñÃ,ôÙ‰,¤—&ü¿òh3>He‚ÚØãh{Tºæƒç„ðV…‹‹“,öf𠺓Çb’S¸K-|¯vØNhÅ4ò9òÌÓ¡¿\Åô=Š?øDçÑw"\âøðŽ[Q‹õ~ù¡ósMeô‰ yCߦÞ5Ù±¸bÝŸÔWJÌä@’Ô„æ) oéé}™/¬9:•µ“ßö/ÏNΤ¥àu7ÅhoÉÜCá[çwXÿ9™‘à-%o­8Kî&™µšK”¦ñt¤ªòè8 @¥ _›ÿÚ/c¿*‘ÂD‡2J3›ÑÁd<ÅIƒ‘3Qj兀ˆ& ª¾SH„R'¢õg¥ç+›L^ü¹»X¿«OÂüˆ£‰«c}ð-´f›ËJÀ»}ÔOžË)•Æ”?Y¨HŽ*š|:ã®|†úôÄm¤´Ñ’éÿnè£57xž¦ŒrzIÆÞÎ÷2Yø!²Â\OÞkÀ4 ¿6”¸pbÔYÈ\Ž‹PÀº¤Ì¬äTì=eVZšþH“ù5 c²0V4±õ¦&¢ùÎ|˜CÝ C%ÜÜÐg~l[^â0¾†àwìcÊ`¯dPøÄ»ÙLà3Œ`‰1› £ô– EÕÚØD6Þ~£8ªÆÁŒË±Ô`‰GBÃÝì¾M$'ñ*ÎBü‡8«0&*s@Jh'êð‹B`3Ssõqü¼GªÇ­Õ¨`‘Â,Ƈ+ÑÅñƒGÙ«›Æ¤iPþ*—K•Áëpd:q‹¸²œno±« ºí™d¦è…Ö(Ã_VKz0¡½’ô2ÊkßkÚåe}:•_Þ‰= “£q]6È,­mbIó!)3a§0cYüuøÈõõ@ºÿuIs2”«ÑæÐœ’.ÌœuB\̧±©¼ÒDVŽ|F^vö†|»8¦o›rç“l=ŽË‹<ò\ÉOöZßJ!Oî±ÒÂIˆF(¸µ`.4uiE%½ÅGØÊ}Óõ¼×ÝR»Ñ„vÙ ­©²ha’V O¡÷ó™RfÞ›+0ö˜\0Ê`ì}Æáq Æáñ=0&—êBúb ™öèŒigPS—²UÁï$ì?šìw˜…È+óì0ºhG&Hù8Ê=ùœæ1e%R˜D£wÅe¢ÅL.Pª^Rh! N\ÙGƒâ^Ô—WÄe|téDÜ\¯µj-©A¼Š¶¶0°ñ>HÓ±w ýﴣ庼ëµw¬j÷ÕfðÓ±ƒ'l|·DW5Ø¢©ò¾¤xôOtØ«"‰ù©é›GµX‹ø"ÛÚD°Sßw2Ò(ðlQJùß±ßÑ… ÿ{â)2þ{üÄi£à»ö­ÿ½~3¾É_ógüñ¡‹KN ò¿¿(ØÅsÜi‹#4úSؽª‘`öè#Û¶Ú\† Ø"ÔêãPSý²‹Š–’QãQÝÉ[CðØÅÓòɇتî(b©9¦X|IŸ¿âï’\~û-¾3‰!4°LÞÎÛb¾D°¸WPG à—ìhÏ:e‡ƒ. Nìä Ãd8¸€L8ðûapb»_Ã;ö~¥Æ§N)еÆuŒ¢Îزr‡%ƒ“00úX†ï"3¾ ï »A|ˆçhàä >ºõ[\EíÌŽ ¡»#üKY:ᥪŸr‹°‰JlŸRöÑ .2äšÛÆ÷‹K_€D³µÀ§‰S8C#µ¬¾“t©_Ù¬ÝÀ»^ã¹,âï YÇÚ÷Žä" @Ùm"ʂ™NJ픲 h!Ø Ò›¥4V7N/¼j< ˜ÛÏtÑíÂ*àpÉ8×»At³hVþö° Y|Li¹™Ìá³BzO}r)$%nH®9PóƒpÎN ñKm%faȼœ{V{óI0 ‡¸ór·ž*õ€GpKí;ÙH޽+o< Rξ“õ…‡´ŠÊO±ç¤[|HÝ~ óÚ:ê=†H´HÛµ»5MØ`zû@xw9ðàíá=¿{žÞ>„²c¦î³ÈŽ j Ù)/Ó=Êߢ¦Äi =¦°bŽ ZÆvæ#©”ð諾êîOZ•\zƒä¾ïû:#ÖBõ¨5&Ga°’§IêPìl,H¼±L`4%;æ»q'½Óã×3;gŽm$‘|;Y¬ TÙfWé#av¤2rr÷PÃ2Ô%¡9§¥DÃrsN-Fw¥m2ˆ|ƒ—(YwµdÍÿÍ=Ò¦rAà¡PØC%€¡3mºˆ^§åÎÈ‚ŽK&Àì!yo ™5:(>9‘ä‘Îï.r `xÑ'Ù¿·2­´Á>ê#²øßÿ%­3óx“AêF!e@æå>qÀ{t!!<ôȳ½UÕ(¨˜Ó—d!ØÍ,#"¯¹½äœ*Š™lêŠX…Ë Ã!+ÒÓýD ‘È×L»ÌµzðÎ^¬ŒY²HyäóJaÛP.g*J"­ðÿ&ØÐ󅌴9ê£ZäXFNo¹›fu¶µn¦…¢8£¸¿Ž÷EÿCi‡+vO÷+\ö¤I‚’I¥b/yI–µ.ÂêP"R YfÂÛFðQtŽ“! “ZãÙ¿ ¡_%M5I2(ÚI@Î…1 –™U=ד®ÐNK#”š8hœ-x‚s>¢óÙÕÈ÷ïÅ™¨´ ij:Œåa-€ýˆöòÔCmÊ\%;¼ÃDÿ©$Ú'M¯ ϪeG(p”åÉZ±LeP<÷²`aš‹ñ“®šyÀ”çvíá3}°{xôÓY[YHîÒÌX‰Èœk50H“ÈoÇ“DYöÔæuIÞ {ŸW”5> ®Ó¶hOz]U·ÒÒˆ—Œw1­ch¯"z¹Lž™NdÄ\„t‡Bšæ†b¸4€¶ €EÞJEk•U+_mëò(Ë¿µPL¶ÍÃ! ïÕ(Œ13¨a®ŒÜÅ pÂ{^Ô2ƒEÎW7†¥6U;K¢,Iž£\d[,.+ª;ürÑÈ5èb”î­-ΕªÆÁ°=_I@°ÀMH¤ý%ë0:d‰fÑŒ\Éê/¼CL:O×k†‰­D;‰$¯3 ®C()L¾cÙÒt¬•Åívs|Ó´7¦$½¸tº3P5ÊI-¿,âk7›Ùa']ŠùjÕÌIS~½ô¾ÇϽ#™‡ Éàö¸ûÙуfl‘± z”1²2ý™6IͰ=l±™&ø›o2s°“šs-ÁŽãÅb™û•¼ØNجäiÝâ8ír´©L(íê ß™1Ð+)À+¢ò䉄G£°bözÅîNïú°g*?qÁ'íÛæf,ØTæO¢gIüÝü)¶ìQ7 æE³’kÙŽoeTOÅ·`ÕÏÜn dãD‡MTsô\iúr€ÊËT®¨dplX"Ñ(e€‘»&@,S«þxOç²^ Kÿ¢iûåeêè)—pèF)šF”¨žÊï_Ú02>¤ÉÖå ¼IÑß*Ö¿á*òùá,×SE9X5PË8ö˜”ë03ËÄ Þ ß)'ffl VXzÒÑ«“8 äÐâº2‡&ãæºì‘„Î3šç$S"×:û®ÂN¤¶ÔØš% ­{ã ®å)Ô–aÊ æ¥Îg,]žµ~_u 5áÄœÊEOµÅŽ­€ºðs)¬/ Eš…¢§Ä8ÒÀ–r¶Ã«W |½æˆacDØ­ÄŽ´†$'jÂ”Û Vk3ok¡#^^ ‡„Lä—”³žu9 ­mg|§›õ;Æ>älì)‘;Y0ŠL—dô\´ÎHäy 3`ÀªP´}’ÕD¿¿·¿ªAX2†%œÇ¦ŸÏÖ8µ’5J Õ¬&þ cævõB»` º­ Ù˜q7 Æ |•lâ4œg;v\Ù¸¤.µWÞæQ9U@ïrZ1Ó„)ã2EVªykzðKé顿 ¦F*?5ܙϞ3õ”H|í)銦ƒ2Î`¯qÄ}áȱ1.á?\'-^qŠH™UÑz‘Ôë+¬,?sÉ«5¸¤ÝÜ3ÄÜ:`4(=¬=“s&fËÐÙ’7ýƒ`P ŒQT:÷HAüg0"K%o¥²g(¶Sç  WFÑœÎgÒ—H¡ôÅ™vºaÝ&A7‡x"ÛÍöwç%舊›Çxó†Ï®‘á¾Y€Z_[ìJN]R9bŸÁ¼¤R~Œ¬•³PŠ•4•ß>C“A§ùcÉ$(ŠŽŽÂÀžÙå1À?>çj& Ãçtk¬ÆÁŽÀ0[Mƒ ;- ê˜½ùF}ŽX…oÂÑÀúíúÞk?è~L^Å^ß…>õ‡2.£Ü·ª¥e!†îmœ{̧›wЧ*ê–ÎóDîäU$릩ÄWÛZ"P¸#¯ÆO@4ñÍÅáþâ’ú›sÆ*Õ ÷-¿<|K•Ö=ϯ€Ÿ/.ñ»ª Ç%¿~†®ÃwU¡`æ’†iÊôÏ$a¥–QI!Ýê#¿Gš#‘lžâ¸„XëË)&“mn†¡øÓè%ŠòbŠh¶Fùã óÄ˪ŠMòÉõ®odZrV\~‰žŽÝùI|“+À㵊hÒoèqsGPJE»0ÂêÖ€ê²ÿ\?Ñ`Ú@Rûº}pzÖVÑðÅ™ê%×öK †ðºô9=‹LŸ‚Qþ§î.ØWi,ƒÇ ˜6™ ”`•cñ6âY3 Ž™,Š2r†r¼à”Ï ¨‰#jÊ9%u C–qRÕ£îÖ„ñ6FвÇo"{ÈDH{ò÷/|º¹½ò[ì×ÿ6ØÏqx ¦éõa¨Ë€iœ,˜´òØhô«m³.¹ÏéZpþÞqë×wd5(†k‹‹ËFÁêÎð¨XåÉ“'é÷÷ïÍï&—íyÉuäµêp­6ŒÜQ/8s†^ÏCg Üàƒî&©ƒ¾fuŠk^èSü¯ªÙJN£V|ºè’‘s W¨x“ b$Æ“%®ƒ¦Óäƒ?h¸eVU ¹l2‰#5”Æíß#'ÚÌ-±¥½4ž‰)8,w$÷ÊÆ¤Ž›ZÆ–ÀeŒ‚*='vV(ñºG§Øj³QaýƒÈ‘V-ºú6ûƒîâ¢ÑujQ¨Â6³‡ßÎ}#{·xåN,Q½„öåÌÐõ{’såÂ+ç2Êlº³6rÑ&ÖqÚ^_ÊðÙ•¡F=  ‘`4ŸupI“H̱$U†T!KǦ¦ )PeÀâe€Ÿe¸B'‰2” æQù>Cäû eà÷”A¦Ë˜†0dªLEf½lå²+"5Üù©IM±±ûmÑš‡R›ééÇ•7Ð[-‚¤iˆtš„HÜë•A5)VZê%+Øö·ßÒÂ! ØõSTr no ‚%—§(ùC[ž ×—ô¤¼r¦RAñ#W‘ž’2´C/Ñ)Ï0ÒXN®#\^Xö‚ê屯jµªÏ q8.F)’¤’Ë’ Y™7scf8x°pRß]ƒHÿI_PmÖjô»´½“m‡gzç?¾Ê©°ƒù[äߪ Ü%aEŒ÷¶„^ÝÐTíˆ2ÈùµýG, ø]ûìõéy;uÖ'DÝ>í|њȈÝlø¤eR}͆ÛÛ ¯¬å2S;yÝ’TÙ+®²VP¥S\¥¹n¬vûëËÏR<–<Í×ÍÛ}Õ¿ð¢ÝØ?p¢x$@5Ø_­3Âm•éþuQΡ½¬~K¸àrÂ_—ŒM|j9= Ôœëá‘2I¾Å²{º¿ •u¿)q„RbE4Dj0ÐÈøNk9SU¶Ä½Q"Î-Á,*1ýäX`S'`•\Á*Ñ Ï lž1º¶a=\,61¿âVòPN…½Í‹!1qf%©ŒQéÙÈ]uǸáõ½a_ÑÈHÞ®P3¨%ŸîÍO±õ)–Ÿ*‰Éz‚ýiæœ:Þı”ÏŠÌ„™ý1ú“ƘMôFx"¸C?ˆUðá™)B-ÆëBS†ø¤½AùbØÑ~Nè <YNQøJ©œ3}¼L½h©[“å‰JSgy’Ÿ@£8à ;‹ìŠP™é¹U™¯†@|uó ðXA 50iÄÃÿ‹qdQxàhy²§tÁ¼}05ŸÚ©¤eà'÷+_†ëQKRKU&OÞµìÜ3¼TÑ#œúØR[ ñVúYñŸtn–4X'rîdöZÂߢ¹‘¢ÄoÜØ²5òÝaŒIÄ{—üà9e¦2ùè¡¿c_Å|Ý«+—bp̶&Çö=Y€à!‚¢Sé ! ¸‚Æ«S5±‚B†´ Ýj/PÁÏ»#Ÿãl,´!$êˆ40ltLNñßjöTHºKØ@} ŽñXSÓy1›k²¬›ò•á’ƒåTÞ V;Vâ¼,Y"ìß ×ow¤äA#à@"òõã÷ójÖ|¾[³j’_³¡lŸßŸÈ‹‰ìÅRH©“ï+UjgqÁ½Þ§w¨ ¸ÈÁwc/ |ÃaOÏ u)ùH/EÕÁœ»q—r!j¢=y/yQû¸.ÛÀ¦V'¼Èí/.ܾ‚":JDuƒ-¨l“Š'g²Mš¼55ÜK9U2üب“寙ä”IMÆÙÔçÒ&†>£9жz]8†Pf>(N*fM$}çÄ]”gÊ‘3-ׯr¼¾’­ñЫfcIï*dš™ŽK}€$,'†ýè›Ì åÚìè<φñŒ ãÞöL`‚»Ã—`Ó¸Fdú:Ù3¢˜ðcéB¢/©¾5qY* 2_£fPürpÚùpr©}D¢—Mï>HïL¢÷òÇ—£÷4˜) l™ôÁÞQ˜£éw/ºN¿ÂÞš´þÞw¯v›¨¢ðgØZ£Ö*MÉ=BnëKÔõ°g<JFNÒF ÁKÎgÛ½AÒi¬ý Á<åLΕ›°Tçs)¦L‘[T©€dš¹sªÜ±¼â:QoQCFÏóêëD¼iOªÓàb û| ã7ò@×ÐW`%y-ŽÎFôZ™´¸¯íí&ǵÈoW¼ÂÞX‚‡‰¹ÀÔÞKɶùv;3)/õk9 F¶æ 7UfdêØà •z¹8YqÂb4z´Ö?ºîPX"6‘tiïAµJ†wÊÆ ÜËJf©%¨•D§œ$«¶tÌßêCcáIË$w%SŽŽ•=‚¶{Ò=œT˜zƒø¡µ¦Lz¾¬;5~µfm•›`UEã|keäK¡u/ÕGI!áÃÛø_-ІÈ7~‘©¥ùgSý¬§#jMp­2¸fWÿ=#®e4щ㚺ªHiÙ‡t¹‚©ªùÓöpSÆR1ó'6#nÀXK¡Eº%¬L¦mƒId¹%ÙÍD (²å¯¶UeNøO-šðýÞïmm½qIèlDlS´&Ü×ÉWqy‹aïÚë¡Z ¾Qœ  O!E+Pa¶ 4áHÁG¢oÀ¤biEyãàë§@0tMRô!tàC€1^’«¢ƒS¥Œ‡äß¹aìÞ-Óä]ÜÆw V|Uœïâ–Ê$án° PlØÅ·-ô *å$¤¥Tõf’ß%1;±šUI‘a…¦ˆ—_Pbc,û¦Á!r©6tÃa‚¤ž_­Õ9+êob§’ *ê&I[K¿jÒ«ñÑtþ6¾Ô#3H*[Wìý~0¨›Á}êQØ­Ÿ¹Ž6%Š׺ww“Ú¬±±¶ö·Æj³±¾Ú ßuùo£Ùln¬ÿ­Ùj®®®­77ס\kÊÿM4cFpZø·^ŒA»‹Ëõ¼ác óØÏSÎÁ²¬5Õ™i¾Y¨TtÙWQD"ÔŽ0ßq28ãã_¡ßôÍ—W²ªnárán8pýº–Ï IQPæðü¶{t‘ !bI!í³X×/°owlA Luý´•B%)„Cô=ðkßµ›á0…Û}Îàú£{Ÿjìݳ‡ú»;Íem8ð㻆*ÔSˆŠ¨Ùû)öüÊSÔ=»,z¨çuK#Aˆ}ž1]%½d¶¶Òot¼Z¾!a{E ¼2ù±$0o®Ø{}Ò¹à1¥È¯È]äšfᕊà,!ÙM+ûn¼µEÿt0>¢ú„ƒ³°TùOEæÿÛ—åF° ª*l0U`{1æÑ&yúCpy:ŒÑžŽ«(©1÷6SÝ»q%|†÷–!Ü£ñhºõYâ­ùÕ’{iYI¾Óru¦¯ˆT½[ýrLÅFºRc|^HV•¾õ >ÖDçSã<‘].4ËÞÀÃÀQÞ¯îkr· ÅzR²²9Úí|ø à8Á²NA¨X”Î[dÛÂ6œÕ–T*ÁÄœNfwT™+(Ò—ÁKÈHFH£Àw`’×5 êìÉ çà.¦$¨ â5JÖgPŠþ E2ÊÞµ4Í®±=wˆ±¦ŸE#eÏ)ØfˆqÔÇ#ùEf´¨éóØ’VB›[ê‘cSËE±°ç ž±çç Ñ0ôÉM'åYÐÀÒ1ïS:( ¨¢ 鄞=WZ~s'9Þ[黡Ì|KJ|¼¡EÛÐÔt$ËfEN‡%ÒÛ—/“i#eL»¹ªâxÐ\V¦Î¡;³,Ÿ¹É;µ~w¬x,Êì+8"9¡ÚCý öœ¯îÈ׬.Rø©×Ú_=õ^»Çï'ŠòÀeÄò¬þo:‚"£1Xëv59™r šD¼Ñ. @q¥Žõßë–Ìmá/`Ac?j‚^¸'å&R˜ìvvd0X¤ aÂvtê›SLŽnìWÕFZ\Ð*‰± Ðuz½×¡3èÞ@-Z3@ÙˆÆó ¢‚F™¶\Bª”ZRérGjMq1½ÄÒå:j1ßS¿þ+WZÛ`Ü:Ó¥h‘aâáÓ÷â¬Ý9;l¿k øßIGà,­ˆÎÙîÞç+âø§Ó“s±{²/ÞžïžýS¼kŸuÚ?‹ƒ³ÓcqÞ9=k¿Ùí´Ï ð‰„b ¼ñWŽ’–N'J$Ðy¨$Þ¨?\‘q0ÒE¬­“»™ÕîâÂO‡ÕÉ éÐs—Ò×P!‰ÛæŠéQmÁ¦&¨|W± Ž`^0©Y’|@ñ£ˆì^–e’ÉÈò£X2=Í¦ÊÆ‘(ÕK½„"Ëâ¶¡õÂÒ!ªxões¤à¬c ª±¨Z3*¦ =I^‹¨µ´@Ròz¨šOtÕræ“¶øZ[«°u÷¾*˜´ ÕÁèg¤Í$ÐjöÅù» VŒ¶Óe³ì/Ú †ÜŽÇg ¿×¡ ¿—ÆOC~•‚3†&3‰¿QÑ ÈÛÂŽl?º÷j2ð‹æBo ôlXòrj^ŽmÛ2rXxõ*¿·j®$W.‘ïè±Y-ðzúO Îü{+½æ~¦ÑÿžA\@¨åÝ\_/ÐÿÒƒúßõµf þn´š­Í¿‰õ™÷6çù‹ë§™ÿá}|ï¦nãó¿±¹6ŸÿÇx¦ºÿ¹qB÷àó¿ÅçóÿÏôó¿»{¢\ìžî+³Õ‹8ž²6­6¼7Û˜0ÿë› ãþ¯Eå­ùýßc´» •ö*µŒ°a†Í=0y_Íüa€4JzLÑw$]hq©’i¼T©ZÆsŒV‰| {Ù¸ˆÍV>Þ˦öƒêçî¼—S~ßJ‡ºßZ+ªN–‡^ÀSŒv›\fÑ¢­Qk,¿qß+êp£°ÃÆŽƒ+·œ-uJ!€ܠjÕS+cì+/rãÑPt:¡«nkeà}¹‡±j×pš91‘ÐÑæä•D¶+ÈEÔæ ê|õ$t׌z «À ê­ì𤇻'±¿ÛÙ=8§o;ÛÏÎÚ{gíÝNûRMÞ²#[cÍúe-ù]&¡„p À;|û•äM°%jÑwhºheÊva —ôC'?=Ù‰]|£ u´ÍBœ1TXŽkÁhájÓ?ìd•«É?#KÜÞ —@¾]øÅj!#x¦Ü'®…ZO\6g?µa L;2Œ #ý +2ø€"“U²¶?¢K'ì°ÀIóÿpùÿç¿Óý8@±ñÖs:Îur|èù¯¹º±–:ÿ56W×çç¿ÇxʳC“1ò™QTs•§°öݨ¾ƒó¬‡í…ÝÎÑîyõ矮Öj5d{ò1X¿Ž¹ð¥&ã'QâÎî›ô+àÆ+óÚé£+ˆ$×½€XµïO9Å)ŠØŒÙ™~@¤%ˆŒ‚:(¦ilEST8#I%š¥`RL ÌBBNÇÒ{ƒò ÐŽa/y†óTæéä€|RÖa÷óÐs*Hp.ñ'äŠ ð£6„—|ôù… ÐWuÒ9 ‚ˆ¼Há¤ó¿ÿ+ø·’œvx Øƒ^Æd³æ~gûÀ“pP霃E]·TpÌ÷ïuq…9¶ %µ4²?jL-•>VÇlŠ˜´•(‡Rrp0gn·}'©ñ·M]€»7Ê÷‡÷¥t'‰®f¨dõ$°óACãÑ•rß\Þ ã&± ð¤|”n€&„ñÀL \Þö1½‘ê=’oBÊ‹õ;u‰ ­°˜ÉK‘€õ ¸¡BQà0¸µÚÜSÎ G]u×`ò.Þ9þȽ„/ŽÐ1™€/™‘6•*ˆêõâ‚LÁÈm‡ØÁ –¨ ç6ðzQ2i€ï¥w-*’ ¼…âÇÁ`[õý©™½#é]qÐ- Èý—|­ûp>Ç<ÅŠ'FjÔ{Š9Yéûo÷·åÝ>’©cøŒZ¦mu;O·ÌzGâ} öírî1‡·¢&½Ü5ÿ·â?ãy¸üŸC\ ãåü7×Sòÿæ:úÿÍåÿ/ÿüwú¨¨*qSR5xÂH|0 4ƒ$KÔâdjŠVÀMVøãyìtƒt$eþÔqFp Ñ@Õk¤Ïkß7;˜^½{Äì@¿‡\tìù#¼–Óm`xSÍ1U$8J—òK¢ONâ•ÑPq¶ìÌh•›Ni Õö¿„ ¹>V”.Yb̰©"ç> £ú>f85ˆÂaÕ8Œ^Ãm(H3‡ØóRA¬(My,!p|ûp%5 Aˆfx}J ºWáS·¼X‘¬]ÙpF)½{\`°ÂpÈלÁ=GΓD'"; Yq…³ìrF€º¨û+tü‹v夼œË㯺>:9k#½å„Tå@‹Æ –ŽQ è/ªãt.dJ,të¡Ú§•ZÁX®Oë,§¶™)Q'.*=µ%×Ï$’žétȲÐH :‹"6å÷ÒÀ™eà8Ð-àüõÁÀyñ篮v‡oÏÙ;ÓÇ]eº >µç¦ [¶ZѰðׇè«}HMXÀi¯òLJ£oîflÂFßÚëmßô}Îø¼Nƒ¶ ¿þÐG˜ÁÞoï%ùÕ?•§þ?™†©daÌ_ËõdOì:ƒÒ¦]e´>I!ÊZòÔTgËl-ñÆ%¹H|¶ËgHRlÃùwµÖ ”Ŧ‰…ÀX«˜üÁéíŸÊc‘ñ_Êwɱ]6¹tVW¸ÔNÀçV>´ŠjTù "èv¶ÇâH•LšðÞ¶Š·+º²ó?pö”šüiÙ‹˜ï°žù»¦Î;$>ž£° «%bÓ^„æ7„m$ç>…¡t3Œ516Næ'„Ò½º†–󾢺1yŠ“ê d*¿0 ÙZ‚ïÄÈÈ…‚®KD) nz>$²O‡…£æE«}Ü\]X G­‹Öu³qÑmàÏöý\øë j– 3âjð þn¶.|:Æsi|³‘}ã¥_µÙ7ºPE¤UæE¦Ö‹ èÕçé7ë™Æž¯É7Ô±øS`öªec#ô»ùïúnÏõT7è_¢­]Á(]¸Mlst.ZZ«9£Vø¾}pç®ÉÉÉê”`¾;f>@GÍú·æ\~«ûÿ­…>gÜËjw·.¬£kdd­Êòzò «“•Æ>jù¬}MîZB¯Éa’þêñ‘þLn]¤áÉ/ØãtlG^Ÿ÷¼àgZ°jS{M%naâ6y«$îX–oÔ—sÒšÎí $ÆdìÇ{¢‡¾T$q=•Ìyß(ÃìšõËì!º`ïeœÃø5옧üWí¸K3)…ð7í“ R¡JÖõ'6ë*ýÌÔþKZ¡¦Û˜`ÿµÚl­¦ã?­6sû¯Çx`ÿ•Ty´ì£øÆ •ÄÝX¬6¨Ì øYýŒ‡t^ßž‹ó½³Ã·qüÓyG¼n‹³ŸN8éQçû¶Ø†g÷d÷èŸç‡çÇ»çöYíí?ñå6ÙŽ×ÜÚŠ )Zõ"Ï£»zvM?í»ÂzÊ^€ O‡HZ®Ëçöì¯h<÷G·òš[9=¶•SÇv ’™ØE4t»Þ•Ëgà:¬ùþcíí©,æ&¸ÁÐöy Gb$ú¯…/Ñ…ø\ øÏPÄð%°˜Å( éêõ„ί§ÌäÉÈäYIh©êkd¦ºn€¨fÿ4¥¯\àJˆrXnX¹ïq¾s?ÔºŽßÅ/ÊÎG<•ÿR¶T’â j’Vêçã#šHE†ò‹:á¿ÿ=Ìç;¶`¾_ ¶R‚ºúT™†ÚZ– 9­¼7ß„Ývå1Øx ãlüÂÑåb5ãmÍÄP†|ß‹_¤awp½p4ˆÈÐÏJ)Ï(ðý ¾£ª.ªY¿Ì-›+Ç,eæJF{½¢oy3SXÖüðÎíÒñùYß\zNtñ¢Ñx㾫ÝõýgâÔ(¾‚¸¶hÃÉ(áa_ƒÇä­8óŒ®o O é›ÊJD ‚/ÔãH¼­Ã4ÅìFÈA_"ttãûÕE¹ô—ˆðE:Ôû‹oMj «a±KÇ…‚FĶUŒŽ°»@(‚wɱԜd$úµÌ{ê2NûÙ‘TˆéÅï_/>K^ÃÏ&º0¢ƒ0Ktî]L“Bž×ýˆzßn†h~G¡ãÁ K‚ù$Æð6W³ZsOZe{E<ûEi;¿7(eÙ;7á›ðÎMxç&¼sÞÙ˜ðæÞàŽbƒw{WâÙáùÅùáñOG»ÃÓ“g¨: ƒ —ç£~ß ïÿõ̽/âû¡ûì—­Ü;8õ¨2_fhâÜÄø¯kb<·óM-µ¹ÁîÜ`÷¿Ä sn°;7ØìÎ vç»sƒÝ¹ÁîŸÂ`wnB:7!›ÎMHÕ„4¾™[‘–·"[Wþ!¬+o“¶ù3Å3[ûO+ú»nc|üÿÖêjk=ÿm³1ÿ÷(ÏÃâÿå€îµÏN ¬39á=m6***7™p"`4É !!Öu) €-[ªŸ@ã}7h±s½"ܸ[[Q×üþ}ešBm,ĵw˺½«‘ïÃQäÔ¡È0Þ*,¬Žô,#q'¡»ñ¶Z7—Æ×¡×[A[ERÓy×`7 ÈKPØO¶î`ëSªâÙJpPØÿž¨à˜ à¯{m}£…¬¾h¼ø]Bϰ/ccÿ÷GÿìÝ » A9M"ð8pßGa5°÷¼É{¬smxqäúWµ’AÌÙ`;}ã+ª¼›q«y´+]¨»Xò* £úñ^G1ÛÌ¡‚õÈ_¢+H7Afìü QG—ZWÌ‘PÖÙRü ®_S*²ØƒR3°4ÓXgÃ*zVPeŠŽšÝõ}j/z2ut&®iZ ®Û–è¹6ÄåMåÿ êÿEÓskùyLйAáÜ pnP87(œÎ ç…sƒÂ¹AáÜ pnP87(œÎ ç…sƒÂ¹AáÜ ðÏlP(æ@ç@çæ›só͹ùæÜ|sn¾ù{ÇõüëXžJ†4·@-ÿ<Àþót?:»o&ç}VÏøøŸÆFs-•ÿy}£ÑœÛ>Æ“ÏÏ÷¥Î;7Œ`‚·v;G»çÕŸþ¹Z«ÕàT†4ñƒí¥’ÎþBŸa‰09Þ^ÀÌóÉgº±xÆ–.ÀzÈÎthüvÍG+½ù¸<‘ô¼Æ—?¬³Mæð’9åôóïLAÀP&’/”{R æF~‚õ»­iö·×ÒÆ¤ýîÿõµf þn´šÍÕ¿‰õYw6ïù‹ïÿiçŸýZ7º™¢ñöÿè°¡è?ZÃü·67Wçôÿ1ž§ÂíÞbpæt[?ªFµ¹^ml ­&co8¬ß}·rÁGä¹:‡L®77k­ÚZ}üÂb&°(¾þûÞq‡…ÛÛ¢!–èš ¸ ãn…úXïÞö¡M2g®)ãæÐõèS= ®b´éª{Ï7ª‘ß]¯^w»k«Õ`+lPý¶¶Ö*î ç]U"R!‰¯ÿ#[ø­Þ¿“Å]AE,wsb·?DõÖöÿ¤jA9Qý÷ȃ*—xy-°d:áý†"üìéרáSüWØË¤…mPvøXûúk‰qN£ó§{0ûSÿœÍÏú™–ÿ‡.¬öÐÅpVQÙ6&Ø­m®6û¿5äÿsýÿ#=H8k×bõ•ŠCñ=óB‚ŠWéåw—¿vÜîT*o9óÛÀ÷º÷Ož<1~UÍêr¥r:ƒîa`'®Aî‡h;åtÝ'OìßTíÉ“öü¬’6ö޾o¿B¶A¿¨/‹¼ÂÈ0:ø7‚LŠQ¹sô^{ƒ^ÌÉóD¿¸yúЇ7¤ã]å”Óß àÐw‰.rå—.e~Ë$±Aeº¤@çÍŸ4ã·<ÁÈÄyyò$ó aME°(ô–ò$ùA¨œ¹˜7GäíÉåÑ/jßíz‘ ñäIú V•ÞSuüW¯[U}x9Ÿ½ýXߌ¡4%s‚¿ûnœÊþ–€*†¤~Ó³g~3g·zVõN+Õ»Ï' ê#N‹Þ¼Qö !·gop]—Õt}|×x熱{g4£ßYëÝ„`vä#—µVgÁë\âÀ#ÇNŒ™t ›ž &Á¨¥'OR/òV?¹µ¨R‡ûǽvú}GÂxbüÊYÿuþLõúj"¡T?™ÔlœñÃ|ô®¼.ùÜQýØ©êêϼ‡EÆHôBÌ/úî.5Uød¾¥f=‡F¸ƒÞ…Ú[ sV Ÿ˜:ñ$ï-ʾw‰'i[5±\ëÞÝ¡Kì0 ,Z§ ¹ ‡þýEì\ ò5}í@g¼Ë(ýáÎxyïÏ;Gû^7Îûô&t†70tyß:Î¥ïÒùeH1p †²•§vžÛõ1ÄfÔ ½aÌñX£í§×C¯ÊQÉ/þ!¸”ñÖTåÚð†eþÝ”ÎÂ0­üì|t±ÁidÌIöÍV+mÿ³¾1·ÿ”Gy1}½(,Kõ(ìêi®Ý£oŽ8UŽÈ©p ÖúPi~(ÿc=Óì8»}Iÿ/cÿ7›ë͹ÿ×c<ÓÌ/è>šÿ_«1ŸÿÇx¦t‚:×ÀÊ·1aþ[k«ëiý_cs~ÿ÷(O}$ìïÔ¬RœAœs}Œ€Ó!)+Qå\> F5Ðèx"RAΫb„ 0͇!PYŒA_’â˜ï&¢X—fQÒ ·O6&##«÷0¼Œwɱâ•îG ¸ó*¥g&tS€ ]'âŒ!Œwß¹¯P EÉ™ŠVƒ¯t Q<ººÒc}Õ¨_yq‹£vR0Ÿ$Ú½àã'Æàuì1ì _õ7"hQ×ñ‹"Œô(ä ZÑe]t»ø7 „ü“–ì}²[.ïÕê¨YˆdžŒåõƒžwu•ú¼q¹þ{„!¨ðd`6J}åçBØ× @‹"ä¸×Q&:ˆCOQ¤¨òÝMÜ÷ÕÁÄ*^Ã/,óÖJœ?*ß©úf‘Je¶Æ_â(3 ÿ·~LÑÆôò_kss}.ÿ=ÆóàùWèÈaÅáøùon4«†üׄùßX[ÛœËñ<õ®ÀÚÄîÉîÑ?Ï11Åí£vçôäâûÊSæy¹ßêñ`+‚BÕÁ³• £xC$?€ÁÕfðš`±c­c‚Àé,±‰<&…%öB×AIgKü0òï9¦Bp¿}¾wvøsylé—³•s ~†¨ŒÐò®ö¡eú|±bw0Éò 8;a÷F4›+œáScFâÆ ˆ´—®;@ùËDP‹„Ì?¢p×]Jt!‡ 3Ÿ(CeD‰Ñà”*œ.…æCÐ*&%&Õ“TM™°ŸÅ÷QØ­]×V’ ö+t‰ÿ|pé+e%¨Íá(ºÁ°ç(ÄdýÌE·R…1·. ë”0”f‚ÄöT23]^fS‰\¨ÇÃh«^?y=mÉH¿ÈTêÖs?ÕÙ|"‘CçWóû üø„þÝÓ}}YâúÍõ§È ¤ã Éð"ø4¸P~AÈ^铯å÷˜3~¨”s¢¹NÈ*¬e'qÈþƒêx=ü=e-¬Ý,”ÑÙ´Š‹pà÷wœÉÎ*Ev#õŸ^ÕÏéÌrzE¿ìbÚ¤®ÿÂ(ˆ… ꨣ7 fß,Œºõ+U2³øŠ“ÝÙhŒ¯˜Î½1EÕ¼.ÓW7CÛ=NwÔÓ/¨|½nÔ8‚¹Ä¿&k~å©åoõLIs hS”L¾»×¨°J¿B2:¸Þ±0ÿ¾I…˜&[qË_â='î/<E@?øNõeÅþ-þƒ†“T¢õ¾Á@Ñ/+¿ÁYŠß¦9ðŸáèÐ"eð*²ÀV%/ðð"Ý׈(îmmq¾!WÄ!¬Ú£æA¸,†É¥—çÿ2€–8ñ­Æ#8lž“EæÒẪÍä9¾÷«ûÚÂÃ6GA0\d€“ëM(Hù'&“9'”B³Ò»$ï©yøêËËÌü&èçu|ŸOÄ6`GE(j€T È+»„äjéÁÄæ0™ kgµYiut ÍêØš|œ,0[D¥Â%^“ —®ú)mȵ4£@ƒ³6©Ÿ€Pý€)?Ù–Ád×YP˜Ý- ‘ø÷È ?Š+ß¹†½G¾-«c°t(ó,;í€ -Z›nk‹V÷…‡ñxaébýÃ8LµÒgKÑîŒÇò¼I£S¼äC?ˆ9 ûùOçÿD5`3?f€`¦¸sþ˜îí°C2Z0ä~çT†R`øag{ÿÍ °µÝäük%ý•2 % ºqý!ˆRÜNÂb_YühGôµÜ@/^æ–Ù„Iz%è8vάâÅi4^ÈÞv¤=I‚Žõùå8)n·“‚“ú<Ró3(çs h/ÜYhÆçdìiˆµhl%·èI^™[d1[[i~ŠˆùAvRóŠrL='œ»L¥ ÛÒòŽXF 7ü#*IP‚,mIO);Â듌¸ˆÚ‰À…À#õÛ¨øÑ½WG•ÏF$ù:Iº…¾aKR€c"gnÃ`ƒÐ‚«óáÈêxð|)ts¤JU¹]FLéUî##CR¦ÕÄÆ8¯ÝØ´´×mc7¥þw,ý²!÷í¤Hyˆ1`ñ!г$ ˆ iMíPþ¤ÕÍÔßÞáëÔ»ûœwDI_ ‘ ¦Óëyˆ·ãËð(V©¬ìTrÐ1Q¸ž•(Õnª¯Ò£&c—\Öp"ì.7Ʀ+º”-)+c°ÔÛØÑ¥U3ÈÕÆ7!ó£zÃÕ^tÛÌ4eäEÍý`µfÌ\^S}#3jRI¥ÈÅÔ,—U.‘°ô/<3û©±ÅhSš¹T…§51  ,1*âC3‡*u·Â`¾OnÛ¨Ù¸oh*†TÖ~ç"Âé—æ"!“Ïr˜/.I0=={™óuÌG9}ïÇ•ñK×/ãCÉÆFvÁÜÑþ)èPá·¤‰Â"ܨ7%ʬrFA¢(fM"'Ö‹˜^o$܆2Œù/v3#zLÑwwO–Ä­zh®áE òKQ„}÷Df1Á †tNš9£œ¤úŒ–(JgÀÅÁED–Èð-:_ñŠß!2ŠeärW„WùX ´îC7éî;»w?0fz·1TE™=6èå×”²óß"®GÖzÁWÜ’¤šr¯®ú·e½¿É‚Úl—ŒXþH¨Àº…jš\æuǹ~ë=’'Ît¨µŠuR*¦gþ„²˜µý—9oG“z!+Oî‰,øvRo4@ä]­FY¨ ä•BõxTÕãQ9T`>ª0˜;Ëɪ¥_»Q|ì” ÷n¼õÌZ{ôýȶãóQ?³2õ~D¬é£\1Î3cŸéì1êã‘.nØJÍü×- _IüšhÑ"¼òGÁGYvßDó…x9î³3îóðÆËÿì·ÆWŸ €óçbàM®ýüùØÏEÀ› ðŠ%¨Ð°éÅ¢åc/•,+½œŒÒêФvé²}gh\Á›ŽÞt{„Ðhy×hBÂë´-'„‹Ü‰ °ïùtÔ÷±5æcû`B7)q…-@êûüï)lxQ–søW°’øó>¾ÿ?s %ïÿÇÅÙ\k¦ïÿW׿öŸòdo8’7LÌ7>œÎÌß@üv|§R|u6Ý­`ÆÙ€¡Ó!ë ƒ0{e•ïZ×È»’+wAÅ÷5¦Öêee¶×¨²‰ô¾›p%ôŸJE]‰lÝÞý_Ðâ’øp ÒÓü¹®„„v & ;ð@2ùn{1àbè*Êh‡ú/)X 'T4ëÄïÙj·´>­zoC¯~¿y°Î³•V…w eW‹v¯í • ûG÷žêœH-'~Mtš²ëm}A”+¥+™†åå¼ïáh€_EÁgÔ÷^ûA÷cQýØë»0SýáËÊF‰vºÐúŠ©¯Ð |k+K‹húÝKÆžé)5:À´ëÉ?Y 1­¶½P*ý2' oèÿ4üòT×Sò˜ñöë««­Í”ÿG«¹ÞšóÿÇxZf³ÚX­¶6 3¯Jåɲ¸òîl»i²ð¢Ë òÊË¢´S/vªnd5ÝH ]—PšIô=¨ö¼pôu†Þ@èÍièé.à ÚmàõÝ Ã'Ñçä±ï·³VIšiæ5ƒ û#÷ßÅIû=ºfÇd¯'®ƒ ‡‘@a ««@f»£8©Þ¡<žժªUm>ÏÃÊI×± —§ì5NVýÚJ䨉ðÆÊt¬\EÄ=lF?à^ Ûœ4‚-×F×Ý^OáD7»9xIw”7Tæ´¤gíÝýãv­ós‡ÌûOã–ɸ+Ã:ï=ß·®š ÛfµÕ*é _ksM‹Gø)¯•¶ÒxQm¶`XÄn R¨#~ è×s„{ñŠßÖ¬·ßIÃÁ9+.»%™7”i>„í/¥cGåIN^rš ´g¤5)Áê”—(êÕ ,VóÚö¯¸yS¸B °ïôÒë ×£#.½X¸Nä¬Èù†7·èK@ªhã[“ËÌMò&qMn^$>yK.‘A/ƒyv/SÛ€OAÐ×ÜÙ<¨JìÞ“i«²[Í™ûI,à{ß]À¹#c€_Ù†ódÓ6E°Ô/.atq\Ã-÷D@÷\éUºtÛÎÞo®ÓË]¾kr“øÆ&ü?nx Áõ…1ù„þ°–*²vªâKk7 )vv¿/ÂrèFO8g8Y\¾¸†Es½Öª5VÄ%ŒN0ðïÍ?×K R°§J …fŸ`[ÉÕ®5^ìë[¡r„UÈ9ka á”"põ.–·ò­K1°#ë7×@w¾wýþMàÇ¿îú¾ç ~uߟ/åN2=Õßjk-ÀQp@?s:ncôŽç¹éÑ÷¬¥U.7UÁ–š‡ñóc`Ùg^× {x ºŽˆW‚È…µH¿¬‰Êƒµ‰úÞu¨}ëpC¥‰ŸjHn†M"è!†ê„¡"6MÉË÷,û ÈÚ3]eɃd\E(n¨Öת«ÆwÀ;‚ÇÓÃ(R£aJE^®ãÄ>—žïÅš‹³LæôÈ*…é‘YZœhMÑ\«5k?+CïÂyYWˆ7ZÏCÔhÏñýà›à>V—c´¸èD†$ÍX]ÞÆ8À¸1†s‚gROŒ$Ú¥SÅñq[3pˬrœB)ÞªGƒi›YbQ¯? Qà<<98%b¿ß~ýÓt“úÎ}­ !ÅP@*hfäåƒCäÃ}o€þ÷à ®QŒ¢1DÚhmäîçñ-ØI§'´ÕdñD+#=ƒ”Ç+3cÑ:là ãtº=r„ÝwÃÊ{øÏwþppãÖ¼Ak¸Z» ™ñäk¼ 9yTl¨å ÙÌ$?ˆcÙZx…Ëô„@Å«óÿù]x3òkN·6úXŒÀóDÆ?Ø[DCm¡ˆê†Ý¬·,„-]êmÁp÷ȾÏÃ`nÀIäà#éF}ŒÒ"Tw”qÙâù}OЭ©ØDêSZ¸R¢>l—Kßí ¶Æ,áð:ÁÝó£z§hä6UÛÄšJOÂc­x,¤?¿íVž(¤ÑaÊ Q……¾Õ#‡k>7\q"çÖ€d­ùôåè:ª{ƒž{WÞ ÿ¾º±¾¶fô¤1EO g>‘„`ú%‡NÚhnÎz´âr¼›12;Z×h®Ö5XÀ=j …õ©P˜àº%ÆâÖscÒצYÜ@N{Àn0XAàߺÚ@+©ÅKJÚIþ÷ÕõV³©` E“Ò»%@”3J!] %JûH-¯bK€*0daÅéÉÑ?‹öNCa²šÃðöÔL‚L“dð½ªtч÷µœê¡ ¼\*¿ÑÀÄÒJ›ÄAû0Ñi\È–™J)ªŸAOôº3^¼ŠLr¦·R+×TJ7kkesdƒñ+4§Bš+YaIAbt]„9:­jË@Åâ-þ]û“¨{rzþv÷Öä’R'` t¡„ã˜òDI-”+nÜcˆ¨)lÇ+€0’-wÈ×øå°‡¦É剜¹G‰ÝÛD‘¥±Yrרp‘ËÚg$ô¦QIfg÷M¢ëWŽ2n½Ibë,[ß )‡GQçMÔ%”æ£åZYËo¥µ:ÓVVõù[Ó$׉Œ&gر&©²›BQ®•&Éì°.øäƒÅˆGy Ã2Y¨…A/ÔeUzåPh˜Z\ °›±èùî â¡xÑ}TÕšL´Û”Ø•hmÌ;œ|; ‡#ã†& 6›3m†ƒÝ¬ZÛ¬¶fH"R<ÏÉ5”:gÙÔæ¤=„MÎpÛ6$ šÔä Wsƒ®T&4I· ³lrMžâ1H ,¿N‘yl}¶+hµd9ÚHޏц'Yg³åz IÒ  j`ÉwkvŒÔÁjŠß€Ø½{‚™ŽJU„Ãx¹rÏ•ô¢™u=í ô;fâb½žÝ^"…p)q5(bœÑñ’j3D%øÌŽN’ú³d¹u…wgÇ\Ie©šNŠnª9ÛÙ!NbÖºŸ¡¬@ÊClƒÓ2Y÷ ‰ÛÃØ({ø+×nsB»O–9XœiÒóh}¢µê.b`¡Ž \ÃÙ‘İÁ8Ä"ôHÉ­/÷¨. ˜ FÛ3ÜÏ«k«LWq``Y»t/NŠöÓ}é–ˆƒËOaМ¥ˆ„´J–kòíXβÎÀûÕŠ´£\嬕4sLQŽƒ}Ì-Óù~ןò‹çÕÕŠ œ¹]™"&;©¤Á™.‰Uâí$ûâ{øÁ1 {/Ai}M9 6剷°IfÇAoä;aj) à? áSW2*ÉqÓ8ã^v3OÀi}JœÊ®— ¬Énº&ì²BøØ«y°Ë.» °[y°§P—ƒMD†þ:Ä V|£¬=|£ül–TëEøÙLjë¹qVàrå…x+ º!rCÎ1éÝìpÒÒ%ÒX2Aµ…–³ô Ä…in’Ƶ­ÈEÁQs¦mù@[O5ô¸`ÔqÐi`&’VK3Ð ­¶ Sl‡ÎÂ*ÝÖÖÛ› &{lßæ{x˜›âžb¦My=.cÒxÿÁ ”Ù¥ð¢2ÜžÁl(Y«aXÐaN_šM™m͆à7_L* O°´4)ÊÞ¤:›‰p6&8ψÒ7‰z¨‰€™´·Ã¡íÐY¶0¹¾6´t’œ "ëÓ b4ß§çD7ž8vÜA ^Å}ü·|Ãk,£ÉpOìï&ÚÕq•xãœa›K*Œ¦Ð´Nh‚ĺ£A‹–„u}MM‹…ðW…8w/hÖˆ×Þ]s_]â¿ßù—þep7v£ìUœØ²Øhì¦"×¼ÆênxjóŠçå5ã‘d;Þˆ£ É ú=qÒ }×h±9›Ye%Ö1Îjnƒ°Ãú,j'ÁýM,ʪG&`±1‹¤Á ¬nW€vá!æ…Ó„Ëf"=÷Êù±8MiùrćÍò‡Å ˆ¬N* Äú<46fµ5Y»ÃVYæ%üÝý5ìÈ^Ð%ÒòøŠ •tÜ*³ ï “£²zåŽ/õ%çX¼C˜LþO÷±ü{ÌKÏ"9)h-”X Fqä¡wçûöÉîãŒC—Útây#-íÐ{‘íòTÎa…nޝg|bÅC¤;ì è\:äÊ%ƒà“1‚ŸÅk6%Áe9Lz§(è병B6%áMͯ$“¯_Ï£Y*ÆJCáX\ºœ°Tã3 »)il>²±µÙä›’¼Ž+°)5´ƒq*µwÎn^CûÅ™ µ1]«³í6%Ñ-ÝêL$îMIÉÇXURðQàôö•RÚs£Ú®ÈZ­ÎÎZIV¤¯=ôÉžm > Ò¶©.ãx©òíêh‚:ˆ“Ñì,¸ñ¦¤õÊ­ˆMèl÷²KW-‰xJ÷JÁ2qv3•V¥OÀ«‘ÇéždøÔ;ÊžŠ³–±oï+ôVg3l­V’ÔY&¨Aü¯2K—¾PLÅÈI¤"”F¿‹ÜØly“°!·Èf(™Ö_tNB ÁëúF³³ ¤r“Zó¨,•lN®È“ÆãÎ wC8x7Ö×kÚýb­d>²þ˜éÓ×½Ÿ0`>4éûð_Î!Lî^€o࣯ s×N·%¹®Çy±œÁ=ž´d5·½½ƒ>Ñ ù¶¤:ÙšJå2®wêB^F¨$¾lú˜ÑGQ—Äê…G·‘x}xÒîC®»ëüÁÜ46RÆðãjd¦<•{¼žJWžàҘŖ^—ò‘6ï{ #~tffqY—"Ò˜,³D}Ç÷ þ:Ý…o–!(1*Ïâ¹.¥åu¢Ir5¡º”î´"g}*s Ð7&X×-©Ðâæg±­Ö%½„sb"nƘ/DY†Èc6n(ú„MPi¾(3Çrü^œ9e4ô½X+lâZY6´®H¯Êo’kŸtx÷í!²вûÚhl6›19èæóWnk6;’‰až=á„z¬eÑñ÷jä ôícô¬³cuÒ¼Ïï5¹Úør¥tÓ³ Ö&ß®Ó úó²ënÍ4­…e§T *‰§³4þrSîI©×Ѿ‰NŒ½q>m‹tP~°ÃQ8 ༿d`3…è/±ihl(<”VöZf€<©Ò+Œç’]ÑO÷ ,J‹™ÊùŒ9Š`þúŽXK Íä$¦œÌl7’ënwµf6UJ¥!á)[7@<•(“èi’›3ß(Å.%üd`LšêÞÂB4@®O2G¤GT9e¥‚Ù(9¼ÏîìÅmów¼›å]ÕT%«b\çËÿ) 1p ±Ô±õqÞݱÝ=7߸¤Lö¬§™{ä|5ÿÄkŒ›Iœ’¶§ çF[úÈI‹ Zؘ!MKŠ½êˆ½:ƒËà¾~ÞÙÝ;5(qÿ2‹Œ‰AOî,>Rq~߈’ÆbÊXùG4ð„åX ä8»¯Õð,:ÛÛ’Ô‘Ùj} ³÷ ÀµUšÖn’Æf4¯‰=¹˜]+ëÉꇒõ&ýšP¼^°•èÉáñ¤äôkufSÕb‹NÍ}~ß?òu6ìd™¨À5Y\frþmIÚ†z>– ÏFƒŽ×w)ÌzÕ"ä'…®‚ Ð”Ù0]Æ=ºÐÂÁ*ÀÌÒY}À:…7šÅš# BløEm­VL™Óê‹YHÚdkÈX4jyŒy kt°ÅBSšL{DjJ;ÄÙ°íM°ƒ!Þwn½žÀØ,¡çŠWô³&~g)ë²¾©”Ƴu[ªÉË{­E¸*”NåIjí®(†¹ OŽÀ<’ÞC‡£AÃ2 wpë…Á Ow”âGyv`ÊøZÒ™Ün6/É!Q¯Û¹ºª¡Yp6%‡d‡y )“1_$ßœšKL6"æl¶¹v¦ÁïuLÏž°@ðà `GZÚn¤²yr\ (J&Op› §iJ~&qkU#Icuå³&m¶Rò‰üY£Ÿöº•pÀL¬£Í–רJk6½X3záà•½1ÄIc3ZMZ 5Çi.µÆÆ'³i¬¥%iõHQ§nlú¼¦)îs68 ;G0¡6â[#1|£!UÐû¹†I[³`÷Ê©U^кf_¦mÈBL±f<Õ1¬ñ-óö—Ôçø^}­ÝÔ`B…•Y ±åb·6í‰(¯÷Ó„”…xac€1aŠI=¯«nØWè&Ž3!ä¤oÁžÍJ–4í¾¥ìò~­ª[e ©.…â#rOY§ÛqÅoUÿ^ƒxšÉþÕñi(LßÄu*-Ù̶Z×öxk 5‹cAC«Ï<'Åü™?ógþÌŸù3æÏü™?ógþÌŸù3æÏü™?ógþÌŸ¿øóÿðpþÒ€cctools-4.0-source/apps/atlas/README0000640060042600000500000000200312175446362016101 0ustar btovardipThanks to Stefan Kluth for providing this example. This is an example of running a ATLAS simulation job using the CVMFS filesystem accessed via Parrot. All of the bootstrap data is present here -- everything is is downloaded on demand using the CVMFS filesystem. In order to run the example correctly, you must have cctools build against the CVMFS filesystem, and also access to an HTTP proxy that is part of the CVMFS caching hierarchy. The code is meant to run on Scientific Linux 5 but appears to run correctly on RHEL5/6 as long as SCRAM_ARCH is set correctly. As written, the example relies upon a specific proxy (cache01.hep.wisc.edu) which is known to be accessible on the wisc.edu and nd.edu networks. If you run it elsewhere, you will almost certainly have to change the HTTP_PROXY setting to point to your own proxy server. To run the example: ./parrot.atlas.sh The example completes in about 5 minutes with a cold CVMFS cache, and about 1 minute with a warm cache. The correct output is: cctools-4.0-source/apps/atlas/atlas.sh0000751060042600000500000000204112175446362016666 0ustar btovardip#!/bin/bash export ATLAS_LOCAL_ROOT_BASE=/cvmfs/atlas.cern.ch/repo/ATLASLocalRootBase echo "atlasLocalSetup" source ${ATLAS_LOCAL_ROOT_BASE}/user/atlasLocalSetup.sh echo "cleaning up workspace" rm -rf athena/17.2.4 mkdir -p athena/17.2.4 echo "asetup" asetup 17.2.4,here # In production, PhysicsAnalysis would be checked out from this code repository. # cmt co -r UserAnalysis-00-15-06 PhysicsAnalysis/AnalysisCommon/UserAnalysis # Since we do not have access to that repository, we use this tarball instead: echo "unpacking analysis data" tar -xzf PhysicsAnalysis.tar.gz cd PhysicsAnalysis/AnalysisCommon/UserAnalysis/run JOBOPTSEARCHPATH=/cvmfs/atlas.cern.ch/repo/sw/Generators/MC12JobOptions/latest/common:$JOBOPTSEARCHPATH JOBOPTSEARCHPATH=/cvmfs/atlas.cern.ch/repo/sw/Generators/MC12JobOptions/latest/share/DSID147xxx:$JOBOPTSEARCHPATH echo "running simulation" Generate_trf.py ecmEnergy=8000. runNumber=105144 firstEvent=1 maxEvents=10 randomSeed=1324354657 jobConfig=MC12.147816.Pythia8_AU2CTEQ6L1_Zee.py outputEVNTFile=pythia.EVNT.pool.root cctools-4.0-source/apps/atlas/parrot.atlas.sh0000751060042600000500000000067312175446362020205 0ustar btovardip#!/bin/sh export PARROT_ALLOW_SWITCHING_CVMFS_REPOSITORIES="yes" export HTTP_PROXY=http://cache01.hep.wisc.edu:3128 export PARROT_CVMFS_REPO='*.cern.ch:pubkey=,url=http://cvmfs-stratum-one.cern.ch/opt/*;http://cernvmfs.gridpp.rl.ac.uk/opt/*;http://cvmfs.racf.bnl.gov/opt/* atlas-nightlies.cern.ch:url=http://cvmfs-atlas-nightlies.cern.ch/cvmfs/atlas-nightlies.cern.ch,pubkey=' parrot_run ./atlas.sh cctools-4.0-source/apps/cms/0000751060042600000500000000000012175446362014704 5ustar btovardipcctools-4.0-source/apps/cms/README0000640060042600000500000000356612175446362015576 0ustar btovardipThanks for Dan Bradley for providing this example. This is an example of running a CMS simulation job using the CVMFS filesystem accessed via Parrot. It is typical of how CMS jobs are run on the Open Science Grid. All of the bootstrap data is present here -- everything is is downloaded on demand using the CVMFS filesystem. In order to run the example correctly, you must have cctools build against the CVMFS filesystem, and also access to an HTTP proxy that is part of the CVMFS caching hierarchy. The code is meant to run on Scientific Linux 5 but appears to run correctly on RHEL5/6 as long as SCRAM_ARCH is set correctly. As written, the example relies upon a specific proxy (cache01.hep.wisc.edu) which is known to be accessible on the wisc.edu and nd.edu networks. If you run it elsewhere, you will almost certainly have to change the HTTP_PROXY setting to point to your own proxy server. The SITECONF directory is a mandatory configuration directory found at all CMS data analysis sites under a fixed path. When the job runs elsewhere, we must provide our own SITECONF directory and mount it into the appropriate place using the -M option to Parrot. To run the example: ./parrot.cmsjob.sh The example completes in about 5 minutes with a cold CVMFS cache, and about 1 minute with a warm cache. The correct output is: GEN,SIM,ENDJOB We have determined that this is simulation (if not, rerun cmsDriver.py with --data) duplicated definition of E8TeV_AVE_10_BX_50ns Step: GEN Spec: Loading generator fragment from Configuration.Generator.TTbar_Tauola_7TeV_cfi Step: SIM Spec: Step: ENDJOB Spec: Starting cmsRun TTbar_Tauola_7TeV_cfi_GEN_SIM.py MSTU(12) changed from 0 to 12345 ============================================= MessageLogger Summary Severity # Occurrences Total Occurrences -------- ------------- ----------------- cctools-4.0-source/apps/cms/SITECONF/0000751060042600000500000000000012175446362016116 5ustar btovardipcctools-4.0-source/apps/cms/SITECONF/local/0000751060042600000500000000000012175446362017210 5ustar btovardipcctools-4.0-source/apps/cms/SITECONF/local/JobConfig/0000751060042600000500000000000012175446362021050 5ustar btovardipcctools-4.0-source/apps/cms/SITECONF/local/JobConfig/site-local-config.xml0000640060042600000500000000303612175446362025073 0ustar btovardip cctools-4.0-source/apps/cms/SITECONF/local/JobConfig/site-local-config.xml.orig0000640060042600000500000000301012175446362026022 0ustar btovardip cctools-4.0-source/apps/cms/SITECONF/local/PhEDEx/0000751060042600000500000000000012175446362020265 5ustar btovardipcctools-4.0-source/apps/cms/SITECONF/local/PhEDEx/storage.xml0000640060042600000500000000047512175446362022461 0ustar btovardip cctools-4.0-source/apps/cms/cmsjob.sh0000751060042600000500000000050612175446362016521 0ustar btovardip#!/bin/sh rm -rf cmsjob mkdir cmsjob cd cmsjob source /cvmfs/cms.cern.ch/cmsset_default.sh scramv1 project CMSSW ${CMS_VERSION} cd ${CMS_VERSION} eval `scram runtime -sh` cd .. cmsDriver.py TTbar_Tauola_7TeV_cfi --conditions auto:startup -s GEN,SIM --datatier GEN-SIM -n 0 --relval 9000,50 --eventcontent RAWSIM --no_output cctools-4.0-source/apps/cms/parrot.cmsjob.sh0000751060042600000500000000032412175446362020025 0ustar btovardip#!/bin/sh export HTTP_PROXY=http://cache01.hep.wisc.edu:3128 export CMS_VERSION=CMSSW_5_3_11 export SCRAM_ARCH=slc5_amd64_gcc462 parrot_run -M /cvmfs/cms.cern.ch/SITECONF/local=`pwd`/SITECONF/local ./cmsjob.sh cctools-4.0-source/apps/makeflow_blast/0000751060042600000500000000000012175446362017114 5ustar btovardipcctools-4.0-source/apps/makeflow_blast/makeflow_blast0000751060042600000500000000741712175446362022045 0ustar btovardip#! /usr/bin/env python # Copyright (C) 2011- The University of Notre Dame # This software is distributed under the GNU General Public License. # See the file COPYING for details. # # This program generates makeflows to parallelize the # popular blastall program. # import sys import re import string import getopt import subprocess import os def usage(): sys.stderr.write("Usage: makeflow_blast query_granularity character_granularity [blastall arguments]") subprocess.call(["blastall"], stdout=sys.stderr) #In which global variables are used with abandon def count_splits(): FILE = open(query, "r") num_chars = 0 num_queries = 0 num_jobs = 1 for line in FILE: if(re.search('^>', line)): if(num_queries > (int(query_gran) - 1) or num_chars > (int(char_gran) - 1) ): num_jobs = num_jobs + 1 num_chars = 0 num_queries = 0 num_queries += 1 else: num_chars += len(line) FILE.close() return num_jobs #In which global variables are used with abandon def check_blast( args=None ): null = open(os.devnull, 'w') TMPF = open("tmp", "w") TMPF.write(">TestSeq\nATATATATTTCCCAGGTAGACCACACAGAGACAGATACACCACA\n") TMPF.close() blast_arguments = 'blastall ' + string.join(args) blast_arguments = re.sub(query,"tmp",blast_arguments) try: subprocess.check_call(re.split("\s+",blast_arguments), stdout=null,stderr=null) except subprocess.CalledProcessError, err: return(1) rm_path = os.curdir + "/tmp" os.remove(rm_path) os.remove(output) null.close() return(0) #Check input in a bunch of ways (getopt wont finish unless it recognizes all the flags, so we put in all the blast options as well options = None args = None try: (options,args) = getopt.gnu_getopt(sys.argv,'p:d:i:e:m:o:F:G:E:X:I:q:r:v:b:f:g:Q:D:a:O:J:M:W:z:K:P:Y:S:T:l:U:y:Z:R:n:L:A:w:t:B:V:C:s:') except getopt.GetoptError, err: usage() sys.exit(1) query = None output = None database = None for o, a in options: if o == "-i": query = a elif o == "-o": output = a elif o == "-d": database = a #Basically, do we have the things we need, and does blast know what to do with the rest of the things if (query == None or output == None or database == None or len(sys.argv) < 3 or check_blast(sys.argv[3:]) == 1) : usage() sys.exit(1) #Survived input validation query_gran = sys.argv[1] char_gran = sys.argv[2] blast_args = string.join(sys.argv[3:]) inputlist = "" outputlist = "" errorlist = "" num_splits = count_splits() for i in range(num_splits): inputlist = inputlist + "input." + str(i) + " " outputlist = outputlist + "output." + str(i) + " " errorlist = errorlist + "error." + str(i) + " " #Here we actually start generating the Makeflow #How to get inputs print str(inputlist) + ": " + query + " split_fasta" print "\tLOCAL python split_fasta " + query_gran + " " + char_gran + " " + query + "\n" #How to get outputs db_split = re.split("/",database) database = db_split[0] for i in range(num_splits): temp_cmd= re.sub("-i\s*" + query,'-i input.'+str(i),blast_args) temp_cmd= re.sub("-o\s*" + output,'-o output.'+str(i),temp_cmd) print "output." + str(i) + " error." + str(i) + ": blastall input." + str(i) + " " + database print "\tblastall " + temp_cmd + " 2> error." + str(i) + "\n" #How to concatenate and cleanup outputs (very naive) print output + ": find cat " + outputlist print "\tLOCAL find . -maxdepth 1 -name 'output.*' -exec cat {} \\\\;> " + output + ";find . -maxdepth 1 -name 'output.*' -exec rm {} \\\\;\n" #How to concatenate and cleanup errors (very naive) print "error: find cat " + errorlist print "\tLOCAL find . -maxdepth 1 -name 'error.*' -exec cat {} \\\\;> error;find . -maxdepth 1 -name 'error.*' -exec rm {} \\\\;\n" #How to cleanup inputs (very naive) print "clean: find rm error " + output + " " + inputlist print "\tLOCAL find . -maxdepth 1 -name 'input.*' -exec rm {} \\\\; > clean\n" cctools-4.0-source/apps/makeflow_blast/split_fasta0000751060042600000500000000171312175446362021355 0ustar btovardip#! /usr/bin/env python # Copyright (C) 2011- The University of Notre Dame # This software is distributed under the GNU General Public License. # See the file COPYING for details. # # This simple script splits a fasta file into pieces # import sys import re if(len(sys.argv) < 4) : sys.stderr.write("Usage: split_fasta.py query_granularity character_granularity fasta_file\n") sys.exit(1) query_gran = sys.argv[1] char_gran = sys.argv[2] query = sys.argv[3] num_chars = 0 num_queries = 0 num_jobs = 0 FILE = open(query, "r") OF = open("input." + str(num_jobs), "w") for line in FILE: if(re.search('^>', line)): if( num_queries > (int(query_gran) - 1) or num_chars > (int(char_gran) - 1) ): OF.close() num_jobs = num_jobs + 1 num_chars = 0 num_queries = 0 OF = open("input." + str(num_jobs), "w") OF.write(line) else : OF.write(line) num_queries += 1 else : OF.write(line) num_chars += len(line) FILE.close() OF.close() sys.exit(0) cctools-4.0-source/apps/maker_galaxy/0000751060042600000500000000000012175446362016566 5ustar btovardipcctools-4.0-source/apps/maker_galaxy/README0000640060042600000500000000024512175446362017447 0ustar btovardipMAKER and a binding for MAKER to Work Queue is available from the University of Utah. Please see the MAKER home page: http://www.yandell-lab.org/software/maker.html cctools-4.0-source/apps/maker_galaxy/maker.pl0000640060042600000500000000700412175446362020223 0ustar btovardip# #Copyright (C) 2012- The University of Notre Dame #This software is distributed under the GNU General Public License. #See the file COPYING for details. # #!/usr/bin/perl use Getopt::Long; my %opt; GetOptions("genome=s" => \$opt{genome}, "ests=s" => \$opt{ests}, "est_reads=s" => \$opt{est_reads}, "proteins=s" => \$opt{proteins}, "alt_est=s" => \$opt{alt_est}, "est_gff=s" => \$opt{est_gff}, "altest_gff=s" => \$opt{altest_gff}, "protein_gff=s" => \$opt{altest_gff}, "repeat_protein=s" => \$opt{repeat_protein}, "rmlib=s" => \$opt{rmlib}, "rm_gff=s" => \$opt{rm_gff}, "model_gff=s" => \$opt{model_gff}, "pred_gff=s" => \$opt{pred_gff}, "other_gff=s" => \$opt{other_gff}, "organism_type=s" => \$opt{organism_type}, "snap" => \$opt{snap}, "snap_hmm=s" => \$opt{snap_hmm}, "augustus" => \$opt{augustus}, "augustus_hmm=s" => \$opt{augustus_hmm}, "genemark" => \$opt{genemark}, "genemark_hmm=s" => \$opt{genemark_hmm}, "fgenesh" => \$opt{fgenesh}, "fgenesh_param=s" => \$opt{fgenesh_param}, "est2genome" => \$opt{est2genome}, "protein2genome" => \$opt{protein2genome}, "output=s" => \$opt{output}, "error=s" => \$opt{error} ); foreach $el (keys %opt){ if($opt{$el} eq "None"){ $opt{$el} = ""; } $val = $opt{$el}; } #generate the generic control files $result = `maker_wq -CTL`; #read the whole control file in open(FILE, "maker_opts.ctl"); my $text = do{local $/;}; close FILE; #now we need to place all of the options into the control file $val = $opt{genome}; $text =~ s/genome:/genome:$val/; $val = $opt{ests}; $text =~ s/est:/est:$val/; $val = $opt{est_reads}; $text =~ s/est_reads:/est_reads:$val/; $val = $opt{altest}; $text =~ s/altest:/altest:$val/; $val = $opt{est_gff}; $text =~ s/est_gff:/est_gff:$val/; $val = $opt{altest_gff}; $text =~ s/altest_gff:/altest_gff:$val/; $val = $opt{protein}; $text =~ s/protein:/protein:$val/; $val = $opt{protein_gff}; $text =~ s/protein_gff:/protein_gff:$val/; $val = $opt{repeat_protein}; if($val ne ""){ $text =~ s/repeat_protein:.*\/te_proteins.fasta/repeat_protein:$val/; } $val = $opt{rmlib}; $text =~ s/rmlib:/rmlib:$val/; $val = $opt{rm_gff}; $text =~ s/rm_gff:/rm_gff:$val/; $val = $opt{organism_type}; $text =~ s/organism_type:eukaryotic/organism_type:$val/; $val = $opt{snaphmm}; $text =~ s/snaphmm:/snaphmm:$val/; $val = $opt{augustus_hmm}; $text =~ s/augustus_species:/augustus_species:$val/; $val = $opt{genemark_hmm}; $text =~ s/gmhmm:/gmhmm:$val/; $val = $opt{fgenesh_param}; $text =~ s/fgenesh_par_file:/fgenesh_par_file:$val/; $val = $opt{model_gff}; $text =~ s/model_gff:/model_gff:$val/; $val = $opt{pred_gff}; $text =~ s/pred_gff:/pred_gff:$val/; $pred = ""; if($opt{snap}){ $pred .= "snap,"; } if($opt{augustus}){ $pred .= "augustus,"; } if($opt{genemark}){ $pred .= "genemark,"; } if($opt{fgenesh}){ $pred .= "fgenesh,"; } if($opt{est2genome}){ $pred .= "est2genome,"; } if($opt{protein2genome}){ $pred .= "protein2genome,"; } $text =~ s/predictor:/predictor:$pred/; `rm maker_opts.ctl`; open(FILE, ">", "maker_opts.ctl"); print FILE $text; close FILE; #need a pre-designed maker_exe.ctl file that gives the locations of all the executables necessary `cp /path/to/maker_exe.ctl .`; $error = $opt{error}; $output = $opt{output}; print STDERR "maker_wq -N biocompute-a -port -1 >& $error\n"; `maker_wq -N biocompute-a -port -1 >& $error`; `touch output`; print "find . -name \"*.gff\" -exec cat {} \\; >> $output"; `find . -name "*.gff" -exec cat {} \\; >> $output`; cctools-4.0-source/apps/maker_galaxy/maker.xml0000640060042600000500000001447212175446362020417 0ustar btovardip Run MAKER in parallel using work queue maker.pl --genome "$genome" --ests "$ests" --est_reads "$est_reads" --proteins "$proteins" --alt_est "$alt_est" --est_gff "$est_gff" --altest_gff "$altest_gff" --protein_gff "$protein_gff" --repeat_protein "$repeat_protein" --rmlib "$rmlib" --rm_gff "$rm_gff" --model_gff "$model_gff" --pred_gff "$pred_gff" --other_gff "$other_gff" --organism_type "$organism_type" #if $snap_opts.snap == "snap": --snap --snap_hmm "$snap_opts.snap_hmm.value" #end if #if $augustus_opts.augustus == "augustus": --augustus --augustus_hmm "$augustus_opts.augustus_hmm.value" #end if #if $genemark_opts.genemark == "genemark": --genemark --genemark_hmm "$genemark_opts.genemark_hmm.value" #end if #if $fgenesh_opts.fgenesh == "fgenesh": --fgenesh --fgenesh_param "$fgenesh_opts.fgenesh_param.value" #end if #if $est2genome.value == True: --est2genome #end if #if $protein2genome.value == True: --protein2genome #end if --output $output1 --error $error1 cctools-4.0-source/apps/replica_exchange_protomol/0000751060042600000500000000000012175446362021336 5ustar btovardipcctools-4.0-source/apps/replica_exchange_protomol/Makefile0000640060042600000500000000030412175446362022773 0ustar btovardip include ../../Makefile.config include ../../Makefile.rules all: test: install: cp protomol_functions.py ${CCTOOLS_INSTALL_DIR}/bin cp replica_exchange.py ${CCTOOLS_INSTALL_DIR}/bin clean: cctools-4.0-source/apps/replica_exchange_protomol/par_all27_prot_lipid.inp0000640060042600000500000043355512175446362026075 0ustar btovardip*>>>>>> Combined CHARMM All-Hydrogen Parameter File for <<<<<<<<< *>>>>>>>>> CHARMM22 Proteins and CHARMM27 Lipids <<<<<<<<<< *from *>>>> CHARMM22 All-Hydrogen Parameter File for Proteins <<<<<<<<<< *>>>>>>>>>>>>>>>>>>>>>> August 1999 <<<<<<<<<<<<<<<<<<<<<<<<<<<<< *>>>>>>> Direct comments to Alexander D. MacKerell Jr. <<<<<<<<< *>>>>>> 410-706-7442 or email: alex,mmiris.ab.umd.edu <<<<<<<<< *and * \\\\\\\ CHARMM27 All-Hydrogen Lipid Parameter File /////// * \\\\\\\\\\\\\\\\\\ Developmental ///////////////////////// * Alexander D. MacKerell Jr. * August 1999 * All comments to ADM jr. email:alex,mmiris.ab.umd.edu * telephone: 410-706-7442 * ! references ! !PROTEINS ! !MacKerell, Jr., A. D.; Bashford, D.; Bellott, M.; Dunbrack Jr., R.L.; !Evanseck, J.D.; Field, M.J.; Fischer, S.; Gao, J.; Guo, H.; Ha, S.; !Joseph-McCarthy, D.; Kuchnir, L.; Kuczera, K.; Lau, F.T.K.; Mattos, !C.; Michnick, S.; Ngo, T.; Nguyen, D.T.; Prodhom, B.; Reiher, III, !W.E.; Roux, B.; Schlenkrich, M.; Smith, J.C.; Stote, R.; Straub, J.; !Watanabe, M.; Wiorkiewicz-Kuczera, J.; Yin, D.; Karplus, M. All-atom !empirical potential for molecular modeling and dynamics Studies of !proteins. Journal of Physical Chemistry B, 1998, 102, 3586-3616. ! !PHOSPHOTYROSINE ! !Feng, M.-H., Philippopoulos, M., MacKerell, Jr., A.D. and Lim, C. !Structural Characterization of the Phosphotyrosine Binding Region of a !High-Affinity aSH2 Domain-Phosphopeptide Complex by Molecular Dynamics !Simulation and Chemical Shift Calculations. Journal of the American !Chemical Society, 1996, 118: 11265-11277. ! !IONS (see lipid and nucleic acid topology and parameter files for !additional ions ! !ZINC ! !Roland H. Stote and Martin Karplus, Zinc Binding in Proteins and !Solution: A Simple but Accurate Nonbonded Representation, PROTEINS: !Structure, Function, and Genetics 23:12-31 (1995) ! ! !LIPIDS ! !Feller, S. and MacKerell, Jr., A.D. manuscript in preparation ! !and ! !Schlenkrich, M., Brickmann, J., MacKerell, Jr., A.D., and Karplus, M. !Empirical Potential Energy Function for Phospholipids: Criteria for !Parameter Optimization and Applications, in "Biological Membranes: A !Molecular Perspective from Computation and Experiment," K.M. Merz and !B. Roux, Eds. Birkhauser, Boston, 1996, pp 31-81. ! !new ALKANES ! !Yin, D. and MacKerell, Jr. A.D. Combined Ab initio/Empirical Approach !for the Optimization of Lennard-Jones Parameters. Journal of !Computational Chemistry, 1998, 19: 334-338. ! !ALKENES ! !Feller, S.E., Yin, D., Pastor, R.W., and MacKerell, Jr., A.D., !Molecular Dynamics Simulation of Unsaturated Lipids at Low Hydration: !Parameterization and Comparison with Diffraction Studies. Biophysical !Journal, 73:2269-2279, 1997. ! !new PHOSPHATE ! !MacKerell, Jr., A.D. Influence of Water and Sodium on the Energetics !of Dimethylphosphate and its Implications For DNA Structure, Journal !de Chimie Physique, 1997, 94: 1436-1447. ! !IONS ! !all ions from Roux and coworkers ! !Sodium ! !Beglov, D. and Roux, B., Finite Representation of an Infinite !Bulk System: Solvent Boundary Potential for Computer Simulations, !Journal of Chemical Physics, 1994, 100: 9050-9063 ! BONDS ! !V(bond) = Kb(b - b0)**2 ! !Kb: kcal/mole/A**2 !b0: A ! !atom type Kb b0 ! C C 600.000 1.3350 ! ALLOW ARO HEM ! Heme vinyl substituent (KK, from propene (JCS)) CA CA 305.000 1.3750 ! ALLOW ARO ! benzene, JES 8/25/89 CE1 CE1 440.000 1.3400 ! ! for butene; from propene, yin/adm jr., 12/95 CE1 CE2 500.000 1.3420 ! ! for propene, yin/adm jr., 12/95 CE1 CT2 365.000 1.5020 ! ! for butene; from propene, yin/adm jr., 12/95 CE1 CT3 383.000 1.5040 ! ! for butene, yin/adm jr., 12/95 CE2 CE2 510.000 1.3300 ! ! for ethene, yin/adm jr., 12/95 CP1 C 250.000 1.4900 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP1 CC 250.000 1.4900 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP1 CD 200.000 1.4900 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP1 222.500 1.5270 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP2 222.500 1.5370 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 CP2 222.500 1.5370 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CPB C 450.000 1.3800 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CPB CPA 299.800 1.4432 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPB CPB 340.700 1.3464 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPH1 CPH1 410.000 1.3600 ! ALLOW ARO ! histidine, adm jr., 6/27/90 CPM CPA 360.000 1.3716 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPT CA 305.000 1.3680 ! ALLOW ARO ! adm jr., 12/30/91, for jwk CPT CPT 360.000 1.4000 ! ALLOW ARO !adm jr., 12/30/91, for jwk CT1 C 250.000 1.4900 ! ALLOW ALI PEP POL ARO ! Ala Dipeptide ab initio calc's (LK) fixed from 10/90 (5/91) CT1 CC 200.000 1.5220 ! ALLOW POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT1 CD 200.000 1.5220 ! ALLOW POL ! adm jr. 5/02/91, acetic acid pure solvent CT1 CT1 222.500 1.5000 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT2 C 250.000 1.4900 ! ALLOW ALI PEP POL ARO ! Ala Dipeptide ab initio calc's (LK) fixed from 10/90 (5/91) CT2 CA 230.000 1.4900 ! ALLOW ALI ARO ! phe,tyr, JES 8/25/89 CT2 CC 200.000 1.5220 ! ALLOW POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT2 CD 200.000 1.5220 ! ALLOW POL ! adm jr. 5/02/91, acetic acid pure solvent CT2 CPB 230.000 1.4900 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT2 CPH1 229.630 1.5000 ! ALLOW ARO ! his, adm jr., 7/22/89, FC from CT2CT, BL from crystals CT2 CT1 222.500 1.5380 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT2 CT2 222.500 1.5300 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 C 250.000 1.4900 ! ALLOW ALI PEP POL ARO ! Ala Dipeptide ab initio calc's (LK) fixed from 10/90 (5/91) CT3 CA 230.000 1.4900 ! ALLOW ALI ARO ! toluene, adm jr. 3/7/92 CT3 CC 200.000 1.5220 ! ALLOW POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT3 CD 200.000 1.5220 ! ALLOW POL ! adm jr. 5/02/91, acetic acid pure solvent CT3 CPB 230.000 1.4900 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT3 CPH1 229.630 1.5000 ! ALLOW ARO ! his, adm jr., 7/22/89, FC from CT2CT, BL from crystals CT3 CS 190.000 1.5310 ! ALLOW SUL ! ethylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 CT3 CT1 222.500 1.5380 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 CT2 222.500 1.5280 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 CT3 222.500 1.5300 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CY CA 350.000 1.3650 ! ALLOW ARO !adm jr., 5/08/91, indole CCDB structure search CY CPT 350.000 1.4400 ! ALLOW ARO !adm jr., 12/30/91, for jwk CY CT2 230.000 1.5100 ! ALLOW ARO !JWK Kb from alkane freq.. b0 from TRP crystal FE CM 258.000 1.9000 ! ALLOW HEM ! Heme (6-liganded): CO ligand (KK 05/13/91) FE CPM 0.000 3.3814 ! ALLOW HEM ! Heme (6-liganded): for "ic para" only (KK 05/13/91) H CD 330.000 1.1100 ! ALLOW PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent HA C 330.000 1.1000 ! ALLOW ARO HEM ! Heme vinyl substituent (KK, from propene (JCS)) HA CA 340.000 1.0830 ! ALLOW ARO ! trp, adm jr., 10/02/89 HA CC 317.130 1.1000 ! ALLOW POL ! adm jr., 5/13/91, formamide geometry and vibrations HA CP2 309.000 1.1110 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP3 309.000 1.1110 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CPM 367.600 1.0900 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) HA CS 300.000 1.1110 ! ALLOW SUL ! methylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 HA CT1 309.000 1.1110 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT2 309.000 1.1110 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT3 322.000 1.1110 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CY 330.000 1.0800 ! ALLOW ARO ! JWK 05/14/91 new r0 from indole HE1 CE1 360.500 1.1000 ! ! for propene, yin/adm jr., 12/95 HE2 CE2 365.000 1.1000 ! ! for ethene, yin/adm jr., 12/95 HB CP1 330.000 1.0800 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CT1 330.000 1.0800 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT2 330.000 1.0800 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT3 330.000 1.0800 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HP CA 340.000 1.0800 ! ALLOW ARO ! phe,tyr JES 8/25/89 HP CY 350.000 1.0800 ! ALLOW ARO !adm jr., 12/30/91, for jwk HR1 CPH1 375.000 1.0830 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH2 340.000 1.0900 ! ALLOW ARO ! his, adm jr., 6/28/29 HR2 CPH2 333.000 1.0700 ! ALLOW ARO ! his, adm jr., 6/27/90 HR3 CPH1 365.000 1.0830 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HT HT 0.000 1.5139 ! ALLOW WAT ! FROM TIPS3P GEOMETRY (FOR SHAKE/W PARAM) N C 260.000 1.3000 ! ALLOW PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP1 320.000 1.4340 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP3 320.000 1.4550 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NC2 C 463.000 1.3650 ! ALLOW PEP POL ARO ! 403.0->463.0, 1.305->1.365 guanidinium (KK) NC2 CT2 261.000 1.4900 ! ALLOW ALI POL ! arg, (DS) NC2 CT3 261.000 1.4900 ! ALLOW ALI POL ! methylguanidinium, adm jr., 3/26/92 NC2 HC 455.000 1.0000 ! ALLOW POL ! 405.0->455.0 GUANIDINIUM (KK) NH1 C 370.000 1.3450 ! ALLOW PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) NH1 CT1 320.000 1.4300 ! ALLOW ALI PEP POL ARO ! NMA Gas & Liquid Phase IR Spectra (LK) NH1 CT2 320.000 1.4300 ! ALLOW ALI PEP POL ARO ! NMA Gas & Liquid Phase IR Spectra (LK) NH1 CT3 320.000 1.4300 ! ALLOW ALI PEP POL ARO ! NMA Gas & Liquid Phase IR Spectra (LK) NH1 H 440.000 0.9970 ! ALLOW PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) NH1 HC 405.000 0.9800 ! ALLOW PEP POL ARO ! (DS) NH2 CC 430.000 1.3600 ! ALLOW PEP POL ARO ! adm jr. 4/10/91, acetamide NH2 CT2 240.000 1.4550 ! from NH2 CT3, neutral glycine, adm jr. NH2 CT3 240.000 1.4550 ! ALLOW POL ! methylamine geom/freq, adm jr., 6/2/92 NH2 H 480.000 1.0000 ! ALLOW POL ! adm jr. 8/13/90 acetamide geometry and vibrations NH2 HC 460.000 1.0000 ! ALLOW POL ! methylamine geom/freq, adm jr., 6/2/92 NH3 CT1 200.000 1.4800 ! ALLOW ALI POL ! new stretch and bend; methylammonium (KK 03/10/92) NH3 CT2 200.000 1.4800 ! ALLOW ALI POL ! new stretch and bend; methylammonium (KK 03/10/92) NH3 CT3 200.000 1.4800 ! ALLOW ALI POL ! new stretch and bend; methylammonium (KK 03/10/92) NH3 HC 403.000 1.0400 ! ALLOW POL ! new stretch and bend; methylammonium (KK 03/10/92) NP CP1 320.000 1.4850 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP3 320.000 1.5020 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP HC 460.000 1.0060 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NPH CPA 377.200 1.3757 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NPH FE 270.200 1.9580 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NR1 CPH1 400.000 1.3800 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR1 CPH2 400.000 1.3600 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR1 H 466.000 1.0000 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 CPH1 400.000 1.3800 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 CPH2 400.000 1.3200 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 FE 65.000 2.2000 ! ALLOW HEM ! Heme (6-liganded): His ligand (KK 05/13/91) NR3 CPH1 380.000 1.3700 ! ALLOW ARO ! his, adm jr., 6/28/90 NR3 CPH2 380.000 1.3200 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 H 453.000 1.0000 ! ALLOW ARO ! his, adm jr., 6/27/90 NY CA 270.000 1.3700 ! ALLOW ARO !adm jr., 12/30/91, for jwk NY CPT 270.000 1.3750 ! ALLOW ARO !adm jr., 12/30/91, for jwk NY H 465.000 0.9760 ! ALLOW ARO ! indole JWK 08/28/89 O C 620.000 1.2300 ! ALLOW PEP POL ARO ! Peptide geometry, condensed phase (LK) O CC 650.000 1.2300 ! ALLOW PEP POL ARO ! adm jr. 4/10/91, acetamide OB CC 750.000 1.2200 ! ALLOW PEP POL ARO ! adm jr., 10/17/90, acetic acid vibrations and geom. OB CD 750.000 1.2200 ! ALLOW PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent OC CA 525.000 1.2600 ! ALLOW PEP POL ARO ION ! adm jr. 8/27/91, phenoxide OC CC 525.000 1.2600 ! ALLOW PEP POL ARO ION ! adm jr. 7/23/91, acetic acid OC CT2 450.000 1.3300 ! ALLOW ALC ! ethoxide 6-31+G* geom/freq, adm jr., 6/1/92 OC CT3 450.000 1.3300 ! ALLOW ALC ! methoxide 6-31+G* geom/freq, adm jr., 6/1/92 OH1 CA 334.300 1.4110 ! ALLOW ARO ALC ! MeOH, EMB 10/10/89, OH1 CD 230.000 1.4000 ! ALLOW PEP POL ARO ALC ! adm jr. 5/02/91, acetic acid pure solvent OH1 CT1 428.000 1.4200 ! ALLOW ALI ALC ARO ! methanol vib fit EMB 11/21/89 OH1 CT2 428.000 1.4200 ! ALLOW ALI ALC ARO ! methanol vib fit EMB 11/21/89 OH1 CT3 428.000 1.4200 ! ALLOW ALI ALC ARO ! methanol vib fit EMB 11/21/89 OH1 H 545.000 0.9600 ! ALLOW ALC ARO ! EMB 11/21/89 methanol vib fit OM CM 1115.000 1.1280 ! ALLOW HEM ! Heme (6-liganded): CO ligand (KK 05/13/91) OM FE 250.000 1.8000 ! ALLOW HEM ! Heme (6-liganded): O2 ligand (KK 05/13/91) OM OM 600.000 1.2300 ! ALLOW HEM ! Heme (6-liganded): O2 ligand (KK 05/13/91) OS CD 150.000 1.3340 ! ALLOW POL PEP ! adm jr. 5/02/91, acetic acid pure solvent OS CT3 340.000 1.4300 ! ALLOW POL PEP ! adm jr., 4/05/91, for PRES CT1 from methylacetate OT HT 450.000 0.9572 ! ALLOW WAT ! FROM TIPS3P GEOM S CT2 198.000 1.8180 ! ALLOW ALI SUL ION ! fitted to C-S s 9/26/92 (FL) S CT3 240.000 1.8160 ! ALLOW ALI SUL ION ! fitted to C-S s 9/26/92 (FL) S HS 275.000 1.3250 ! ALLOW SUL ION ! methanethiol pure solvent, adm jr., 6/22/92 SM CT2 214.000 1.8160 ! ALLOW SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) SM CT3 214.000 1.8160 ! ALLOW SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) SM SM 173.000 2.0290 ! ALLOW SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) SS CS 205.000 1.8360 ! ALLOW SUL ! methylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 !lipids section CTL3 CL 200.0 1.522 ! methyl acetate CTL2 CL 200.0 1.522 ! methyl acetate CTL1 CL 200.0 1.522 ! methyl acetate OBL CL 750.0 1.220 ! methyl acetate OCL CL 525.0 1.260 ! acetate, protein OSL CL 150.0 1.334 ! methyl acetate OHL CL 230.0 1.40 ! methyl acetate HOL OHL 545.0 0.960 ! acetic acid CTL1 HAL1 309.00 1.111 ! alkanes, 3/92 CTL2 HAL2 309.00 1.111 ! alkanes, 4/98 CTL3 HAL3 322.00 1.111 ! alkanes, 4/98 CTL3 OSL 340.0 1.43 ! phosphate CTL2 OSL 340.0 1.43 ! phosphate CTL1 OSL 340.0 1.43 ! phosphate OSL PL 270.0 1.60 ! phosphate O2L PL 580.0 1.48 ! phosphate OHL PL 237.0 1.59 ! phosphate NH3L HCL 410.0 1.04 ! ethanolamine NH3L CTL2 261.0 1.51 ! ethanolamine NTL CTL2 215.00 1.51 ! tetramethylammonium NTL CTL5 215.00 1.51 ! tetramethylammonium CTL5 HL 300.00 1.08 ! tetramethylammonium CTL2 HL 300.00 1.08 ! tetramethylammonium CTL1 CTL1 222.500 1.500 ! alkanes, 3/92 CTL1 CTL2 222.500 1.538 ! alkanes, 3/92 CTL1 CTL3 222.500 1.538 ! alkanes, 3/92 CTL2 CTL2 222.500 1.530 ! alkanes, 3/92 CTL2 CTL3 222.500 1.528 ! alkanes, 3/92 CTL3 CTL3 222.500 1.530 ! alkanes, 3/92 OHL CTL1 428.0 1.420 ! glycerol OHL CTL2 428.0 1.420 ! glycerol OHL CTL3 428.0 1.420 ! glycerol SL O2L 540.0 1.448 ! methylsulfate SL OSL 250.0 1.575 ! methylsulfate !HT HT 0.0 1.5139 ! from TIPS3P geometry (for SHAKE w/PARAM) !HT OT 450.0 0.9572 ! from TIPS3P geometry CEL2 CEL2 510.000 1.330 ! ethene yin,adm jr., 12/95 HEL2 CEL2 365.000 1.100 ! propene; from ethene, yin,adm jr., 12/95 CEL1 CTL3 383.000 1.504 ! butene, yin,adm jr., 12/95 CEL1 CEL2 500.000 1.342 ! propene, yin,adm jr., 12/95 HEL1 CEL1 360.500 1.100 ! propene, yin,adm jr., 12/95 CEL1 CTL2 365.000 1.502 ! butene; from propene, yin,adm jr., 12/95 CEL1 CEL1 440.000 1.340 ! butene, yin,adm jr., 12/95 ANGLES ! !V(angle) = Ktheta(Theta - Theta0)**2 ! !V(Urey-Bradley) = Kub(S - S0)**2 ! !Ktheta: kcal/mole/rad**2 !Theta0: degrees !Kub: kcal/mole/A**2 (Urey-Bradley) !S0: A ! !atom types Ktheta Theta0 Kub S0 ! CA CA CA 40.000 120.00 35.00 2.41620 ! ALLOW ARO ! JES 8/25/89 CE1 CE1 CT3 48.00 123.50 ! ! for 2-butene, yin/adm jr., 12/95 CE1 CT2 CT3 32.00 112.20 ! ! for 1-butene; from propene, yin/adm jr., 12/95 CE2 CE1 CT2 48.00 126.00 ! ! for 1-butene; from propene, yin/adm jr., 12/95 CE2 CE1 CT3 47.00 125.20 ! ! for propene, yin/adm jr., 12/95 CP1 N C 60.000 117.0000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP1 C 52.000 112.3000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP1 CC 52.000 112.3000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP1 CD 50.000 112.3000 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP2 CP1 70.000 108.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 CP2 CP2 70.000 108.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N C 60.000 117.0000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N CP1 100.000 114.2000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 NP CP1 100.000 111.0000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CPA CPB C 70.000 126.7400 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CPA CPM CPA 94.200 125.1200 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPA NPH CPA 139.300 103.9000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPB C C 70.000 121.5000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CPB CPB C 70.000 126.7500 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CPB CPB CPA 30.800 106.5100 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPH2 NR1 CPH1 130.000 107.5000 ! ALLOW ARO ! his, adm jr., 6/27/90 CPH2 NR2 CPH1 130.000 104.0000 ! ALLOW ARO ! his, adm jr., 6/27/90 CPH2 NR3 CPH1 145.000 108.0000 ! ALLOW ARO ! his, ADM JR., 7/20/89 CPM CPA CPB 61.600 124.0700 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPT CA CA 60.000 118.0000 ! ALLOW ARO !adm jr., 12/30/91, for jwk CPT CPT CA 60.000 122.0000 ! ALLOW ARO !adm jr., 12/30/91, for jwk CPT CY CA 120.000 107.40 25.00 2.26100 ! ALLOW ARO !adm jr., 12/30/91, for jwk CPT NY CA 110.000 108.0000 ! ALLOW ARO !adm jr., 12/30/91, for jwk CT1 CT1 C 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) CT1 CT1 CC 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT1 CT1 CT1 53.350 111.00 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT1 CT2 CA 51.800 107.5000 ! ALLOW ALI ARO ! PARALLH19 (JES) CT1 CT2 CC 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT1 CT2 CD 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent CT1 CT2 CPH1 58.350 113.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, from CT2CT2CT, U-B omitted CT1 CT2 CT1 58.350 113.50 11.16 2.56100 ! ALLOW ALI ! alkane frequencies (MJF), alkane geometries (SF) CT1 NH1 C 50.000 120.0000 ! ALLOW ALI PEP POL ARO ! NMA Vib Modes (LK) CT2 CA CA 45.800 122.3000 ! ALLOW ALI ARO ! PARALLH19 (JES) CT2 CPB CPA 65.000 126.7400 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT2 CPB CPB 65.000 126.7500 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT2 CPH1 CPH1 45.800 130.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, FC=>CT2CA CA,BA=> CRYSTALS CT2 CT1 C 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) CT2 CT1 CC 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT2 CT1 CD 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent CT2 CT1 CT1 53.350 111.00 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT2 CT2 C 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! from CT2 CT1 C, for lactams, adm jr. CT2 CT2 CC 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/05/91, for asn,asp,gln,glu and cters CT2 CT2 CD 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent CT2 CT2 CPB 70.000 113.0000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT2 CT2 CT1 58.350 113.50 11.16 2.56100 ! ALLOW ALI ! alkane frequencies (MJF), alkane geometries (SF) CT2 CT2 CT2 58.350 113.60 11.16 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT2 CT3 CT1 58.350 113.50 11.16 2.56100 ! ALLOW ALI ! alkane frequencies (MJF), alkane geometries (SF) CT2 CY CA 45.800 129.4000 ! ALLOW ARO !adm jr., 5/08/91, indole CCDB structure search CT2 CY CPT 45.800 124.0000 ! ALLOW ARO !adm jr., 5/08/91, indole CCDB structure search CT2 NC2 C 62.300 120.0000 ! ALLOW ALI POL PEP ARO ! 107.5->120.0 to make planar Arg (KK) CT2 NH1 C 50.000 120.0000 ! ALLOW ALI PEP POL ARO ! NMA Vib Modes (LK) CT2 OS CD 40.000 109.60 30.00 2.26510 ! ALLOW POL PEP ! adm jr. 5/02/91, acetic acid pure solvent CT3 CA CA 45.800 122.3000 ! ALLOW ALI ARO ! toluene, adm jr., 3/7/92 CT3 CPB CPA 65.000 126.7400 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT3 CPB CPB 65.000 126.7500 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT3 CPH1 CPH1 45.800 130.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, FC=>CT2CA CA,BA=> CRYSTALS CT3 CT1 C 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) CT3 CT1 CC 52.000 108.0000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/09/92, for ALA cter CT3 CT1 CT1 53.350 108.50 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 CT1 CT2 53.350 114.00 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 CT1 CT3 53.350 114.00 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 CT2 CA 51.800 107.5000 ! ALLOW ALI ARO ! ethylbenzene, adm jr., 3/7/92 CT3 CT2 CPH1 58.350 113.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, from CT2CT2CT, U-B omitted CT3 CT2 CT1 58.350 113.50 11.16 2.56100 ! ALLOW ALI ! alkane frequencies (MJF), alkane geometries (SF) CT3 CT2 CT2 58.000 115.00 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 CT2 CT3 53.350 114.00 8.00 2.56100 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CT3 NC2 C 62.300 120.0000 ! ALLOW ALI POL PEP ARO ! methylguanidinium, adm jr., 3/26/92 CT3 NH1 C 50.000 120.0000 ! ALLOW ALI PEP POL ARO ! NMA Vib Modes (LK) CT3 OS CD 40.000 109.60 30.00 2.26510 ! ALLOW POL PEP ! adm jr. 5/02/91, acetic acid pure solvent CT3 S CT2 34.000 95.0000 ! ALLOW ALI SUL ION ! expt. MeEtS, 3/26/92 (FL) CY CPT CA 160.000 130.6000 ! ALLOW ARO !adm jr., 12/30/91, for jwk CY CPT CPT 110.000 107.4000 ! ALLOW ARO !adm jr., 12/30/91, for jwk CY CT2 CT1 58.350 114.0000 ! ALLOW ARO ! from TRP crystal, JWK CY CT2 CT3 58.350 114.0000 ! ALLOW ARO ! from TRP crystal, JWK FE NPH CPA 96.150 128.0500 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) FE NR2 CPH1 30.000 133.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) FE NR2 CPH2 30.000 123.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) H NH1 C 34.000 123.0000 ! ALLOW PEP POL ARO ! NMA Vib Modes (LK) H NH1 CT1 35.000 117.0000 ! ALLOW PEP POL ARO ALI ! NMA Vibrational Modes (LK) H NH1 CT2 35.000 117.0000 ! ALLOW PEP POL ARO ALI ! NMA Vibrational Modes (LK) H NH1 CT3 35.000 117.0000 ! ALLOW PEP POL ARO ALI ! NMA Vibrational Modes (LK) H NH2 CC 50.000 120.0000 ! ALLOW POL PEP ARO ! his, adm jr. 8/13/90 acetamide geometry and vibrations H NH2 H 23.000 120.0000 ! ALLOW POL ! adm jr. 8/13/90 acetamide geometry and vibrations H NR1 CPH1 30.000 125.50 20.00 2.15000 ! ALLOW ARO ! his, adm jr., 6/27/90 H NR1 CPH2 30.000 127.00 20.00 2.14000 ! ALLOW ARO ! his, adm jr., 6/27/90 H NR3 CPH1 25.000 126.00 15.00 2.13000 ! ALLOW ARO ! his, adm jr., 6/27/90 H NR3 CPH2 25.000 126.00 15.00 2.09000 ! ALLOW ARO ! his, adm jr., 6/27/90 H NY CA 28.000 126.0000 ! ALLOW ARO !adm jr., 12/30/91, for jwk H NY CPT 28.000 126.0000 ! ALLOW ARO !adm jr., 12/30/91, for jwk H OH1 CA 65.000 108.0000 ! ALLOW ALC ARO ! JES 8/25/89 phenol H OH1 CD 55.000 115.0000 ! ALLOW ALC ARO PEP POL ! adm jr. 5/02/91, acetic acid pure solvent H OH1 CT1 57.500 106.0000 ! ALLOW ALC ARO ALI ! methanol vib fit EMB 11/21/89 H OH1 CT2 57.500 106.0000 ! ALLOW ALC ARO ALI ! methanol vib fit EMB 11/21/89 H OH1 CT3 57.500 106.0000 ! ALLOW ALC ARO ALI ! methanol vib fit EMB 11/21/89 HA C C 50.000 120.5000 ! ALLOW PEP POL ARO ! Heme vinyl substituent (KK from propene (JCS)) HA C CPB 50.000 120.0000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) HA C HA 50.000 118.0000 ! ALLOW PEP POL ARO ! Heme vinyl substituent (KK from propene (JCS)) HA CA CA 29.000 120.00 25.00 2.15250 ! ALLOW ARO ! trp, adm jr., 10/02/89 HA CA CPT 41.000 122.0000 ! ALLOW ARO !adm jr., 5/08/91, indole CCDB structure search HA CA CY 32.000 125.00 25.00 2.17300 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole HA CP2 CP1 33.430 110.10 22.53 2.17900 ! ALLOW ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP2 CP2 26.500 110.10 22.53 2.17900 ! ALLOW ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP2 CP3 26.500 110.10 22.53 2.17900 ! ALLOW ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP2 HA 35.500 109.00 5.40 1.80200 ! ALLOW ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP3 CP2 26.500 110.10 22.53 2.17900 ! ALLOW ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP3 HA 35.500 109.00 5.40 1.80200 ! ALLOW ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CPM CPA 12.700 117.4400 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) HA CPM FE 0.000 180.0000 ! ALLOW HEM ! Heme (6-liganded): for "ic para" only (KK 05/13/91) HA CS CT3 34.600 110.10 22.53 2.17900 ! ALLOW SUL ! ethylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 HA CS HA 35.500 108.40 14.00 1.77500 ! ALLOW SUL ! methylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 HA CT1 C 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! alanine dipeptide, LK, replaced, adm jr., 5/09/91 HA CT1 CD 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent HA CT1 CT1 34.500 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT1 CT2 34.500 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT1 CT3 34.500 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT1 HA 35.500 109.00 5.40 1.80200 ! TEST for test cpd ! based on HA CT2 HA HA CT2 C 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! alanine dipeptide, LK, replaced, adm jr., 5/09/91 HA CT2 CA 49.300 107.5000 ! ALLOW ALI ARO ! PARALLH19 (JES) HA CT2 CC 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! adm jr. 4/05/91, for asn,asp,gln,glu and cters HA CT2 CD 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent HA CT2 CE1 45.00 111.50 ! ! for 1-butene; from propene, yin/adm jr., 12/95 HA CT2 CPB 50.000 109.5000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) HA CT2 CPH1 33.430 109.5000 ! ALLOW ARO ! his, ADM JR., 7/22/89, from CT2CT2HA, U-B OMITTED HA CT2 CT1 33.430 110.10 22.53 2.17900 ! ALLOW ALI ! alkane frequencies (MJF), alkane geometries (SF) HA CT2 CT2 26.500 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT2 CT3 34.600 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT2 CY 33.430 109.5000 ! ALLOW ARO ! ADM JR., 10/02/89, from CT2CT2HA (U-B OMITTED), FOR JOANNA HA CT2 HA 35.500 109.00 5.40 1.80200 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT3 C 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! alanine dipeptide, LK, replaced, adm jr., 5/09/91 HA CT3 CA 49.300 107.5000 ! ALLOW ALI ARO ! toluene, adm jr. 3/7/92 HA CT3 CC 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! adm jr. 4/05/91, for asn,asp,gln,glu and cters HA CT3 CD 33.000 109.50 30.00 2.16300 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent HA CT3 CE1 42.00 111.50 ! ! for 2-butene, yin/adm jr., 12/95 HA CT3 CPB 50.000 109.5000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) HA CT3 CPH1 33.430 109.5000 ! ALLOW ARO ! his, ADM JR., 7/22/89, from CT2CT2HA, U-B OMITTED HA CT3 CS 34.600 110.10 22.53 2.17900 ! ALLOW SUL ! ethylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 HA CT3 CT1 33.430 110.10 22.53 2.17900 ! ALLOW ALI ! alkane frequencies (MJF), alkane geometries (SF) HA CT3 CT2 34.600 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT3 CT3 37.500 110.10 22.53 2.17900 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CT3 HA 35.500 108.40 5.40 1.80200 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 HA CY CA 20.000 126.40 25.00 2.18600 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole HA CY CPT 32.000 126.40 25.00 2.25500 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole HE1 CE1 CE1 52.00 119.50 ! ! for 2-butene, yin/adm jr., 12/95 HE1 CE1 CE2 42.00 118.00 ! ! for propene, yin/adm jr., 12/95 HE1 CE1 CT2 40.00 116.00 ! ! for 1-butene; from propene, yin/adm jr., 12/95 HE1 CE1 CT3 22.00 117.00 ! ! for propene, yin/adm jr., 12/95 HE2 CE2 CE1 45.00 120.50 ! ! for propene, yin/adm jr., 12/95 HE2 CE2 CE2 55.50 120.50 ! ! for ethene, yin/adm jr., 12/95 HE2 CE2 HE2 19.00 119.00 ! ! for propene, yin/adm jr., 12/95 HB CP1 C 50.000 112.0000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CP1 CC 50.000 112.0000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CP1 CD 50.000 112.0000 ! ALLOW PEP POL PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CP1 CP2 35.000 118.0000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CT1 C 50.000 109.5000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT1 CC 50.000 109.5000 ! ALLOW PEP POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters HB CT1 CD 50.000 109.5000 ! ALLOW PEP POL ! adm jr. 5/02/91, acetic acid pure solvent HB CT1 CT1 35.000 111.0000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT1 CT2 35.000 111.0000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT1 CT3 35.000 111.0000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT2 C 50.000 109.5000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT2 CC 50.000 109.5000 ! ALLOW PEP POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters HB CT2 CD 50.000 109.5000 ! ALLOW PEP POL ! adm jr. 5/02/91, acetic acid pure solvent HB CT2 HB 36.000 115.0000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT3 C 50.000 109.5000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HC NC2 C 49.000 120.0000 ! ALLOW POL PEP ARO ! 35.3->49.0 GUANIDINIUM (KK) HC NC2 CT2 40.400 120.0000 ! ALLOW POL ALI ! 107.5->120.0 to make planar Arg (KK) HC NC2 CT3 40.400 120.0000 ! ALLOW POL ALI ! methylguanidinium, adm jr., 3/26/92 HC NC2 HC 25.000 120.0000 ! ALLOW POL ! 40.0->25.0 GUANIDINIUM (KK) HC NH2 CT2 50.000 111.0000 ! ALLOW POL ! from HC NH2 CT3, neutral glycine, adm jr. HC NH2 CT3 50.000 111.0000 ! ALLOW POL ! methylamine geom/freq, adm jr., 6/2/92 HC NH2 HC 39.000 106.5000 ! ALLOW POL ! 40.0->25.0 GUANIDINIUM (KK) HC NH3 CT1 30.000 109.50 20.00 2.07400 ! ALLOW POL ALI ! new stretch and bend; methylammonium (KK 03/10/92) HC NH3 CT2 30.000 109.50 20.00 2.07400 ! ALLOW POL ALI ! new stretch and bend; methylammonium (KK 03/10/92) HC NH3 CT3 30.000 109.50 20.00 2.07400 ! ALLOW POL ALI ! new stretch and bend; methylammonium (KK 03/10/92) HC NH3 HC 44.000 109.5000 ! ALLOW POL ! new stretch and bend; methylammonium (KK 03/10/92) HC NP CP1 33.000 109.50 4.00 2.05600 ! ALLOW POL ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP3 33.000 109.50 4.00 2.05600 ! ALLOW POL ALI PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP HC 51.000 107.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HP CA CA 30.000 120.00 22.00 2.15250 ! ALLOW ARO ! JES 8/25/89 benzene HP CA CPT 30.000 122.00 22.00 2.14600 ! ALLOW ARO !adm jr., 12/30/91, for jwk HP CA CY 32.000 125.00 25.00 2.17300 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole HP CY CA 32.000 126.40 25.00 2.18600 ! ALLOW ARO !adm jr., 12/30/91, for jwk HP CY CPT 32.000 126.40 25.00 2.25500 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole HR1 CPH1 CPH1 22.000 130.00 15.00 2.21500 ! ALLOW ARO ! adm jr., 6/27/90, his HR3 CPH1 CPH1 25.000 130.00 20.00 2.20000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HS S CT2 38.800 95.0000 ! ALLOW SUL ION ALI ! methanethiol pure solvent, adm jr., 6/22/92 HS S CT3 43.000 95.0000 ! ALLOW SUL ION ALI ! methanethiol pure solvent, adm jr., 6/22/92 HT OT HT 55.000 104.5200 ! ALLOW WAT ! TIP3P GEOMETRY, ADM JR. N C CP1 20.000 112.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT1 20.000 112.5000 ! ALLOW ALI PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT2 20.000 112.5000 ! ALLOW ALI PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT3 20.000 112.5000 ! ALLOW ALI PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP1 C 50.000 108.2000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP1 CC 50.000 108.2000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP1 CD 50.000 108.2000 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP1 CP2 70.000 110.8000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP1 HB 48.000 112.0000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP3 CP2 70.000 110.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CP3 HA 48.000 108.0000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NC2 C NC2 52.000 120.00 90.00 2.36420 ! ALLOW POL PEP ARO ! changed from 60.0/120.3 for guanidinium (KK) NC2 CT2 CT2 67.700 107.5000 ! ALLOW ALI POL ! arg, (DS) NC2 CT2 HA 51.500 107.5000 ! ALLOW ALI POL ! arg, (DS) NC2 CT3 HA 51.500 107.5000 ! ALLOW ALI POL ! methylguanidinium, adm jr., 3/26/92 NH1 C CP1 80.000 116.5000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CT1 80.000 116.5000 ! ALLOW ALI PEP POL ARO ! NMA Vib Modes (LK) NH1 C CT2 80.000 116.5000 ! ALLOW ALI PEP POL ARO ! NMA Vib Modes (LK) NH1 C CT3 80.000 116.5000 ! ALLOW ALI PEP POL ARO ! NMA Vib Modes (LK) NH1 CT1 C 50.000 107.0000 ! ALLOW PEP POL ARO ALI ! Alanine Dipeptide ab initio calc's (LK) NH1 CT1 CC 50.000 107.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 4/05/91, for asn,asp,gln,glu and cters NH1 CT1 CD 50.000 107.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 5/02/91, acetic acid pure solvent NH1 CT1 CT1 70.000 113.5000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) NH1 CT1 CT2 70.000 113.5000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) NH1 CT1 CT3 70.000 113.5000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) NH1 CT1 HB 48.000 108.0000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) NH1 CT2 C 50.000 107.0000 ! ALLOW PEP POL ARO ALI ! Alanine Dipeptide ab initio calc's (LK) NH1 CT2 CC 50.000 107.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 5/20/92, for asn,asp,gln,glu and cters NH1 CT2 CD 50.000 107.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 5/02/91, acetic acid pure solvent NH1 CT2 CT2 70.000 113.5000 ! ALLOW ALI PEP POL ARO ! from NH1 CT1 CT2, for lactams, adm jr. NH1 CT2 HA 51.500 109.5000 ! ALLOW ALI PEP POL ARO ! from NH1 CT3 HA, for lactams, adm jr. NH1 CT2 HB 48.000 108.0000 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) NH1 CT3 HA 51.500 109.5000 ! ALLOW ALI PEP POL ARO ! NMA crystal (JCS) NH2 CC CP1 80.000 112.5000 ! ALLOW ALI PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CT1 50.000 116.50 50.00 2.45000 ! ALLOW ALI PEP POL ARO ! adm jr. 8/13/90 acetamide geometry and vibrations NH2 CC CT2 50.000 116.50 50.00 2.45000 ! ALLOW ALI PEP POL ARO ! adm jr. 8/13/90 acetamide geometry and vibrations NH2 CC CT3 50.000 116.50 50.00 2.45000 ! ALLOW ALI PEP POL ARO ! adm jr. 8/13/90 acetamide geometry and vibrations NH2 CC HA 44.000 111.00 50.00 1.98000 ! ALLOW POL ! adm jr., 5/13/91, formamide geometry and vibrations NH2 CT2 HB 38.000 109.50 50.00 2.14000 !from NH2 CT3 HA, neutral glycine, adm jr. NH2 CT2 CD 52.000 108.0000 !from CT2 CT2 CD, neutral glycine, adm jr. NH2 CT3 HA 38.000 109.50 50.00 2.14000 ! ALLOW POL ! methylamine geom/freq, adm jr., 6/2/92 NH3 CT1 C 43.700 110.0000 ! ALLOW PEP POL ARO ALI ! new aliphatics, adm jr., 2/3/92 NH3 CT1 CC 43.700 110.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 4/05/91, for asn,asp,gln,glu and cters NH3 CT1 CT1 67.700 110.0000 ! ALLOW ALI POL ! new aliphatics, adm jr., 2/3/92 NH3 CT1 CT2 67.700 110.0000 ! ALLOW ALI POL ! new aliphatics, adm jr., 2/3/92 NH3 CT1 CT3 67.700 110.0000 ! ALLOW ALI POL ! new aliphatics, adm jr., 2/3/92 NH3 CT1 HB 51.500 107.5000 ! ALLOW ALI POL PEP ! new aliphatics, adm jr., 2/3/92 NH3 CT2 C 43.700 110.0000 ! ALLOW PEP POL ARO ALI ! alanine (JCS) NH3 CT2 CC 43.700 110.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 4/05/91, for asn,asp,gln,glu and cters NH3 CT2 CD 43.700 110.0000 ! ALLOW PEP POL ARO ALI ! adm jr. 5/02/91, acetic acid pure solvent NH3 CT2 CT2 67.700 110.0000 ! ALLOW ALI POL ! alanine (JCS) NH3 CT2 HA 45.000 107.50 35.00 2.10100 ! ALLOW ALI POL ! new stretch and bend; methylammonium (KK 03/10/92) NH3 CT2 HB 51.500 107.5000 ! ALLOW ALI POL PEP ! for use on NTER -- from NH3 CT2HA (JCS) -- (LK) NH3 CT3 HA 45.000 107.50 35.00 2.10100 ! ALLOW ALI POL ! new stretch and bend; methylammonium (KK 03/10/92) NP CP1 C 50.000 106.0000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP1 CC 50.000 106.0000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP1 CD 50.000 106.0000 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP1 CP2 70.000 108.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP1 HB 51.500 107.5000 ! ALLOW ALI POL PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP3 CP2 70.000 108.5000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP3 HA 51.500 109.1500 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NPH CPA CPB 122.000 111.5400 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NPH CPA CPM 88.000 124.3900 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NPH FE CM 50.000 90.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) NPH FE CPM 0.000 45.0000 ! ALLOW HEM ! Heme (6-liganded): for "ic para" only (KK 05/13/91) NPH FE NPH 14.390 90.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NR1 CPH1 CPH1 130.000 106.0000 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR1 CPH1 CT2 45.800 124.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, FC FROM CA CT2CT NR1 CPH1 CT3 45.800 124.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, FC FROM CA CT2CT NR1 CPH1 HR3 25.000 124.00 20.00 2.14000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params NR1 CPH2 HR1 25.000 122.50 20.00 2.14000 ! ALLOW ARO ! his, adm jr., 6/27/90 NR2 CPH1 CPH1 130.000 110.0000 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 CPH1 CT2 45.800 120.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, FC FROM CA CT2CT NR2 CPH1 HR3 25.000 120.00 20.00 2.14000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params NR2 CPH2 HR1 25.000 125.00 20.00 2.12000 ! ALLOW ARO ! his, adm jr., 6/27/90 NR2 CPH2 NR1 130.000 112.5000 ! ALLOW ARO ! his, adm jr., 6/27/90 NR2 FE CM 50.000 180.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) NR2 FE NPH 50.000 90.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) NR3 CPH1 CPH1 145.000 108.0000 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR3 CPH1 CT2 45.800 122.0000 ! ALLOW ARO ! his, ADM JR., 7/22/89, FC FROM CA CT2CT NR3 CPH1 HR1 22.000 122.00 15.00 2.18000 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH2 HR2 32.000 126.00 25.00 2.14000 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH2 NR3 145.000 108.0000 ! ALLOW ARO ! his, ADM JR., 7/20/89 NY CA CY 120.000 110.00 25.00 2.24000 ! ALLOW ARO !adm jr., 12/30/91, for jwk NY CA HA 32.000 125.00 25.00 2.17700 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole NY CA HP 32.000 125.00 25.00 2.17700 ! ALLOW ARO ! JWK 05/14/91 new theta0 and r0UB from indole NY CPT CA 160.000 130.6000 ! ALLOW ARO !adm jr., 12/30/91, for jwk NY CPT CPT 110.000 107.4000 ! ALLOW ARO !adm jr., 12/30/91, for jwk O C CP1 80.000 118.0000 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C CT1 80.000 121.0000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) O C CT2 80.000 121.0000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) O C CT3 80.000 121.0000 ! ALLOW ALI PEP POL ARO ! Alanine Dipeptide ab initio calc's (LK) O C H 50.000 121.7000 ! ALLOW PEP POL ARO ! acetaldehyde (JCS) O C N 80.000 122.5000 ! ALLOW PRO PEP POL ARO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C NH1 80.000 122.5000 ! ALLOW PEP POL ARO ! NMA Vib Modes (LK) O CC CP1 80.000 118.0000 ! ALLOW ALI PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O CC CT1 15.000 121.00 50.00 2.44000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/10/91, acetamide update O CC CT2 15.000 121.00 50.00 2.44000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/10/91, acetamide update O CC CT3 15.000 121.00 50.00 2.44000 ! ALLOW ALI PEP POL ARO ! adm jr. 4/10/91, acetamide update O CC HA 44.000 122.0000 ! ALLOW POL ! adm jr., 5/13/91, formamide geometry and vibrations O CC NH2 75.000 122.50 50.00 2.37000 ! ALLOW POL PEP ARO ! adm jr. 4/10/91, acetamide update OB CD CP1 70.000 125.00 20.00 2.44200 ! ALLOW ALI PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OB CD CT1 70.000 125.00 20.00 2.44200 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent OB CD CT2 70.000 125.00 20.00 2.44200 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent OB CD CT3 70.000 125.00 20.00 2.44200 ! ALLOW ALI PEP POL ARO ! adm jr. 5/02/91, acetic acid pure solvent OC CA CA 40.000 120.0000 ! ALLOW POL ARO ! adm jr. 8/27/91, phenoxide OC CC CP1 40.000 118.00 50.00 2.38800 ! ALLOW ALI PEP POL ARO ION PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OC CC CT1 40.000 118.00 50.00 2.38800 ! ALLOW ALI PEP POL ARO ION ! adm jr. 7/23/91, correction, ACETATE (KK) OC CC CT2 40.000 118.00 50.00 2.38800 ! ALLOW ALI PEP POL ARO ION ! adm jr. 7/23/91, correction, ACETATE (KK) OC CC CT3 40.000 118.00 50.00 2.38800 ! ALLOW ALI PEP POL ARO ION ! adm jr. 7/23/91, correction, ACETATE (KK) OC CC OC 100.000 124.00 70.00 2.22500 ! ALLOW POL ION PEP ARO ! adm jr. 7/23/91, correction, ACETATE (KK) OC CT2 CT3 65.000 122.0000 ! ALLOW ALC ! ethoxide 6-31+G* geom/freq, adm jr., 6/1/92 OC CT2 HA 65.000 118.3000 ! ALLOW ALC ! ethoxide 6-31+G* geom/freq, adm jr., 6/1/92 OC CT3 HA 65.000 118.3000 ! ALLOW ALC ! methoxide 6-31+G* geom/freq, adm jr., 6/1/92 OH1 CA CA 45.200 120.0000 ! ALLOW ARO ALC ! PARALLH19 WITH [122.3] (JES) OH1 CD CT2 55.000 110.5000 ! ALLOW ALI PEP POL ARO ALC ! adm jr, 10/17/90, acetic acid vibrations OH1 CD CT3 55.000 110.5000 ! ALLOW ALI PEP POL ARO ALC ! adm jr, 10/17/90, acetic acid vibrations OH1 CD OB 50.000 123.00 210.00 2.26200 ! ALLOW PEP POL ARO ALC ! adm jr, 10/17/90, acetic acid vibrations OH1 CT1 CT1 75.700 110.1000 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT1 CT3 75.700 110.1000 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT1 HA 45.900 108.8900 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT2 CT1 75.700 110.1000 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT2 CT2 75.700 110.1000 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT2 CT3 75.700 110.1000 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT2 HA 45.900 108.8900 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OH1 CT3 HA 45.900 108.8900 ! ALLOW ALI ALC ARO ! MeOH, EMB, 10/10/89 OM CM FE 35.000 180.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) OM FE NPH 5.000 90.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) OM OM FE 0.000 180.0000 ! ALLOW HEM ! Heme (6-liganded): ligand links (KK 05/13/91) OS CD CP1 55.000 109.00 20.00 2.32600 ! ALLOW POL PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OS CD CT1 55.000 109.00 20.00 2.32600 ! ALLOW POL PEP ! adm jr., 4/05/91, for PRES CT1 from methylacetate OS CD CT2 55.000 109.00 20.00 2.32600 ! ALLOW POL PEP ! adm jr., 4/05/91, for PRES CT1 from methylacetate OS CD CT3 55.000 109.00 20.00 2.32600 ! ALLOW POL PEP ! adm jr., 4/05/91, for PRES CT1 from methylacetate OS CD OB 90.000 125.90 160.00 2.25760 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate OS CT2 HA 60.000 109.5000 ! ALLOW PEP POL ! adm jr. 4/05/91, for PRES CT1 from methyl acetate OS CT3 HA 60.000 109.5000 ! ALLOW PEP POL ! adm jr. 4/05/91, for PRES CT1 from methyl acetate S CT2 CT1 58.000 112.5000 ! ALLOW ALI SUL ION ! as in expt.MeEtS & DALC crystal, 5/15/92 S CT2 CT2 58.000 114.5000 ! ALLOW ALI SUL ION ! expt. MeEtS, 3/26/92 (FL) S CT2 CT3 58.000 114.5000 ! ALLOW ALI SUL ION ! expt. MeEtS, 3/26/92 (FL) S CT2 HA 46.100 111.3000 ! ALLOW ALI SUL ION ! vib. freq. and HF/6-31G* geo. (DTN) 8/24/90 S CT3 HA 46.100 111.3000 ! ALLOW ALI SUL ION ! vib. freq. and HF/6-31G* geo. (DTN) 8/24/90 SM CT2 CT1 58.000 112.5000 ! ALLOW ALI SUL ION ! as in expt.MeEtS & DALC crystal, 5/15/92 SM CT2 HA 38.000 111.0000 ! ALLOW ALI SUL ION ! new S-S atom type 8/24/90 SM CT3 HA 38.000 111.0000 ! ALLOW ALI SUL ION ! new S-S atom type 8/24/90 SM SM CT2 72.500 103.3000 ! ALLOW ALI SUL ION ! expt. dimethyldisulfide, 3/26/92 (FL) SM SM CT3 72.500 103.3000 ! ALLOW ALI SUL ION ! expt. dimethyldisulfide, 3/26/92 (FL) SS CS CT3 55.000 118.0000 ! ALLOW SUL ! ethylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 SS CS HA 40.000 112.3000 ! ALLOW SUL ! methylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 !lipids section OBL CL CTL3 70.0 125.0 20.0 2.442 ! methyl acetate OBL CL CTL2 70.0 125.0 20.0 2.442 ! methyl acetate OBL CL CTL1 70.0 125.0 20.0 2.442 ! methyl acetate OSL CL OBL 90.0 125.9 160.0 2.2576 ! acetic acid CL OSL CTL1 40.0 109.6 30.0 2.2651 ! methyl acetate CL OSL CTL2 40.0 109.6 30.0 2.2651 ! methyl acetate CL OSL CTL3 40.0 109.6 30.0 2.2651 ! methyl acetate HAL2 CTL2 CL 33.00 109.50 30.00 2.163 ! methyl acetate HAL3 CTL3 CL 33.00 109.50 30.00 2.163 ! methyl acetate CTL2 CTL2 CL 52.0 108.00 ! alkane CTL3 CTL2 CL 52.0 108.00 ! alkane OSL CL CTL3 55.0 109.0 20.00 2.3260 ! methyl acetate OSL CL CTL2 55.0 109.0 20.00 2.3260 ! methyl acetate OHL CL OBL 50.0 123.0 210.0 2.2620 ! acetic acid OCL CL CTL2 40.0 118.0 50.0 2.3880 ! acetate OCL CL CTL3 40.0 118.0 50.0 2.3880 ! acetate OCL CL OCL 100.0 124.0 70.0 2.2250 ! acetate OHL CL CTL3 55.0 110.50 ! acetic acid OHL CL CTL2 55.0 110.50 ! acetic acid HOL OHL CL 55.0 115.0 ! acetic acid OSL CTL1 CTL2 75.700 110.10 ! acetic acid OSL CTL1 CTL3 75.700 110.10 ! acetic acid OSL CTL2 CTL1 75.700 110.10 ! acetic acid OSL CTL2 CTL2 75.700 110.10 ! acetic acid OSL CTL2 CTL3 75.700 110.10 ! acetic acid HAL2 CTL2 HAL2 35.500 109.00 5.40 1.80200 ! alkane, 3/92 HAL3 CTL3 HAL3 35.500 108.40 5.40 1.80200 ! alkane, 3/92 HAL1 CTL1 OSL 60.0 109.5 ! phosphate HAL2 CTL2 OSL 60.0 109.5 ! phosphate HAL3 CTL3 OSL 60.0 109.5 ! phosphate CTL2 OSL PL 20.0 120.0 35.0 2.33 ! phosphate CTL3 OSL PL 20.0 120.0 35.0 2.33 ! phosphate HOL OHL PL 30.0 115.0 40.0 2.30 ! phosphate OSL PL OSL 80.0 104.3 ! phosphate OSL PL O2L 98.9 111.6 ! phosphate OSL PL OHL 48.1 108.0 ! phosphate O2L PL O2L 120.0 120.0 ! phosphate O2L PL OHL 98.9 108.23 ! phosphate NTL CTL2 HL 40.0 109.5 27. 2.13 ! tetramethylammonium NTL CTL5 HL 40.0 109.5 27. 2.13 ! tetramethylammonium HL CTL2 HL 24.0 109.50 28. 1.767 ! tetramethylammonium HL CTL5 HL 24.0 109.50 28. 1.767 ! tetramethylammonium CTL5 NTL CTL2 60.0 109.5 26. 2.466 ! tetramethylammonium CTL5 NTL CTL5 60.0 109.5 26. 2.466 ! tetramethylammonium HL CTL2 CTL2 33.430 110.10 22.53 2.179 ! alkane HL CTL2 CTL3 33.430 110.10 22.53 2.179 ! alkane HAL1 CTL1 CTL1 34.500 110.10 22.53 2.179 ! alkane, 3/92 HAL1 CTL1 CTL2 34.500 110.10 22.53 2.179 ! alkane, 3/92 HAL1 CTL1 CTL3 34.500 110.10 22.53 2.179 ! alkane, 3/92 HAL2 CTL2 CTL1 26.500 110.10 22.53 2.179 ! alkane, 4/98 HAL2 CTL2 CTL2 26.500 110.10 22.53 2.179 ! alkane, 4/98 HAL2 CTL2 CTL3 34.600 110.10 22.53 2.179 ! alkane, 4/98 HAL3 CTL3 CTL1 33.430 110.10 22.53 2.179 ! alkane, 4/98 HAL3 CTL3 CTL2 34.600 110.10 22.53 2.179 ! alkane, 4/98 HAL3 CTL3 CTL3 37.500 110.10 22.53 2.179 ! alkane, 4/98 NTL CTL2 CTL2 67.7 115.00 ! tetramethylammonium NTL CTL2 CTL3 67.7 115.00 ! tetramethylammonium HCL NH3L CTL2 33.0 109.50 4.00 2.056 ! ethanolamine HCL NH3L HCL 41.0 109.50 ! ethanolamine NH3L CTL2 CTL2 67.7 110.00 ! ethanolamine NH3L CTL2 HAL2 45.0 107.50 35.00 2.0836 ! ethanolamine CTL1 CTL1 CTL1 53.350 111.00 8.00 2.561 ! alkane, 3/92 CTL1 CTL1 CTL2 58.350 113.50 11.16 2.561 ! glycerol CTL1 CTL1 CTL3 53.350 108.50 8.00 2.561 ! alkane, 3/92 CTL1 CTL2 CTL1 58.350 113.50 11.16 2.561 ! glycerol CTL1 CTL2 CTL2 58.350 113.50 11.16 2.561 ! glycerol CTL1 CTL2 CTL3 58.350 113.50 11.16 2.561 ! glycerol CTL2 CTL1 CTL2 58.350 113.50 11.16 2.561 ! glycerol CTL2 CTL1 CTL3 58.350 113.50 11.16 2.561 ! glycerol CTL2 CTL2 CTL2 58.350 113.60 11.16 2.561 ! alkane, 3/92 CTL2 CTL2 CTL3 58.000 115.00 8.00 2.561 ! alkane, 3/92 HOL OHL CTL1 57.500 106.00 ! glycerol HOL OHL CTL2 57.500 106.00 ! glycerol HOL OHL CTL3 57.500 106.00 ! glycerol OHL CTL1 CTL2 75.700 110.10 ! glycerol OHL CTL2 CTL1 75.700 110.10 ! glycerol OHL CTL2 CTL2 75.700 110.10 ! glycerol OHL CTL2 CTL3 75.700 110.10 ! glycerol OHL CTL1 HAL1 45.900 108.89 ! glycerol OHL CTL2 HAL2 45.900 108.89 ! glycerol OHL CTL3 HAL3 45.900 108.89 ! glycerol O2L SL O2L 130.0 109.47 35.0 2.45 ! methylsulfate O2L SL OSL 85.0 98.0 ! methylsulfate CTL2 OSL SL 15.0 109.0 27.00 1.90 ! methylsulfate CTL3 OSL SL 15.0 109.0 27.00 1.90 ! methylsulfate !HT OT HT 55.0 104.52 ! FROM TIPS3P GEOMETRY CEL1 CEL1 CTL2 48.00 123.50 ! from 2-butene, yin,adm jr., 12/95 CEL1 CEL1 CTL3 48.00 123.50 ! 2-butene, yin,adm jr., 12/95 CEL2 CEL1 CTL2 48.00 126.00 ! 1-butene; from propene, yin,adm jr., 12/95 CEL2 CEL1 CTL3 47.00 125.20 ! propene, yin,adm jr., 12/95 HEL1 CEL1 CEL1 52.00 119.50 ! 2-butene, yin,adm jr., 12/95 HEL1 CEL1 CEL2 42.00 118.00 ! propene, yin,adm jr., 12/95 HEL1 CEL1 CTL2 40.00 116.00 ! 1-butene; from propene, yin,adm jr., 12/95 HEL1 CEL1 CTL3 22.00 117.00 ! propene, yin,adm jr., 12/95 HEL2 CEL2 CEL1 45.00 120.50 ! propene, yin,adm jr., 12/95 HEL2 CEL2 CEL2 55.50 120.50 ! ethene, yin,adm jr., 12/95 HEL2 CEL2 HEL2 19.00 119.00 ! propene, yin,adm jr., 12/95 CEL1 CTL2 CTL2 32.00 112.20 ! 1-butene; from propene, yin,adm jr., 12/95 CEL1 CTL2 CTL3 32.00 112.20 ! 1-butene; from propene, yin,adm jr., 12/95 HAL2 CTL2 CEL1 45.00 111.50 ! 1-butene; from propene, yin,adm jr., 12/95 HAL3 CTL3 CEL1 42.00 111.50 ! 2-butene, yin,adm jr., 12/95 DIHEDRALS ! !V(dihedral) = Kchi(1 + cos(n(chi) - delta)) ! !Kchi: kcal/mole !n: multiplicity !delta: degrees ! !atom types Kchi n delta ! C CT1 NH1 C 0.2000 1 180.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c C CT2 NH1 C 0.2000 1 180.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c C N CP1 C 0.8000 3 0.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CA CA CA CA 3.1000 2 180.00 ! ALLOW ARO ! JES 8/25/89 CA CPT CPT CA 3.1000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CA CT2 CT1 C 0.0400 3 0.00 ! ALLOW ARO ! 2.7 kcal/mole CH3 rot in ethylbenzene, adm jr, 3/7/92 CA CY CPT CA 3.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 CA NY CPT CA 3.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CC CP1 N C 0.8000 3 0.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CC CT1 CT2 CA 0.0400 3 0.00 ! ALLOW ARO ! 2.7 kcal/mole CH3 rot in ethylbenzene, adm jr, 3/7/92 CC CT1 NH1 C 0.2000 1 180.00 ! ALLOW PEP POL ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c CC CT2 NH1 C 0.2000 1 180.00 ! ALLOW PEP POL ! Alanine dipeptide; NMA; acetate; etc. adm jr., 3/3/93c CD CP1 N C 0.0000 1 180.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CD CT1 NH1 C 0.2000 1 180.00 ! ALLOW PEP POL ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c CD CT2 NH1 C 0.2000 1 180.00 ! ALLOW PEP POL ! Alanine dipeptide; NMA; acetate; etc. backbon adm jr., 3/3/93c CE1 CE1 CT3 HA 0.0300 3 0.00 ! ! for butene, yin/adm jr., 12/95 CE2 CE1 CT2 CT3 0.5000 3 0.00 ! ! for butene, yin/adm jr., 12/95 CE2 CE1 CT2 HA 0.1200 3 0.00 ! ! for butene, yin/adm jr., 12/95 CE2 CE1 CT3 HA 0.0500 3 180.00 ! ! for propene, yin/adm jr., 12/95 CP1 C N CP1 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP1 C N CP1 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP1 N C 0.8000 3 0.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP3 N C 0.0000 3 180.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP3 N CP1 0.1000 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP2 CP3 NP CP1 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N C CP1 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N C CP1 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N CP1 C 0.1000 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N CP1 CC 0.1000 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 N CP1 CP2 0.1000 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 NP CP1 C 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 NP CP1 CC 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 NP CP1 CD 0.0800 3 0.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CP3 NP CP1 CP2 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CPH2 NR1 CPH1 CPH1 14.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 CPH2 NR2 CPH1 CPH1 14.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 CPH2 NR3 CPH1 CPH1 12.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 CPT CA CA CA 3.1000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CPT CPT CA CA 3.1000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CPT CPT CY CA 4.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CPT CPT NY CA 5.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CT1 C N CP1 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT1 C N CP1 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT1 C N CP3 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT1 C N CP3 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT1 C NH1 CT1 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT1 C NH1 CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT1 CT1 NH1 C 1.8000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c CT1 CT2 CA CA 0.2300 2 180.00 ! ALLOW ARO ALI ! ethylbenzene ethyl rotation, adm jr. 3/7/92 CT1 CT2 CPH1 CPH1 0.2000 1 0.00 ! ALLOW ARO ! 4-ethylimidazole 4-21G rot bar, adm jr. 3/4/92 CT1 CT2 CPH1 CPH1 0.2700 2 0.00 ! ALLOW ARO ! 4-ethylimidazole 4-21G rot bar, adm jr. 3/4/92 CT1 CT2 CPH1 CPH1 0.0000 3 0.00 ! ALLOW ARO ! 4-ethylimidazole 4-21G rot bar, adm jr. 3/4/92 CT1 CT2 CY CA 0.2300 2 180.00 ! ALLOW ARO ! from ethylbenzene, adm jr., 3/7/92 CT1 CT2 CY CPT 0.2300 2 180.00 ! ALLOW ARO ! from ethylbenzene, adm jr., 3/7/92 CT1 NH1 C CP1 1.6000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT1 NH1 C CP1 2.5000 2 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 C N CP1 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 C N CP1 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 C N CP3 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 C N CP3 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 C NH1 CT1 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT2 C NH1 CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT2 C NH1 CT2 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT2 C NH1 CT2 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT2 C NH1 CT3 1.6000 1 0.00 ! ALLOW PEP ! from CT2 C NH1 CT2, adm jr. 10/21/96 CT2 C NH1 CT3 2.5000 2 180.00 ! ALLOW PEP ! from CT2 C NH1 CT2, adm jr. 10/21/96 CT2 CA CA CA 3.1000 2 180.00 ! ALLOW ARO ! JES 8/25/89 toluene and ethylbenzene CT2 CPH1 NR1 CPH2 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM HA CPH1 NR1 CPH2 CT2 CPH1 NR2 CPH2 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM HA CPH1 NR2 CPH2 CT2 CPH1 NR3 CPH2 2.5000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 CT2 CT1 NH1 C 1.8000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c CT2 CT2 CPH1 CPH1 0.4000 1 0.00 ! ALLOW ARO ! 4-methylimidazole 4-21G//6-31G* rot bar. ADM JR., 9/4/89 CT2 CT2 CT2 CT2 0.1500 1 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92, butane trans/gauche CT2 CT2 NH1 C 1.8000 1 0.00 ! ALLOW PEP ! from CT2 CT1 NH1 C, for lactams, adm jr. CT2 CY CPT CA 3.0000 2 180.00 ! ALLOW ARO ! JWK CT2 CY CPT CPT 3.0000 2 180.00 ! ALLOW ARO !JWK CT2 NH1 C CP1 1.6000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 NH1 C CP1 2.5000 2 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT2 NH1 C CT1 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT2 NH1 C CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT2 SM SM CT2 1.0000 1 0.00 ! ALLOW ALI SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) CT2 SM SM CT2 4.1000 2 0.00 ! ALLOW ALI SUL ION ! mp 6-311G** dimethyldisulfide, 3/26/92 (FL) CT2 SM SM CT2 0.9000 3 0.00 ! ALLOW ALI SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) CT3 C N CP1 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT3 C N CP1 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT3 C N CP3 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT3 C N CP3 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT3 C NH1 CT1 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT3 C NH1 CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT3 C NH1 CT2 1.6000 1 0.00 ! ALLOW PEP ! for acetylated GLY N-terminus, adm jr. CT3 C NH1 CT2 2.5000 2 180.00 ! ALLOW PEP ! for acetylated GLY N-terminus, adm jr. CT3 C NH1 CT3 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT3 C NH1 CT3 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT3 CA CA CA 3.1000 2 180.00 ! ALLOW ARO ! toluene, adm jr., 3/7/92 CT3 CE1 CE2 HE2 5.2000 2 180.00 ! ! for propene, yin/adm jr., 12/95 CT3 CPH1 NR1 CPH2 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM HA CPH1 NR1 CPH2 CT3 CT1 NH1 C 1.8000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c CT3 CT2 CA CA 0.2300 2 180.00 ! ALLOW ARO ALI ! ethylbenzene ethyl rotation, adm jr. 3/7/92 CT3 CT2 CPH1 CPH1 0.2000 1 0.00 ! ALLOW ARO ! 4-ethylimidazole 4-21G rot bar, adm jr. 3/4/92 CT3 CT2 CPH1 CPH1 0.2700 2 0.00 ! ALLOW ARO ! 4-ethylimidazole 4-21G rot bar, adm jr. 3/4/92 CT3 CT2 CPH1 CPH1 0.0000 3 0.00 ! ALLOW ARO ! 4-ethylimidazole 4-21G rot bar, adm jr. 3/4/92 CT3 CT2 CT2 CT2 0.1500 1 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92, butane trans/gauche CT3 CT2 CT2 CT3 0.1500 1 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92, butane trans/gauche CT3 CT2 CY CA 0.2300 2 180.00 ! ALLOW ARO ! from ethylbenzene, adm jr., 3/7/92 CT3 CT2 CY CPT 0.2300 2 180.00 ! ALLOW ARO ! from ethylbenzene, adm jr., 3/7/92 CT3 CT2 S CT3 0.2400 1 180.00 ! ALOW ALI SUL ION ! expt. MeEtS, 3/26/92 (FL) CT3 CT2 S CT3 0.3700 3 0.00 ! ALOW ALI SUL ION ! DTN 8/24/90 CT3 NH1 C CP1 1.6000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT3 NH1 C CP1 2.5000 2 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 CT3 NH1 C CT1 1.6000 1 0.00 ! ALLOW PEP ! Revised to adjust NMA cis/trans energy difference. (LK) CT3 NH1 C CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) CT3 S CT2 CT2 0.2400 1 180.00 ! ALOW ALI SUL ION ! expt. MeEtS, 3/26/92 (FL) CT3 S CT2 CT2 0.3700 3 0.00 ! ALOW ALI SUL ION ! expt. MeEtS, 3/26/92 (FL) CT3 SM SM CT3 1.0000 1 0.00 ! ALLOW ALI SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) CT3 SM SM CT3 4.1000 2 0.00 ! ALLOW ALI SUL ION ! mp 6-311G** dimethyldisulfide, 3/26/92 (FL) CT3 SM SM CT3 0.9000 3 0.00 ! ALLOW ALI SUL ION ! improved CSSC dihedral in DMDS 5/15/92 (FL) CY CA NY CPT 5.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CY CPT CA CA 3.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole CY CPT CPT CA 10.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole H NH1 C CP1 2.5000 2 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 H NH1 C CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) H NH1 C CT2 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) H NH1 C CT3 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) H NH1 CT1 C 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) H NH1 CT1 CC 0.0000 1 0.00 ! ALLOW PEP POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters H NH1 CT1 CD 0.0000 1 0.00 ! ALLOW PEP POL ! adm jr. 5/02/91, acetic acid pure solvent H NH1 CT1 CT1 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) H NH1 CT1 CT2 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) H NH1 CT1 CT3 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) H NH1 CT2 C 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) H NH1 CT2 CC 0.0000 1 0.00 ! ALLOW PEP POL ! Alanine dipeptide; NMA; acetate; etc. backbone param. RLD 3/22/92 H NH1 CT2 CD 0.0000 1 0.00 ! ALLOW PEP POL ! adm jr. 5/02/91, acetic acid pure solvent H NH1 CT2 CT2 0.0000 1 0.00 ! ALLOW PEP ! from H NH1 CT2 CT3, for lactams, adm jr. H NH1 CT2 CT3 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) H NH2 CC CT1 1.4000 2 180.00 ! ALLOW PEP POL ARO PRO ! adm jr. 4/10/91, acetamide update H NH2 CC CT2 1.4000 2 180.00 ! ALLOW PEP POL ARO PRO ! adm jr. 4/10/91, acetamide update H NH2 CC CT3 1.4000 2 180.00 ! ALLOW PEP POL ARO PRO ! adm jr. 4/10/91, acetamide update H NH2 CC CP1 2.5000 2 180.00 ! ALLOW PEP POL ARO PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 H NR1 CPH1 CPH1 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 7/20/89 H NR1 CPH1 CT2 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 7/22/89, FROM HA CPH1 NR1 H H NR1 CPH1 CT3 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 7/22/89, FROM HA CPH1 NR1 H H NR3 CPH1 CPH1 1.4000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 H NR3 CPH1 CT2 3.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 7/22/89, FROM HC NR3 CPH1 HA H NR3 CPH1 CT3 3.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 7/22/89, FROM HC NR3 CPH1 HA H NY CA CY 0.8000 2 180.00 ! ALLOW ARO !adm jr., 12/30/91, for jwk H NY CPT CA 0.8000 2 180.00 ! ALLOW ARO !adm jr., 12/30/91, for jwk H NY CPT CPT 0.8000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole H OH1 CA CA 0.9900 2 180.00 ! ALLOW ARO ALC ! phenol OH rot bar, 3.37 kcal/mole, adm jr. 3/7/92 H OH1 CT1 CT1 1.3300 1 0.00 ! ALLOW ALC ! 2-propanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT1 CT1 0.1800 2 0.00 ! ALLOW ALC ! 2-propanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT1 CT1 0.3200 3 0.00 ! ALLOW ALC ! 2-propanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT1 CT3 1.3300 1 0.00 ! ALLOW ALC ! 2-propanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT1 CT3 0.1800 2 0.00 ! ALLOW ALC ! 2-propanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT1 CT3 0.3200 3 0.00 ! ALLOW ALC ! 2-propanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT1 1.3000 1 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT1 0.3000 2 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT1 0.4200 3 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT2 1.3000 1 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT2 0.3000 2 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT2 0.4200 3 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT3 1.3000 1 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT3 0.3000 2 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 H OH1 CT2 CT3 0.4200 3 0.00 ! ALLOW ALC ! ethanol OH hf/6-31g* torsional surface, adm jr., 3/2/93 HA CA CA CA 3.5000 2 180.00 ! ALLOW ARO ! adm jr., 10/02/89 HA CA CA CPT 3.5000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CA CA HA 2.5000 2 180.00 ! ALLOW ARO ! ADM JR., 10/02/89 HA CA CPT CPT 3.0000 2 180.00 ! ALLOW ARO ! TRP (JES) HA CA CPT CY 4.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CA CY CPT 1.2000 2 180.00 ! ALLOW ARO ! JWK HA CA CY CT2 1.2000 2 180.00 ! ALLOW ARO ! JWK HA CA NY CPT 3.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CA NY H 1.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CC NH2 H 1.4000 2 180.00 ! ALLOW PEP POL ! adm jr. 4/10/91, acetamide update HA CP3 N C 0.0000 3 180.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP3 N CP1 0.1000 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CP3 NP CP1 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HA CT1 CT2 CA 0.0400 3 0.00 ! ALLOW ARO ! 2.7 kcal/mole CH3 rot in ethylbenzene, adm jr, 3/7/92 HA CT2 CPH1 CPH1 0.0000 3 0.00 ! ALLOW ARO ! 4-methylimidazole 4-21G//6-31G* rot bar. adm jr., 9/4/89 HA CT2 CY CA 0.2500 2 180.00 ! ALLOW ARO ! JWK HA CT2 CY CPT 0.2500 2 180.00 ! ALLOW ARO ! JWK HA CT2 NH1 C 0.0000 3 0.00 ! ALLOW PEP ! LK for autogenerate dihe, sp2-methyl, no dihedral potential HA CT2 NH1 H 0.0000 3 0.00 ! ALLOW PEP ! LK for autogenerate dihe, sp2-methyl, no dihedral potential HA CT2 S CT3 0.2800 3 0.00 ! ALLOW ALI SUL ION ! DTN 8/24/90 HA CT3 CPH1 CPH1 0.0000 3 0.00 ! ALLOW ARO ! 4-methylimidazole 4-21G//6-31G* rot bar. adm jr., 9/4/89 HA CT3 CS HA 0.1600 3 0.00 ! ALLOW SUL ! ethylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 HA CT3 CT2 CA 0.0400 3 0.00 ! ALLOW ARO ! 2.7 kcal/mole CH3 rot in ethylbenzene, adm jr, 3/7/92 HA CT3 NH1 C 0.0000 3 0.00 ! ALLOW PEP ! LK for autogenerate dihe, sp2-methyl, no dihedral potential HA CT3 NH1 H 0.0000 3 0.00 ! ALLOW PEP ! LK for autogenerate dihe, sp2-methyl, no dihedral potential HA CT3 S CT2 0.2800 3 0.00 ! ALLOW ALI SUL ION ! DTN 8/24/90 HA CY CA CPT 1.2000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CY CA HA 1.2000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CY CPT CA 3.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HA CY CPT CPT 3.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 HE1 CE1 CE2 HE2 5.2000 2 180.00 ! ! for propene, yin/adm jr., 12/95 HE1 CE1 CT2 HA 0.8700 3 0.00 ! ! for butene, yin/adm jr., 12/95 HE1 CE1 CT2 CT3 0.1200 3 0.00 ! ! for butene, yin/adm jr., 12/95 HE1 CE1 CT3 HA 0.3400 3 0.00 ! ! for butene, yin/adm jr., 12/95 HE2 CE2 CE1 CT2 5.2000 2 180.00 ! ! for butene, yin/adm jr., 12/95 HB CP1 N C 0.8000 3 0.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CP1 N CP3 0.1000 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CP1 NP CP3 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HB CT1 NH1 C 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT1 NH1 H 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT2 NH1 C 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT2 NH1 H 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT3 NH1 C 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HB CT3 NH1 H 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) HC NH2 CT2 HB 0.1100 3 0.00 !from X CT3 NH2 X, neutral glycine, adm jr. HC NH2 CT2 CD 0.1100 3 0.00 !from X CT3 NH2 X, neutral glycine, adm jr. HC NP CP1 C 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP1 CC 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP1 CD 0.0800 3 0.00 ! ALLOW PRO PEP ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP1 CP2 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP1 HB 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP3 CP2 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HC NP CP3 HA 0.0800 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 HP CA CA CA 4.2000 2 180.00 ! ALLOW ARO ! JES 8/25/89 benzene HP CA CA CPT 3.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole HP CA CA CT2 4.2000 2 180.00 ! ALLOW ARO ! JES 8/25/89 toluene and ethylbenzene HP CA CA CT3 4.2000 2 180.00 ! ALLOW ARO ! toluene, adm jr., 3/7/92 HP CA CA HP 2.4000 2 180.00 ! ALLOW ARO ! JES 8/25/89 benzene HP CA CPT CPT 3.0000 2 180.00 ! ALLOW ARO ! JWK indole 05/14/91 HP CA CPT CY 3.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole HP CA CY CPT 2.0000 2 180.00 ! ALLOW ARO !adm jr., 12/30/91, for jwk HP CA CY CT2 1.2000 2 180.00 ! ALLOW ARO ! JWK indole 05/14/91 HP CA NY CPT 2.0000 2 180.00 ! ALLOW ARO !adm jr., 12/30/91, for jwk HP CA NY H 0.4000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole HP CY CA HP 1.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole HP CY CPT CA 2.8000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole HP CY CPT CPT 2.8000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole HR1 CPH1 CPH1 CT2 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH1 CPH1 CT3 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH1 CPH1 HR1 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90, his HR1 CPH1 NR3 CPH2 2.5000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH1 NR3 H 3.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH2 NR1 CPH1 3.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH2 NR1 H 1.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR1 CPH2 NR2 CPH1 3.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR2 CPH2 NR3 CPH1 3.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 HR2 CPH2 NR3 H 0.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90, YES, 0.0 HR3 CPH1 CPH1 CT2 2.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 CPH1 CT3 2.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 CPH1 HR3 2.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 NR1 CPH2 3.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 NR1 H 1.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 NR2 CPH2 3.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HS S CT2 CT1 0.2400 1 0.00 ! ALLOW ALI SUL ION ! methanethiol pure solvent, adm jr., 6/22/92 HS S CT2 CT1 0.1500 2 0.00 ! ALLOW ALI SUL ION ! methanethiol pure solvent, adm jr., 6/22/92 HS S CT2 CT1 0.2700 3 0.00 ! ALLOW ALI SUL ION ! methanethiol pure solvent, adm jr., 6/22/92 HS S CT2 CT3 0.2400 1 0.00 ! ALLOW ALI SUL ION ! ethanethiol C-C-S-H surface, adm jr., 4/18/93 HS S CT2 CT3 0.1500 2 0.00 ! ALLOW ALI SUL ION ! ethanethiol C-C-S-H surface, adm jr., 4/18/93 HS S CT2 CT3 0.2700 3 0.00 ! ALLOW ALI SUL ION ! ethanethiol C-C-S-H surface, adm jr., 4/18/93 HS S CT2 HA 0.2000 3 0.00 ! ALLOW ALI SUL ION ! methanethiol pure solvent, adm jr., 6/22/92 HS S CT3 HA 0.2000 3 0.00 ! ALLOW ALI SUL ION ! methanethiol pure solvent, adm jr., 6/22/92 N C CP1 CP2 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CP1 CP2 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CP1 HB 0.4000 1 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CP1 HB 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CP1 N 0.3000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CP1 N -0.3000 4 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT1 CT1 0.0000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT1 CT2 0.0000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT1 CT3 0.0000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT1 HB 0.0000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT2 HB 0.0000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N C CT3 HA 0.0000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 N CT1 CT2 CA 0.0400 3 0.00 ! ALLOW ARO ! 2.7 kcal/mole CH3 rot in ethylbenzene, adm jr, 3/7/92 NH1 C CP1 CP2 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CP1 CP2 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CP1 HB 0.4000 1 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CP1 HB 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CP1 N 0.3000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CP1 N -0.3000 4 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 C CT1 CT1 0.0000 1 0.00 ! ALLOW PEP ! ala dipeptide corrxn for new C VDW Rmin, 4/10/93 (LK) NH1 C CT1 CT2 0.0000 1 0.00 ! ALLOW PEP ! ala dipeptide corrxn for new C VDW Rmin, 4/10/93 (LK) NH1 C CT1 CT3 0.0000 1 0.00 ! ALLOW PEP ! ala dipeptide corrxn for new C VDW Rmin, 4/10/93 (LK) NH1 C CT1 HB 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) NH1 C CT1 NH1 0.6000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93 NH1 C CT2 CT2 0.0000 1 0.00 ! ALLOW PEP ! from NH1 C CT1 CT2, for lactams, adm jr. NH1 C CT2 HA 0.0000 3 0.00 ! ALLOW PEP ! LK for autogenerate dihe, sp2-methyl, no dihedral potential NH1 C CT2 HB 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) NH1 C CT2 NH1 0.6000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93 NH1 C CT3 HA 0.0000 3 0.00 ! ALLOW PEP ! LK for autogenerate dihe, sp2-methyl, no dihedral potential NH1 CT1 C N 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH1 CT2 C N 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CP1 CP2 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CP1 CP2 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CP1 HB 0.4000 1 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CP1 HB 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CP1 N 0.3000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CP1 N -0.3000 4 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH2 CC CT2 HA 0.0000 3 180.00 ! ALLOW POL ! adm jr., 8/13/90 acetamide geometry and vibrations NH3 CT1 C N 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH3 CT1 C NH1 0.6000 1 0.00 ! ALLOW PEP PRO ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93 NH3 CT1 CC NH2 0.4000 1 0.00 ! ALLOW PEP PRO ! Alanine dipeptide; NMA; acetate; etc. backbone param. RLD 3/22/92 NH3 CT2 C N 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NH3 CT2 C NH1 0.4000 1 0.00 ! ALLOW PEP PRO ! adm jr. 3/24/92, for PRES GLYP NH3 CT2 CC NH2 0.4000 1 0.00 ! ALLOW PEP PRO ! Alanine dipeptide; NMA; acetate; etc. backbone param. RLD 3/22/92 NP CP1 C N 0.3000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP1 C NH1 0.3000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NP CP1 CC NH2 0.3000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NR1 CPH1 CPH1 CT2 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM NR1 CPH1 CPH1 HA NR1 CPH1 CPH1 CT3 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM NR1 CPH1 CPH1 HA NR1 CPH1 CPH1 HR3 3.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params NR1 CPH1 CT2 CT1 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR1 CPH1 CT2 CT2 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR1 CPH1 CT2 CT3 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR1 CPH1 CT2 HA 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR1 CPH1 CT3 HA 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR1 CPH2 NR2 CPH1 14.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 CPH1 CPH1 CT2 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM NR2 CPH1 CPH1 HA NR2 CPH1 CPH1 CT3 3.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/22/89, FROM NR2 CPH1 CPH1 HA NR2 CPH1 CPH1 HR3 3.0000 2 180.00 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params NR2 CPH1 CPH1 NR1 14.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 CPH1 CT2 CT1 0.1900 3 0.00 ! ALLOW ARO ! HIS CB-CG TORSION, NR2 CPH1 CT2 CT2 0.1900 3 0.00 ! ALLOW ARO ! HIS CB-CG TORSION, NR2 CPH1 CT2 CT3 0.1900 3 0.00 ! ALLOW ARO ! HIS CB-CG TORSION, NR2 CPH1 CT2 HA 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR2 CPH1 CT3 HA 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR2 CPH2 NR1 CPH1 14.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR2 CPH2 NR1 H 1.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR3 CPH1 CPH1 CT2 2.5000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH1 CPH1 CT3 2.5000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH1 CPH1 HR1 2.5000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH1 CPH1 NR3 12.0000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH1 CT2 CT1 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR3 CPH1 CT2 CT2 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR3 CPH1 CT2 CT3 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR3 CPH1 CT2 HA 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR3 CPH1 CT3 HA 0.1900 3 0.00 ! ALLOW ARO ! 4-METHYLIMIDAZOLE 4-21G//6-31G* ROT BAR. ADM JR., 9/4/89 NR3 CPH2 NR3 CPH1 12.0000 2 180.00 ! ALLOW ARO ! his, ADM JR., 7/20/89 NR3 CPH2 NR3 H 1.4000 2 180.00 ! ALLOW ARO ! his, adm jr., 6/27/90 NY CA CY CPT 4.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole NY CA CY CT2 3.5000 2 180.00 ! ALLOW ARO ! JWK NY CA CY HA 3.5000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 NY CA CY HP 3.5000 2 180.00 ! ALLOW ARO ! JWK indole 05/14/91 NY CPT CA CA 2.8000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole NY CPT CA HA 4.0000 2 180.00 ! ALLOW ARO ! JWK 09/05/89 NY CPT CA HP 3.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole NY CPT CPT CA 10.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole NY CPT CPT CY 5.0000 2 180.00 ! ALLOW ARO ! JWK 05/14/91 fit to indole O C CP1 CP2 0.4000 1 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C CP1 CP2 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C CP1 HB 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C CP1 HB 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C CP1 N -0.3000 4 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C CT1 CT1 1.4000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c O C CT1 CT2 1.4000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c O C CT1 CT3 1.4000 1 0.00 ! ALLOW PEP ! ala dipeptide update for new C VDW Rmin, adm jr., 3/3/93c O C CT1 HB 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) O C CT1 NH1 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) O C CT1 NH3 0.0000 1 0.00 ! ALLOW PEP PRO ! Backbone parameter set made complete RLD 8/8/90 O C CT2 CT2 1.4000 1 0.00 ! ALLOW PEP ! from O C CT1 CT2, for lactams, adm jr. O C CT2 HA 0.0000 3 180.00 ! ALLOW POL ! adm jr., 8/13/90 acetamide geometry and vibrations O C CT2 HB 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) O C CT2 NH1 0.0000 1 0.00 ! ALLOW PEP ! Alanine Dipeptide ab initio calc's (LK) O C CT2 NH3 0.0000 1 0.00 ! ALLOW PEP PRO ! Backbone parameter set made complete RLD 8/8/90 O C CT3 HA 0.0000 3 180.00 ! ALLOW POL ! adm jr., 8/13/90 acetamide geometry and vibrations O C N CP1 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C N CP1 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C N CP3 2.7500 2 180.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C N CP3 0.3000 4 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O C NH1 CT1 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) O C NH1 CT2 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) O C NH1 CT3 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) O C NH1 H 2.5000 2 180.00 ! ALLOW PEP ! Gives appropriate NMA cis/trans barrier. (LK) O CC CP1 CP2 0.4000 1 180.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O CC CP1 CP2 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O CC CP1 HB 0.4000 1 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O CC CP1 HB 0.6000 2 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O CC CP1 N -0.3000 4 0.00 ! ALLOW PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 O CC CT2 HA 0.0000 3 180.00 ! ALLOW POL ! adm jr. 4/05/91, for asn,asp,gln,glu and cters O CC NH2 H 1.4000 2 180.00 ! ALLOW PEP POL ARO PRO ! adm jr. 4/10/91, acetamide update OB CD OS CT2 0.9650 1 180.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate OB CD OS CT2 3.8500 2 180.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate OB CD OS CT3 0.9650 1 180.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate OB CD OS CT3 3.8500 2 180.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate OC CA CA CA 3.1000 2 180.00 ! ALLOW ARO ! adm jr. 8/27/91, phenoxide OC CA CA HP 4.2000 2 180.00 ! ALLOW ARO ! adm jr. 8/27/91, phenoxide OC CC CP1 CP2 0.1600 3 0.00 ! ALLOW PEP PRO POL ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OC CC CP1 HB 0.1600 3 0.00 ! ALLOW PEP PRO POL ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OC CC CP1 N 0.1600 3 0.00 ! ALLOW PEP PRO POL ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OC CC CP1 NP 0.1600 3 0.00 ! ALLOW PEP PRO POL ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 OC CC CT1 NH3 3.2000 2 180.00 ! ALLOW PEP PRO ! adm jr. 4/17/94, zwitterionic glycine OC CC CT2 NH3 3.2000 2 180.00 ! ALLOW PEP PRO ! adm jr. 4/17/94, zwitterionic glycine OH1 CA CA CA 3.1000 2 180.00 ! ALLOW ARO ! JES 8/25/89 phenol OH1 CA CA HP 4.2000 2 180.00 ! ALLOW ARO ! JES 8/25/89 phenol S CT2 CT2 HA 0.0100 3 0.00 ! ALLOW ALI SUL ION ! DTN 8/24/90 SM CT2 CT2 HA 0.0100 3 0.00 ! ALLOW ALI SUL ION ! DTN 8/24/90 SM SM CT2 CT1 0.3100 3 0.00 ! ALLOW SUL ALI ! S-S for cys-cys, dummy parameter for now ... DTN 9/04/90 SM SM CT2 CT2 0.3100 3 0.00 ! ALLOW SUL ALI ! S-S for cys-cys, dummy parameter for now ... DTN 9/04/90 SM SM CT2 HA 0.1580 3 0.00 ! ALLOW ALI SUL ION ! expt. dimethyldisulfide, 3/26/92 (FL) SM SM CT3 HA 0.1580 3 0.00 ! ALLOW ALI SUL ION ! expt. dimethyldisulfide, 3/26/92 (FL) SS CS CT3 HA 0.1500 3 0.00 ! ALLOW SUL ! ethylthiolate 6-31+G* geom/freq, adm jr., 6/1/92 X C C X 4.0000 2 180.00 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) X C NC2 X 2.2500 2 180.00 ! ALLOW PEP POL ARO ! 9.0->2.25 GUANIDINIUM (KK) X CD OH1 X 2.0500 2 180.00 ! ALLOW PEP POL ARO ALC ! adm jr, 10/17/90, acetic acid C-Oh rotation barrier X CD OS X 2.0500 2 180.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate X CE1 CE1 X 5.2000 2 180.00 ! ! for butene, yin/adm jr., 12/95 X CE2 CE2 X 4.9000 2 180.00 ! ! for ethene, yin/adm jr., 12/95 X CP1 C X 0.0000 6 180.00 ! ALLOW POL PEP PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 X CP1 CC X 0.0000 6 180.00 ! ALLOW POL PEP ! changed to 0.0 RLD 5/19/92 X CP1 CD X 0.0000 6 180.00 ! ALLOW POL PEP ! Alanine dipeptide; NMA; acetate; etc. backbone param. RLD 3/22/92 X CP1 CP2 X 0.1400 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 X CP2 CP2 X 0.1600 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 X CP3 CP2 X 0.1400 3 0.00 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 X CPA CPB X 0.0000 2 0.00 ! ALLOW HEM ! Heme (6-liganded): dummy for "auto dihe" (KK 05/13/91) X CPA CPM X 0.0000 2 0.00 ! ALLOW HEM ! Heme (6-liganded): dummy for "auto dihe" (KK 05/13/91) X CPB C X 3.0000 2 180.00 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) X CPB CPB X 0.0000 2 0.00 ! ALLOW HEM ! Heme (6-liganded): dummy for "auto dihe" (KK 05/13/91) X CPB CT2 X 0.0000 6 0.00 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) X CPB CT3 X 0.0000 6 0.00 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) X CPT CPT X 0.0000 2 180.00 ! ALLOW ARO ! JWK indole 05/14/91 X CT1 CC X 0.0500 6 180.00 ! ALLOW POL PEP ! For side chains of asp,asn,glu,gln, (n=6) from KK(LK) X CT1 CD X 0.0000 6 180.00 ! ALLOW POL PEP ! adm jr. 3/19/92, from lipid methyl acetate X CT1 CT1 X 0.2000 3 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 X CT1 CT2 X 0.2000 3 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 X CT1 CT3 X 0.2000 3 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 X CT1 NH3 X 0.1000 3 0.00 ! ALLOW ALI POL ! 0.715->0.10 METHYLAMMONIUM (KK) X CT1 OH1 X 0.1400 3 0.00 ! ALLOW ALI ALC ARO ! EMB 11/21/89 methanol vib fit X CT1 OS X -0.1000 3 0.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate X CT2 CA X 0.0000 6 0.00 ! ALLOW ALI ARO ! toluene, adm jr., 3/7/92 X CT2 CC X 0.0500 6 180.00 ! ALLOW POL PEP ! For side chains of asp,asn,glu,gln, (n=6) from KK(LK) X CT2 CD X 0.0000 6 180.00 ! ALLOW POL PEP ! adm jr. 3/19/92, from lipid methyl acetate X CT2 CT2 X 0.1950 3 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 X CT2 CT3 X 0.1600 3 0.00 ! ALLOW ALI ! rotation barrier in Ethane (SF) X CT2 NC2 X 0.0000 6 180.00 ! ALLOW ALI POL ! methylguanidinium, adm jr., 3/26/92 X CT2 NH3 X 0.1000 3 0.00 ! ALLOW ALI POL ! 0.715->0.10 METHYLAMMONIUM (KK) X CT2 OH1 X 0.1400 3 0.00 ! ALLOW ALI ALC ARO ! EMB 11/21/89 methanol vib fit X CT2 OS X -0.1000 3 0.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate X CT3 CA X 0.0000 6 0.00 ! ALLOW ALI ARO ! toluene, adm jr., 3/7/92 X CT3 CC X 0.0500 6 180.00 ! ALLOW POL PEP ! For side chains of asp,asn,glu,gln, (n=6) from KK(LK) X CT3 CD X 0.0000 6 180.00 ! ALLOW POL PEP ! adm jr. 3/19/92, from lipid methyl acetate X CT3 CT3 X 0.1550 3 0.00 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 X CT3 NC2 X 0.0000 6 180.00 ! ALLOW ALI POL ! methylguanidinium, adm jr., 3/26/92 X CT3 NH2 X 0.1100 3 0.00 ! ALLOW POL ! methylamine geom/freq, adm jr., 6/2/92 X CT3 NH3 X 0.0900 3 0.00 ! ALLOW ALI POL ! fine-tuned to ab initio; METHYLAMMONIUM, KK 03/10/92 X CT3 OH1 X 0.1400 3 0.00 ! ALLOW ALI ALC ARO ! EMB 11/21/89 methanol vib fit X CT3 OS X -0.1000 3 0.00 ! ALLOW PEP POL ! adm jr. 3/19/92, from lipid methyl acetate X FE CM X 0.0500 4 0.00 ! ALLOW HEM ! Heme (6-liganded): ligands (KK 05/13/91) X FE NPH X 0.0000 2 0.00 ! ALLOW HEM ! Heme (6-liganded): for "ic para" only (KK 05/13/91) X FE OM X 0.0000 4 0.00 ! ALLOW HEM ! Heme (6-liganded): ligands (KK 05/13/91) X NPH CPA X 0.0000 2 0.00 ! ALLOW HEM ! Heme (6-liganded): dummy for "auto dihe" (KK 05/13/91) !lipids section X CTL1 OHL X 0.14 3 0.00 ! glycerol X CTL2 OHL X 0.14 3 0.00 ! glycerol X CTL3 OHL X 0.14 3 0.00 ! glycerol OBL CL CTL2 HAL2 0.00 6 180.00 ! acetic acid OBL CL CTL3 HAL3 0.00 6 180.00 ! acetic acid OSL CL CTL2 HAL2 0.00 6 180.00 ! acetic acid OSL CL CTL3 HAL3 0.00 6 180.00 ! acetic acid OBL CL OSL CTL1 0.965 1 180.00 ! methyl acetate OBL CL OSL CTL1 3.85 2 180.00 ! methyl acetate OBL CL OSL CTL2 0.965 1 180.00 ! methyl acetate OBL CL OSL CTL2 3.85 2 180.00 ! methyl acetate OBL CL OSL CTL3 0.965 1 180.00 ! methyl acetate OBL CL OSL CTL3 3.85 2 180.00 ! methyl acetate X CL OSL X 2.05 2 180.00 ! methyl acetate X CTL2 CL X 0.05 6 180.00 ! methyl acetate X CTL3 CL X 0.05 6 180.00 ! methyl acetate X CL OHL X 2.05 2 180.00 ! acetic acid HAL2 CTL2 CL OHL 0.00 6 180.00 HAL3 CTL3 CL OHL 0.00 6 180.00 OSL PL OSL CTL2 1.20 1 180.00 ! phosphate, new NA, 4/98, adm jr. OSL PL OSL CTL2 0.10 2 180.00 ! phosphate, new NA, 4/98, adm jr. OSL PL OSL CTL2 0.10 3 180.00 ! phosphate, new NA, 4/98, adm jr. O2L PL OSL CTL2 0.10 3 0.00 ! phosphate, new NA, 4/98, adm jr. OSL PL OSL CTL3 1.20 1 180.00 ! phosphate, new NA, 4/98, adm jr. OSL PL OSL CTL3 0.10 2 180.00 ! phosphate, new NA, 4/98, adm jr. OSL PL OSL CTL3 0.10 3 180.00 ! phosphate, new NA, 4/98, adm jr. O2L PL OSL CTL3 0.10 3 0.00 ! phosphate, new NA, 4/98, adm jr. OHL PL OSL CTL2 0.95 2 0.00 ! terminal phosphate OHL PL OSL CTL2 0.50 3 0.00 ! terminal phosphate OHL PL OSL CTL3 0.95 2 0.00 ! terminal phosphate OHL PL OSL CTL3 0.50 3 0.00 ! terminal phosphate X OHL PL X 0.30 3 0.00 ! terminal phosphate X CTL1 OSL X 0.00 3 0.00 ! phosphate, new NA, 4/98, adm jr. X CTL2 OSL X 0.00 3 0.00 ! phosphate, new NA, 4/98, adm jr. X CTL3 OSL X 0.00 3 0.00 ! phosphate, new NA, 4/98, adm jr. CTL3 CTL2 OSL CL 0.7 1 180.00 ! ethyl acetate, 12/92 CTL2 CTL2 OSL CL 0.7 1 180.00 ! ethyl acetate, 12/92 CTL3 CTL1 OSL CL 0.7 1 180.00 ! ethyl acetate, 12/92 CTL2 CTL1 OSL CL 0.7 1 180.00 ! ethyl acetate, 12/92 CTL1 CTL2 CL OSL -0.15 1 180.00 ! methyl propionate, 12/92 CTL1 CTL2 CL OSL 0.53 2 180.00 ! methyl propionate, 12/92 CTL2 CTL2 CL OSL -0.15 1 180.00 ! methyl propionate, 12/92 CTL2 CTL2 CL OSL 0.53 2 180.00 ! methyl propionate, 12/92 CTL3 CTL2 CL OSL -0.15 1 180.00 ! methyl propionate, 12/92 CTL3 CTL2 CL OSL 0.53 2 180.00 ! methyl propionate, 12/92 X CTL2 NTL X 0.26 3 0.00 ! tetramethylammonium X CTL5 NTL X 0.23 3 0.00 ! tetramethylammonium X CTL2 NH3L X 0.10 3 0.00 ! ethanolamine NH3L CTL2 CTL2 OHL 0.7 1 180.00 ! ethanolamine NH3L CTL2 CTL2 OSL 0.7 1 180.00 ! ethanolamine NTL CTL2 CTL2 OHL 4.3 1 180.00 ! choline, 12/92 NTL CTL2 CTL2 OHL -0.4 3 180.00 ! choline, 12/92 NTL CTL2 CTL2 OSL 3.3 1 180.00 ! choline, 12/92 NTL CTL2 CTL2 OSL -0.4 3 180.00 ! choline, 12/92 X CTL1 CTL1 X 0.200 3 0.00 ! alkane, 3/92 X CTL1 CTL2 X 0.200 3 0.00 ! alkane, 3/92 X CTL1 CTL3 X 0.200 3 0.00 ! alkane, 3/92 X CTL2 CTL2 X 0.1900 3 0.00 ! alkane, 4/98, yin and mackerell X CTL2 CTL3 X 0.1600 3 0.00 ! alkane, 4/98, yin and mackerell X CTL3 CTL3 X 0.1525 3 0.00 ! alkane, 4/98, yin and mackerell CTL3 CTL2 CTL2 CTL3 0.10 2 180.00 ! alkane, 4/98, adm jr., lower butane gauche conformer CTL3 CTL2 CTL2 CTL3 0.15 4 0.00 ! alkane, 4/98, adm jr. CTL3 CTL2 CTL2 CTL3 0.10 6 180.00 ! alkane, 4/98, adm jr. CTL2 CTL2 CTL2 CTL3 0.10 2 180.00 ! alkane, 4/98, adm jr. CTL2 CTL2 CTL2 CTL3 0.15 4 0.00 ! alkane, 4/98, adm jr. CTL2 CTL2 CTL2 CTL3 0.10 6 180.00 ! alkane, 4/98, adm jr. CTL2 CTL2 CTL2 CTL2 0.10 2 180.00 ! alkane, 4/98, adm jr. CTL2 CTL2 CTL2 CTL2 0.15 4 0.00 ! alkane, 4/98, adm jr. CTL2 CTL2 CTL2 CTL2 0.10 6 180.00 ! alkane, 4/98, adm jr. HAL3 CTL3 OSL SL 0.00 3 0.00 ! methylsulfate CTL2 OSL SL O2L 0.00 3 0.00 ! methylsulfate CTL3 OSL SL O2L 0.00 3 0.00 ! methylsulfate HEL1 CEL1 CEL1 HEL1 1.0000 2 180.00 ! 2-butene, adm jr., 8/98 update CTL3 CEL1 CEL1 HEL1 1.0000 2 180.00 ! 2-butene, adm jr., 8/98 update X CEL1 CEL1 X 0.1300 1 180.00 ! 2-butene, adm jr., 8/98 update X CEL1 CEL1 X 24.0000 2 180.00 ! 2-butene, adm jr., 8/98 update X CEL2 CEL2 X 4.9000 2 180.00 ! ethene, yin,adm jr., 12/95 CTL2 CEL1 CEL2 HEL2 5.2000 2 180.00 ! propene, yin,adm jr., 12/95 CTL3 CEL1 CEL2 HEL2 5.2000 2 180.00 ! propene, yin,adm jr., 12/95 HEL1 CEL1 CEL2 HEL2 5.2000 2 180.00 ! propene, yin,adm jr., 12/95 CEL1 CEL1 CTL2 HAL2 0.0300 3 0.00 ! butene, yin,adm jr., 12/95 CEL1 CEL1 CTL3 HAL3 0.0300 3 0.00 ! butene, yin,adm jr., 12/95 CEL1 CEL1 CTL2 CTL2 0.4000 3 0.00 ! 1-butene, adm jr., 8/98 update CEL2 CEL1 CTL2 CTL2 0.4000 3 0.00 ! 1-butene, adm jr., 8/98 update CEL2 CEL1 CTL2 CTL3 0.4000 3 0.00 ! 1-butene, adm jr., 8/98 update CEL2 CEL1 CTL2 HAL2 0.1200 3 0.00 ! 1-butene, yin,adm jr., 12/95 CEL2 CEL1 CTL3 HAL3 0.050 3 180.00 ! propene, yin,adm jr., 12/95 HEL1 CEL1 CTL2 CTL2 0.1200 3 0.00 ! butene, yin,adm jr., 12/95 HEL1 CEL1 CTL2 CTL3 0.1200 3 0.00 ! butene, yin,adm jr., 12/95 HEL1 CEL1 CTL2 HAL2 0.8700 3 0.00 ! butene, yin,adm jr., 12/95 HEL1 CEL1 CTL3 HAL3 0.3400 3 0.00 ! butene, yin,adm jr., 12/95 IMPROPER ! !V(improper) = Kpsi(psi - psi0)**2 ! !Kpsi: kcal/mole/rad**2 !psi0: degrees !note that the second column of numbers (0) is ignored ! !atom types Kpsi psi0 ! CPB CPA NPH CPA 20.8000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPB X X C 90.0000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT2 X X CPB 90.0000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) CT3 X X CPB 90.0000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): substituents (KK 05/13/91) HA C C HA 20.0000 0 0.0000 ! ALLOW PEP POL ARO ! Heme vinyl substituent (KK, from propene (JCS)) HA CPA CPA CPM 29.4000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) HA CPB C C 20.0000 0 0.0000 ! ALLOW HEM ARO ! Heme (6-liganded): substituents (KK 05/13/91) HA HA C C 20.0000 0 180.0000 ! ALLOW PEP POL ARO ! Heme vinyl substituent (KK, from propene (JCS)) HE2 HE2 CE2 CE2 3.0 0 0.00 ! ! for ethene, yin/adm jr., 12/95 HR1 NR1 NR2 CPH2 0.5000 0 0.0000 ! ALLOW ARO ! his, adm jr., 7/05/90 HR1 NR2 NR1 CPH2 0.5000 0 0.0000 ! ALLOW ARO ! his, adm jr., 7/05/90 HR3 CPH1 NR1 CPH1 0.5000 0 0.0000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 NR2 CPH1 0.5000 0 0.0000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 CPH1 NR3 CPH1 1.0000 0 0.0000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 NR1 CPH1 CPH1 0.5000 0 0.0000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HR3 NR2 CPH1 CPH1 0.5000 0 0.0000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params N C CP1 CP3 0.0000 0 0.0000 ! ALLOW PRO ! 6-31g* AcProNH2 and ProNH2 RLD 5/19/92 NC2 X X C 40.0000 0 0.0000 ! ALLOW PEP POL ARO ! 5.75->40.0 GUANIDINIUM (KK) NH1 X X H 20.0000 0 0.0000 ! ALLOW PEP POL ARO ! NMA Vibrational Modes (LK) NH2 X X H 4.0000 0 0.0000 ! ALLOW POL ! adm jr., 8/13/90 acetamide geometry and vibrations NPH CPA CPA FE 137.4000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NPH CPA CPB CPB 40.6000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NPH CPA CPM CPA 18.3000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NPH CPM CPB CPA 32.7000 0 0.0000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NR1 CPH1 CPH2 H 0.4500 0 0.0000 ! ALLOW ARO ! his, adm jr., 7/05/90 NR1 CPH2 CPH1 H 0.4500 0 0.0000 ! ALLOW ARO ! his, adm jr., 7/05/90 NR3 CPH1 CPH2 H 1.2000 0 0.0000 ! ALLOW ARO ! his, adm jr., 6/27/90 NR3 CPH2 CPH1 H 1.2000 0 0.0000 ! ALLOW ARO ! his, adm jr., 6/27/90 NY CA CY CPT 100.0000 0 0.0000 ! ALLOW ARO !adm jr., 5/15/91, indole 3-21G HE1 out-of-plane surf. O CP1 NH2 CC 45.0000 0 0.0000 ! ALLOW PEP POL PRO ! 6-31g* AcProNH2 and ProNH2 RLD 5/19/92 O CT1 NH2 CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 8/13/90 acetamide geometry and vibrations O CT2 NH2 CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 8/13/90 acetamide geometry and vibrations O CT3 NH2 CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 8/13/90 acetamide geometry and vibrations O HA NH2 CC 45.0000 0 0.0000 ! ALLOW PEP POL PRO ! adm jr., 5/13/91, formamide geometry and vibrations O N CT2 CC 120.0000 0 0.0000 ! ALLOW PEP POL PRO ! 6-31g* AcProNH2 and ProNH2 RLD 5/19/92 O NH2 CP1 CC 45.0000 0 0.0000 ! ALLOW PEP POL PRO ! 6-31g* AcProNH2 and ProNH2 RLD 5/19/92 O NH2 CT1 CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 8/13/90 acetamide geometry and vibrations O NH2 CT2 CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 8/13/90 acetamide geometry and vibrations O NH2 CT3 CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 8/13/90 acetamide geometry and vibrations O NH2 HA CC 45.0000 0 0.0000 ! ALLOW PEP POL ! adm jr., 5/13/91, formamide geometry and vibrations O X X C 120.0000 0 0.0000 ! ALLOW PEP POL ARO ! NMA Vibrational Modes (LK) OB X X CD 100.0000 0 0.0000 ! ALLOW ALC ARO POL ! adm jr., 10/17/90, acetic acid vibrations OC X X CC 96.0000 0 0.0000 ! ALLOW PEP POL ARO ION ! 90.0->96.0 acetate, single impr (KK) CC X X CT1 96.0000 0 0.0000 ! ALLOW PEP POL ARO ION ! 90.0->96.0 acetate, single impr (KK) CC X X CT2 96.0000 0 0.0000 ! ALLOW PEP POL ARO ION ! 90.0->96.0 acetate, single impr (KK) CC X X CT3 96.0000 0 0.0000 ! ALLOW PEP POL ARO ION ! 90.0->96.0 acetate, single impr (KK) !lipids section OBL X X CL 100.00 0 0.00 ! acetic acid HEL2 HEL2 CEL2 CEL2 3.00 0 0.00 ! ethene, yin,adm jr., 12/95 OCL X X CL 96.00 0 0.00 ! acetate NONBONDED nbxmod 5 atom cdiel shift vatom vdistance vswitch - cutnb 14.0 ctofnb 12.0 ctonnb 10.0 eps 1.0 e14fac 1.0 wmin 1.5 !adm jr., 5/08/91, suggested cutoff scheme ! !V(Lennard-Jones) = Eps,i,j[(Rmin,i,j/ri,j)**12 - 2(Rmin,i,j/ri,j)**6] ! !epsilon: kcal/mole, Eps,i,j = sqrt(eps,i * eps,j) !Rmin/2: A, Rmin,i,j = Rmin/2,i + Rmin/2,j ! !atom ignored epsilon Rmin/2 ignored eps,1-4 Rmin/2,1-4 ! C 0.000000 -0.110000 2.000000 ! ALLOW PEP POL ARO ! NMA pure solvent, adm jr., 3/3/93 CA 0.000000 -0.070000 1.992400 ! ALLOW ARO ! benzene (JES) CC 0.000000 -0.070000 2.000000 ! ALLOW PEP POL ARO ! adm jr. 3/3/92, acetic acid heat of solvation CD 0.000000 -0.070000 2.000000 ! ALLOW POL ! adm jr. 3/19/92, acetate a.i. and dH of solvation CE1 0.000000 -0.068000 2.090000 ! ! for propene, yin/adm jr., 12/95 CE2 0.000000 -0.064000 2.080000 ! ! for ethene, yin/adm jr., 12/95 CM 0.000000 -0.110000 2.100000 ! ALLOW HEM ! Heme (6-liganded): CO ligand carbon (KK 05/13/91) CP1 0.000000 -0.020000 2.275000 0.000000 -0.010000 1.900000 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CP2 0.000000 -0.055000 2.175000 0.000000 -0.010000 1.900000 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CP3 0.000000 -0.055000 2.175000 0.000000 -0.010000 1.900000 ! ALLOW ALI ! alkane update, adm jr., 3/2/92 CPA 0.000000 -0.090000 1.800000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPB 0.000000 -0.090000 1.800000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPH1 0.000000 -0.050000 1.800000 ! ALLOW ARO ! adm jr., 10/23/91, imidazole solvation and sublimation CPH2 0.000000 -0.050000 1.800000 ! ALLOW ARO ! adm jr., 10/23/91, imidazole solvation and sublimation CPM 0.000000 -0.090000 1.800000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) CPT 0.000000 -0.090000 1.800000 0.000000 -0.090000 1.900000 ! ALLOW ARO ! benzene (JES) CS 0.000000 -0.110000 2.200000 ! ALLOW SUL ! methylthiolate to water and F.E. of solvation, adm jr. 6/1/92 CT1 0.000000 -0.020000 2.275000 0.000000 -0.010000 1.900000 ! ALLOW ALI ! isobutane pure solvent properties, adm jr, 2/3/92 CT2 0.000000 -0.055000 2.175000 0.000000 -0.010000 1.900000 ! ALLOW ALI ! propane pure solvent properties, adm jr, 2/3/92 CT3 0.000000 -0.080000 2.060000 0.000000 -0.010000 1.900000 ! ALLOW ALI ! methane/ethane a.i. and ethane pure solvent, adm jr, 2/3/92 CY 0.000000 -0.070000 1.992400 ! ALLOW ARO ! TRP, JWK 08/29/89 ! carbon wildcards, following atom order is essential for accurate results !C* 0.000000 -0.070000 2.000000 !CP% 0.000000 -0.090000 1.800000 !C%1 0.000000 -0.020000 2.275000 0.000000 -0.010000 1.900000 !C%2 0.000000 -0.055000 2.175000 0.000000 -0.010000 1.900000 !C%3 0.000000 -0.080000 2.060000 0.000000 -0.010000 1.900000 !CPH+ 0.000000 -0.050000 1.800000 !C 0.000000 -0.110000 2.000000 !CA 0.000000 -0.070000 1.992400 !CE1 0.000000 -0.068000 2.090000 !CE2 0.000000 -0.064000 2.080000 !CM 0.000000 -0.110000 2.100000 !CP3 0.000000 -0.055000 2.175000 0.000000 -0.010000 1.900000 ! ALLOW ALI !CPT 0.000000 -0.090000 1.800000 0.000000 -0.090000 1.900000 !CS 0.000000 -0.110000 2.200000 !CY 0.000000 -0.070000 1.992400 H 0.000000 -0.046000 0.224500 ! ALLOW PEP POL SUL ARO ALC ! same as TIP3P hydrogen, adm jr., 7/20/89 HA 0.000000 -0.022000 1.320000 ! ALLOW PEP ALI POL SUL ARO PRO ALC ! methane/ethane a.i. and ethane pure solvent, adm jr, 2/3/92 HE1 0.000000 -0.031000 1.250000 ! ! for propene, yin/adm jr., 12/95 HE2 0.000000 -0.026000 1.260000 ! ! for ethene, yin/adm jr., 12/95 HB 0.000000 -0.022000 1.320000 ! ALLOW PEP ALI POL SUL ARO PRO ALC ! methane/ethane a.i. and ethane pure solvent, adm jr, 2/3/92 HC 0.000000 -0.046000 0.224500 ! ALLOW POL ! new, small polar Hydrogen, see also adm jr. JG 8/27/89 HP 0.000000 -0.030000 1.358200 0.000000 -0.030000 1.358200 ! ALLOW ARO ! JES 8/25/89 values from Jorgensen fit to hydration energy HR1 0.000000 -0.046000 0.900000 ! ALLOW ARO ! adm jr., 6/27/90, his HR2 0.000000 -0.046000 0.700000 ! ALLOW ARO ! adm jr., 6/27/90, his HR3 0.000000 -0.007800 1.468000 ! ALLOW ARO ! adm jr., 3/24/92, maintain old aliphatic H VDW params HS 0.000000 -0.100000 0.450000 ! ALLOW SUL ! methanethiol pure solvent, adm jr., 6/22/92 HT 0.000000 -0.046000 0.224500 ! ALLOW WAT !TIP3P HYDROGEN PARAMETERS, adm jr., NBFIX obsolete ! hydrogen wildcards !H* 0.000000 -0.046000 0.224500 !HA 0.000000 -0.022000 1.320000 !HE1 0.000000 -0.031000 1.250000 !HE2 0.000000 -0.026000 1.260000 !HB 0.000000 -0.022000 1.320000 !HP 0.000000 -0.030000 1.358200 0.000000 -0.030000 1.358200 !HR1 0.000000 -0.046000 0.900000 !HR2 0.000000 -0.046000 0.700000 !HR3 0.000000 -0.007800 1.468000 !HS 0.000000 -0.100000 0.450000 ! N 0.000000 -0.200000 1.850000 0.000000 -0.000100 1.850000 ! ALLOW PRO ! 6-31g* AcProNH2, ProNH2, 6-31g*//3-21g AcProNHCH3 RLD 4/23/93 NC2 0.000000 -0.200000 1.850000 ! ALLOW POL ! JG 8/27/89; note: NH1 in ARG was changed to NC2. NH1 0.000000 -0.200000 1.850000 0.000000 -0.200000 1.550000 ! ALLOW PEP POL ARO ! This 1,4 vdW allows the C5 dipeptide minimum to exist.(LK) NH2 0.000000 -0.200000 1.850000 ! ALLOW POL ! adm jr. NH3 0.000000 -0.200000 1.850000 ! ALLOW POL ! adm jr. NP 0.000000 -0.200000 1.850000 ! ALLOW PRO ! N-terminal proline; from 6-31g* +ProNH2 RLD 9/28/90 NPH 0.000000 -0.200000 1.850000 ! ALLOW HEM ! Heme (6-liganded): porphyrin macrocycle (KK 05/13/91) NR1 0.000000 -0.200000 1.850000 ! ALLOW ARO ! His, adm jr., 9/4/89 NR2 0.000000 -0.200000 1.850000 ! ALLOW ARO ! His, adm jr., 9/4/89 NR3 0.000000 -0.200000 1.850000 ! ALLOW ARO ! His, adm jr., 9/4/89 NY 0.000000 -0.200000 1.850000 ! ALLOW ARO ! trp, JWK ! nitrogen wildcards !N* 0.000000 -0.200000 1.850000 !N 0.000000 -0.200000 1.850000 0.000000 -0.000100 1.850000 !NH1 0.000000 -0.200000 1.850000 0.000000 -0.200000 1.550000 ! O 0.000000 -0.120000 1.700000 0.000000 -0.120000 1.400000 ! ALLOW PEP POL ! This 1,4 vdW allows the C5 dipeptide minimum to exist.(LK) OB 0.000000 -0.120000 1.700000 0.000000 -0.120000 1.400000 ! ALLOW PEP POL ARO ! adm jr., 10/17/90, acetic acid carbonyl O OC 0.000000 -0.120000 1.700000 ! ALLOW POL ION ! JG 8/27/89 OH1 0.000000 -0.152100 1.770000 ! ALLOW ALC ARO ! adm jr. 8/14/90, MeOH nonbond and solvent (same as TIP3P) OM 0.000000 -0.120000 1.700000 ! ALLOW HEM ! Heme (6-liganded): CO ligand oxygen (KK 05/13/91) OS 0.000000 -0.152100 1.770000 ! ALLOW ALC ARO ! adm jr. 9/17/90, avoid O* wildcard OT 0.000000 -0.152100 1.768200 ! ALLOW WAT !TIP3P OXYGEN PARAMETERS, adm jr., NBFIX obsolete ! oxygen wildcards !O* 0.000000 -0.120000 1.700000 0.000000 -0.120000 1.400000 !OC 0.000000 -0.120000 1.700000 !OH1 0.000000 -0.152100 1.770000 !OM 0.000000 -0.120000 1.700000 !OS 0.000000 -0.152100 1.770000 !OT 0.000000 -0.152100 1.768200 !CAL 0.000000 -0.120000 1.710000 ! ALLOW ION ! !Calcium (BP) FE 0.010000 0.000000 0.650000 ! ALLOW HEM ! Heme (6-liganded): Iron atom (KK 05/13/91) S 0.000000 -0.450000 2.000000 ! ALLOW SUL ION ! adm jr., 3/3/92, methanethiol/ethylmethylsulfide pure solvent SM 0.000000 -0.380000 1.975000 ! ALLOW SUL ION ! adm jr., 3/3/92, dimethyldisulphide pure solvent SS 0.000000 -0.470000 2.200000 ! ALLOW SUL ! methylthiolate to water and F.E. of solvation, adm jr. 6/1/92 ZN 0.000000 -0.250000 1.090000 ! ALLOW ION ! RHS March 18, 1990 DUM 0.000000 -0.000000 0.000000 ! ! dummy atom HE 0.000000 -0.021270 1.4800 ! ! helium, experimental pot. energy surface, adm jr., 12/95 NE 0.000000 -0.086000 1.5300 ! neon, semiempirical pot. energy surface, adm jr., 12/95 !lipids section HOL 0.0 -0.046 0.2245 HAL1 0.0 -0.022 1.3200 ! alkane, 3/92 HAL2 0.0 -0.028 1.3400 ! alkane, yin and mackerell, 4/98 HAL3 0.0 -0.024 1.3400 ! alkane, yin and mackerell, 4/98 HCL 0.0 -0.046 0.2245 ! ethanolamine !HT 0.0 -0.046 0.2245 HL 0.0 -0.046 0.7 ! polar H on NC4+ HEL1 0.0 -0.031 1.25 ! alkene, yin,adm jr., 12/95 HEL2 0.0 -0.026 1.26 ! alkene, yin,adm jr., 12/95 ! CL 0.0 -0.070 2.00 ! methyl acetate update CTL1 0.0 -0.0200 2.275 0.0 -0.01 1.9 ! alkane, 3/92 CTL2 0.0 -0.0560 2.010 0.0 -0.01 1.9 ! alkane, 4/98, yin, adm jr. CTL3 0.0 -0.0780 2.040 0.0 -0.01 1.9 ! alkane, 4/98, yin, adm jr. CTL5 0.0 -0.0800 2.06 0.0 -0.01 1.9 ! old CTL3 ! maintained for tetramethylammonium CEL1 0.0 -0.068 2.09 ! alkene, yin,adm jr., 12/95 CEL2 0.0 -0.064 2.08 ! alkene, yin,adm jr., 12/95 ! OBL 0.0 -0.12 1.70 0.0 -0.12 1.4 OCL 0.0 -0.12 1.70 O2L 0.0 -0.12 1.70 OHL 0.0 -0.1521 1.77 OSL 0.0 -0.1521 1.77 !OT 0.0 -0.1521 1.7682 ! NH3L 0.0 -0.20 1.85 ! ethanolamine NTL 0.0 -0.20 1.85 ! as all other nitogens ! SL 0.0 -0.47 2.1 ! methylsulfate PL 0.0 -0.585 2.15 ! ADM Jr. !DUM 0.0 -0.00 0.0 ! dummy atom ! ! ions, note lack of NBFIXes ! SOD 0.0 -0.0469 1.36375 ! sodium ! D. Beglovd and B. Roux, dA=-100.8 kcal/mol POT 0.0 -0.0870 1.76375 ! potassium ! D. Beglovd and B. Roux, dA=-82.36+2.8 = -79.56 kca/mol CLA 0.0 -0.150 2.27 ! chloride ! D. Beglovd and B. Roux, dA=-83.87+4.46 = -79.40 kcal/mol CAL 0.0 -0.120 1.367 ! Calcium ! S. Marchand and B. Roux, dA = -384.8 kcal/mol MG 0.0 -0.0150 1.18500 ! Magnesium ! B. Roux dA = -441.65 CES 0.0 -0.1900 2.100 ! Cesium, so far untested. HBOND CUTHB 0.5 ! If you want to do hbond analysis (only), then use ! READ PARAM APPEND CARD ! to append hbond parameters from the file: par_hbond.inp END cctools-4.0-source/apps/replica_exchange_protomol/protomol_functions.py0000640060042600000500000001177312175446362025664 0ustar btovardip#! /usr/bin/env python import random import math #-------------------------------Constants----------------------------------- DEFAULT_MONTE_CARLO_STEPS = 100 DEFAULT_OUTPUT_PATH = '.' DEFAULT_MDSTEPS = 10000 DEFAULT_BOUNDARY_CONDITIONS = "Vacuum" DEFAULT_OUTPUT_FREQ = 10000 DEFAULT_PHYSICAL_TEMP = 300 EXECUTABLE = "ProtoMol" #-----------------------------Global Data------------------------------------- pdb_file = "" psf_file = "" par_file = "" xyz_file_name = "" dcd_file_name = "" boundary_conditions = DEFAULT_BOUNDARY_CONDITIONS monte_carlo_steps = DEFAULT_MONTE_CARLO_STEPS md_steps = DEFAULT_MDSTEPS output_freq = DEFAULT_OUTPUT_FREQ output_path = DEFAULT_OUTPUT_PATH replica_list = [] #------------------------Initialize random generator---------------------------- random.seed() #-------------------------Global functions--------------------------------- #Function to parse the file name from a string holding its location. def parse_file_name(file_name): split_name = file_name.split('/') return split_name[len(split_name)-1] #Function to parse the file name and leave out its extension. def remove_trailing_dots(file_name): split_name = file_name.split('.') return split_name[0] #-------------------------Define Replica Object--------------------------------- class Replica(object): def __init__(self, id, temp): self.id = id self.temp = temp self.exchgd_replica_id = -1 self.potential_energy = None self.prev_temp = None self.exch_steps = [] self.running = 0 self.last_seen_step = -1 def __str__(self): return "Replica %d at temp %f" % (self.id, self.temp) #Function to generate a config file to send to workqueue. It returns the generated config file name. def generate_config(output_path, pdb_file, psf_file, par_file, monte_carlo_step, md_steps, output_freq, replica_obj, generate_xyz = False, generate_dcd = False): #initialize the config file name based on the replica id. cfg_file_name = "%s/%s/%s/%d/%d-%d.cfg" % ( output_path, "simfiles", "config", replica_obj.id, replica_obj.id, monte_carlo_step) cfg_file_stream = open(cfg_file_name, "w") #initialize string that will hold the config file values write_str = "" #Parse supplied files so only actual file name is passed, not full path of the file name input_pdb = "%s.%d-%d.pdb" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_obj.id, monte_carlo_step) parsed_psf_file = parse_file_name(psf_file) parsed_par_file = parse_file_name(par_file) #Start writing the config file parameters and values write_str += "randomtype 1\n" write_str += "numsteps %d\n" % md_steps write_str += "outputfreq %d\n" % output_freq write_str += "posfile %s\n" % input_pdb write_str += "psffile %s\n" % parsed_psf_file write_str += "parfile %s\n" % parsed_par_file if monte_carlo_step > 0: write_str += "velfile %s.%d-%d.vel\n" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_obj.id, monte_carlo_step) write_str += "dofinPDBPosFile true\n" write_str += "finPDBPosFile %s.%d-%d.pdb\n" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_obj.id, monte_carlo_step+1) write_str += "finXYZVelFile %s.%d-%d.vel\n" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_obj.id, monte_carlo_step+1) write_str += "temperature %f\n" % replica_obj.temp write_str += "boundaryConditions %s\n" % boundary_conditions write_str += "cellManager Cubic\n" write_str += "cellsize 69\n" if generate_xyz: write_str += "XYZPosFile %d.xyz\n" % replica_obj.id write_str += "XYZPosFileOutputFreq %d\n" % md_steps if generate_dcd: write_str += "DCDFile %d.dcd\n" % replica_obj.id write_str += "DCDFileOutputFreq %d\n" % output_freq write_str += "allEnergiesFile %d.eng\n" % replica_obj.id write_str += "allEnergiesFileOutputFreq %d\n" % output_freq write_str += "seed %d\n" % random.randint(1, 1000000) write_str += "shake on\n" write_str += "integrator {\n" write_str += "level 0 langevinImpulse {\n" write_str += "temperature %f\n" % replica_obj.temp write_str += "gamma 5\n" write_str += "timestep 2\n" write_str += "force bond\n" write_str += "force angle\n" write_str += "force dihedral\n" write_str += "force improper\n" write_str += "force LennardJones Coulomb\n" write_str += " -switchingFunction C2 -switchingFunction C1 -algorithm NonbondedCutoff\n" write_str += " -switchon 10\n" write_str += " -cutoff 12\n" write_str += " -cutoff 12\n" write_str += " -cutoff 12\n" write_str += "}\n}" #Write to the config file cfg_file_stream.write(write_str) return cfg_file_name #Function that to perform metropolis criteria check for two replicas. def metropolis( u_i, u_j, t_i, t_j ): # Metropolis for replica i with potential energy u_i, temp t_i # and replica j with potential energy u_j, temp t_j K_b = 0.001987191 #Constants.boltzmann() deltaE = (1 / (K_b * t_i) - 1/ (K_b * t_j) ) - (u_j - u_i) if( deltaE < 0 ): return True acceptProb = math.exp(-deltaE) randNum = random.random() if( randNum < acceptProb ): return True else: return False cctools-4.0-source/apps/replica_exchange_protomol/replica_exchange.py0000751060042600000500000006331212175446362025201 0ustar btovardip#! /usr/bin/env python # replica_exchange.py # # Copyright (C) 2011- The University of Notre Dame # This software is distributed under the GNU General Public License. # See the file COPYING for details. # # This program implements elastic replica exchange using # the cctools work queue framework and the Protomol molecular # dynamics package, as described in the following paper: # # Dinesh Rajan, Anthony Canino, Jesus A Izaguirre, and Douglas Thain, # "Converting a High Performance Application to an Elastic Cloud Application", # The 3rd IEEE International Conference on Cloud Computing Technology # and Science", November 2011. # From the cctools python bindings, use work queue. from work_queue import * # Get ProtoMol related bindings from protomol_functions. from protomol_functions import * # All other dependencies are standard python. import time import sys import os import pprint import re import getopt #-------------------------------Global Variables---------------------------- protomol_local_install = False use_barrier = False generate_xyz = False generate_dcd = False debug_mode = False quart_temp_split = False mc_step_times = [] #------------------------------Global Data-------------------------------------- replica_id = None proj_name = None replicas_running = 0 #------------------------Stat Collection Variables------------------------------ num_replica_exchanges = 0 num_task_resubmissions = 0 replica_temp_execution_list = [] replica_exch_list = [] step_time = 0 #--------------------------------Program Meat----------------------------------- #Function to drop repetetive values and gather just the unique ones. def unique(inlist, keep_val=True): typ = type(inlist) if not typ == list: inlist = list(inlist) i = 0 while i < len(inlist): try: del inlist[inlist.index(inlist[i], i + 1)] except: i += 1 if not typ in (str, unicode): inlist = type(inlist) else: if keep_val: inlist = ''.join(inlist) return inlist #Function to check if a given executable exists in PATH. def locate(executable): def check_executable(prog): return os.path.exists(prog) and os.access(prog, os.X_OK) for path in os.environ["PATH"].split(os.pathsep): exe = os.path.join(path, executable) if check_executable(exe): return exe return None #Function to generate execution script that runs simulations of a replica # over given number of steps def generate_execn_script(replica_obj, replica_next_starting_step, replica_next_ending_step): #assign script file name based on the replica id. execn_script_name = "%s/%s/%s/exec-%d.sh" % (output_path, "simfiles", "runs", replica_obj.id) execn_script_stream = open(execn_script_name, "w") #check if protomol comes installed on the remote worker site. if protomol_local_install: execn_string = "%s" % EXECUTABLE else: execn_string = "./%s" % EXECUTABLE #initialize string that will hold the file strings. write_str = "" #write protomol execution commands for steps to be run for this replica. write_str += "#!/bin/sh\n\n" for i in range(replica_next_starting_step, replica_next_ending_step+1): write_str += "%s %d-%d.cfg\n" % (execn_string, replica_obj.id, i) #Write to file execn_script_stream.write(write_str) execn_script_stream.close() #Make file executable os.chmod(execn_script_name, 0755) return execn_script_name #Setup and initalize WorkQueue def create_wq(): #Instantiate workqueue instance. wq = WorkQueue() wq.specify_algorithm(WORK_QUEUE_SCHEDULE_RAND) if proj_name: wq.specify_name(proj_name) return wq #Create a new WorkQueue task. def create_wq_task(replica_id): #Task string will be running the execution script. task_str = "./exec-%d.sh" % replica_id #Create a task using given task string for remote worker to execute. task = Task(task_str) task.specify_tag('%s' % replica_id) return task #Assign all the input files for the task (replica). def assign_task_output_files(task, replica_list, replica_id, replica_next_starting_step, replica_next_ending_step): #Find pdb file for current replica replica_pdb = "%s.%d" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_id) #Assign local and remote xyz output files. if generate_xyz: local_xyz_output_file = "%s/simfiles/%s/%s.%d-%d.xyz" % (output_path, replica_list[replica_id].temp, xyz_file_name, replica_id, replica_next_ending_step) remote_xyz_output_file = "%d.xyz" % (replica_id) task.specify_output_file(remote_xyz_output_file, local_xyz_output_file) #Assign local and remote dcd output files. if generate_dcd: local_dcd_output_file = "%s/simfiles/%s/%s.%d-%d.dcd" % (output_path, replica_list[replica_id].temp, dcd_file_name, replica_id, replica_next_ending_step) remote_dcd_output_file = "%d.dcd" % (replica_id) task.specify_output_file(remote_dcd_output_file, local_dcd_output_file) #Assign local and remote (output) energies files. local_energies_file = "%s/simfiles/eng/%d/%d.eng" % (output_path, replica_id, replica_id) remote_energies_file = "%d.eng" % replica_id task.specify_output_file(local_energies_file, remote_energies_file, cache=False) #Assign local and remote velocity output files. local_velocity_output_file = "%s/simfiles/%s/%s-%d.vel" % (output_path, replica_list[replica_id].temp, replica_pdb, replica_next_ending_step+1) remote_velocity_output_file = "%s-%d.vel" % (replica_pdb, replica_next_ending_step+1) task.specify_output_file(local_velocity_output_file, remote_velocity_output_file, cache=False) pdb_output_file = "%s/simfiles/%s/%s-%d.pdb" % (output_path, replica_list[replica_id].temp, replica_pdb, replica_next_ending_step+1) task.specify_output_file(pdb_output_file, parse_file_name(pdb_output_file), cache=False) #Assign all the output files for the task (replica). def assign_task_input_files(task, replica_list, replica_id, replica_next_starting_step, replica_next_ending_step): #Find pdb file for current replica replica_pdb = "%s.%d" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_id) #Find pdb file for replica that exchanged with current replica in last step if (replica_list[replica_id].exchgd_replica_id > -1): exchgd_replica_pdb = "%s.%d" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_list[replica_id].exchgd_replica_id) else: exchgd_replica_pdb = "%s.%d" % (remove_trailing_dots(parse_file_name(pdb_file)), replica_id) '''Local_file: name for file brought back and stored on local site where this is run. Remote_file: name for file sent to remote worker and used in execution there.''' #Assign local and remote execution scripts local_execn_file = "%s/simfiles/%s/exec-%d.sh" % (output_path, "runs", replica_id) remote_execn_file = "exec-%d.sh" % (replica_id) task.specify_input_file(local_execn_file, remote_execn_file, cache=False) #Assign local and remote psf and par inputs task.specify_input_file(psf_file, parse_file_name(psf_file)) task.specify_input_file(par_file, parse_file_name(par_file)) #Assign local and remote pdb inputs local_pdb_input_file = "%s/simfiles/%s/%s-%d.pdb" % (output_path, replica_list[replica_id].temp, exchgd_replica_pdb, replica_next_starting_step) remote_pdb_input_file = "%s-%d.pdb" % (replica_pdb, replica_next_starting_step) task.specify_input_file(local_pdb_input_file, remote_pdb_input_file, cache=False) #Velocity input only required after first step since it is output #of first step. if (replica_next_starting_step > 0): #Assign local and remote velocity input files. local_velocity_input_file = "%s/simfiles/%s/%s-%d.vel" % (output_path, replica_list[replica_id].temp, exchgd_replica_pdb, replica_next_starting_step) remote_velocity_input_file = "%s-%d.vel" % (replica_pdb, replica_next_starting_step) task.specify_input_file(local_velocity_input_file, remote_velocity_input_file, cache=False) for i in range(replica_next_starting_step, replica_next_ending_step+1): #Assign local and remote config files. local_config_file = "%s/simfiles/config/%d/%d-%d.cfg" % (output_path, replica_id, replica_id, i) remote_config_file = "%d-%d.cfg" % (replica_id, i) task.specify_input_file(local_config_file, remote_config_file, cache=False) #Call function to generate execution script. generate_execn_script(replica_list[replica_id], replica_next_starting_step, replica_next_ending_step) #Assign executable that will be run on remote worker to task string. if not protomol_local_install: local_executable = "%s" % (EXECUTABLE) remote_executable = "%s" % (EXECUTABLE) task.specify_input_file(local_executable, remote_executable) # Major replica exchange and scheduling is handled here def wq_main(wq, replica_list, replicas_to_run): #Stat collection variables global replicas_running global step_time #Variable that tracks replicas which completed simulations over all MC steps num_replicas_completed = 0 #-------Perform computation for each replica at current monte carlo step-------- '''Each computation is a task in work queue. Each task will be run on one of the connected workers.''' while num_replicas_completed < len(replica_list): #Iterate through the given set of replicas and start their # computation for the current monte carlo step. for j in replicas_to_run: if not replica_list[j].running: #Initialize step time. step_time = time.time() replica_id = replica_list[j].id #Each replica does computation at its current temperature replica_temperature = replica_list[j].temp '''Get the last seen step of replica. The last_seen_step is the step at which this replica was brought back and attempted for an exchange.''' replica_last_seen_step = replica_list[j].last_seen_step #record the starting, ending steps for current iteration of #this replica. replica_next_starting_step = replica_last_seen_step + 1 if replica_next_starting_step >= monte_carlo_steps: break if use_barrier: #Barrier version, so run one step at a time. replica_next_ending_step = replica_next_starting_step else: #Run all steps until the step where the replica will be #chosen to attempt an exchange. if len(replica_list[j].exch_steps) > 0: replica_next_ending_step = replica_list[j].exch_steps[0] #If there are no more exchange steps for this replica, run the #remainder of monte carlo steps. else: replica_next_ending_step = monte_carlo_steps-1 #Set the last_seen_step to the next exchange step at which the #replica (its output) will be brought back. replica_list[j].last_seen_step = replica_next_ending_step task = create_wq_task(replica_id) assign_task_input_files(task, replica_list, replica_id, replica_next_starting_step, replica_next_ending_step) assign_task_output_files(task, replica_list, replica_id, replica_next_starting_step, replica_next_ending_step) #Keep count of replicas that iterated through all MC steps. if (replica_next_ending_step == monte_carlo_steps-1): num_replicas_completed += 1 #Submit the task to WorkQueue for execution at remote worker. wq.submit(task) #Submitted for execution. So mark this replica as running. replica_list[j].running = 1 replicas_running += 1 #Wait for tasks to complete. if use_barrier: replicas_to_run=wq_wait_barrier(wq, replica_list, replica_next_starting_step, 5) else: replicas_to_run=wq_wait_nobarrier(wq, replica_list, 5) '''The barrier version where it waits for all replicas to finish a given MC step. Returns all the replicas that it waited for.''' def wq_wait_barrier(wq, replica_list, monte_carlo_step, timeout): #Stat collection variables global step_time global num_task_resubmissions global replicas_running #Initialize list that contains replicas that will be returned to run next. replica_to_run = [] #Wait for all replicas to finish execution, while not wq.empty(): task = wq.wait(timeout) if (task): #Get replica id from finished task. replica_id = int(task.tag) # Check if task (replica) failed. If so, resubmit. if task.result != 0: num_task_resubmissions += 1 print "Replica failed!" time.sleep(3) #Resubmit the task. wq.submit(task) continue #Task was succesful. Update run information. replicas_running -= 1 replica_list[replica_id].running = 0 #Get potential energy value of the completed replica run. energies_file = "%s/simfiles/eng/%d/%d.eng" % (output_path, replica_id, replica_id) energies_stream = open(energies_file, "r") slist = (energies_stream.readline()).split() potential_energy = float(slist[1]) replica_list[replica_id].potential_energy = potential_energy #Store temperature and exchanged replica id values from the current run. replica_list[replica_id].prev_temp = replica_list[replica_id].temp replica_list[replica_id].exchgd_replica_id = replica_id #Add this replica to return list. replica_to_run.append(replica_id) #Get replica exchange pair for current step and attempt exchange. cur = replica_exch_list[monte_carlo_step].pop(0) next = replica_exch_list[monte_carlo_step].pop(0) if debug_mode: print "Replicas %d & %d are attempted for an exchange at step %d" % (cur, next, monte_carlo_step) #Attempt exchange between the two. attempt_replica_exch(replica_list, cur, next) #Update time stats for this MC step. step_time = time.time() - step_time mc_step_times.append(step_time) return replica_to_run '''The nobarrier version where it receives a finished replica, waits for its exchange partner to finish, attempts an exchange between the two, and continues waiting for the rest similarly. Returns the replica pair that finished and was attempted for an exchange.''' def wq_wait_nobarrier(wq, replica_list, timeout): #Stat collection variables global num_task_resubmissions global replicas_running #Wait for a task to finish execution. while not wq.empty(): task = wq.wait(timeout) if (task): #Get replica id from finished task. replica_id = int(task.tag) #Check if task (replica) failed. If so, resubmit. if task.result != 0: num_task_resubmissions += 1 print "Replica failed!" time.sleep(3) #Resubmit the task. wq.submit(task) continue #Task was succesful. Update run information. replicas_running -= 1 replica_list[replica_id].running = 0 #Get potential energy value of the completed replica run. energies_file = "%s/simfiles/eng/%d/%d.eng" % (output_path, replica_id, replica_id) energies_stream = open(energies_file, "r") slist = (energies_stream.readline()).split() potential_energy = float(slist[1]) replica_list[replica_id].potential_energy = potential_energy #Store temperature and exchanged replica id values from the current run. replica_list[replica_id].prev_temp = replica_list[replica_id].temp replica_list[replica_id].exchgd_replica_id = replica_id #Replica should be currently at this step which is its exchange step. if len(replica_list[replica_id].exch_steps) > 0: replica_exch_step = replica_list[replica_id].exch_steps.pop(0) #Else replica is at the last MC step of this run. else: replica_exch_step = monte_carlo_steps - 1 #Find the exchange partner of this replica. if (replica_id == replica_exch_list[replica_exch_step][0]): replica_exch_partner = replica_exch_list[replica_exch_step][1] elif (replica_id == replica_exch_list[replica_exch_step][1]): replica_exch_partner = replica_exch_list[replica_exch_step][0] else: if (replica_exch_step != (monte_carlo_steps-1)): #If this replica is not part of the exchange pair for this #step and is not at the last MC step of the run, something #is amiss.. print "Replica %d should not be here at step %d" % (replica_id, replica_exch_step) sys.exit(1) else: #If all replicas have completed last MC step, return. if replicas_running == 0: return #If not, loop back to receive other replicas. else: continue #If exchange partner is still running, go back to get other tasks. if replica_list[replica_exch_partner].running: continue #Otherwise check if partner has finished the current exchange step. else: if (replica_list[replica_exch_partner].last_seen_step < replica_exch_step): #Exchange partner is currently behind the exchange step of #this replica. So loop back to get other tasks. continue elif (replica_list[replica_exch_partner].last_seen_step > replica_exch_step): #Should never get here. Something went wrong. print "Partner of replica %d - replica %d is currently at step %d which is beyond step %d" % (replica_id, replica_exch_partner, replica_list[replica_exch_partner].exch_steps[0], replica_exch_step) sys.exit(1) else: #Make sure the replicas are checked in the same order they were chosen at the start. if (replica_exch_partner == replica_exch_list[replica_exch_step][0]): replica_1 = replica_exch_partner replica_2 = replica_id else: replica_1 = replica_id replica_2 = replica_exch_partner if debug_mode: print "Replicas %d & %d are attempted for an exchange at step %d" % (replica_1, replica_2, replica_exch_step) #Attempt exchange between the two. attempt_replica_exch(replica_list, replica_1, replica_2) #Add these two replicas to return list. replicas_to_run = [replica_1, replica_2] return replicas_to_run #Check if two replicas satisfy the criteria to undergo an exchange. def attempt_replica_exch(replica_list, replica1, replica2): global num_replica_exchanges #Check for metropolis criteria. if (metropolis(replica_list[replica1].potential_energy, replica_list[replica2].potential_energy, replica_list[replica1].temp, replica_list[replica2].temp)): #Swap fields of the two replicas being exchanged. T = replica_list[replica2].temp replica_list[replica2].temp = replica_list[replica1].temp replica_list[replica1].temp = T replica_list[replica1].exchgd_replica_id = replica_list[replica2].id replica_list[replica2].exchgd_replica_id = replica_list[replica1].id replica_temp_execution_list[replica1].append(replica_list[replica1].temp) replica_temp_execution_list[replica2].append(replica_list[replica2].temp) if debug_mode: print "Replicas %d and %d exchanged" % (replica1, replica2) #Keep count of exchanges. num_replica_exchanges += 1 #Function to create directories to hold files from the simulations. def make_directories(output_path, temp_list, num_replicas): count = 0 #For each temperature value, create a directory with its name. for i in temp_list: newdir1 = "%s/simfiles/%s" % (output_path, i) if not os.path.exists(newdir1): os.makedirs(newdir1) command = "cp %s %s/simfiles/%s/%s.%d-%d.pdb" % (pdb_file, output_path, i, remove_trailing_dots(parse_file_name(pdb_file)), count, 0) print command os.system(command) count += 1 #Create eng (energies) directory to hold energy files of replicas. for j in range(num_replicas): newdir2 = "%s/simfiles/%s/%s" % (output_path, "eng", j) if not os.path.exists(newdir2): os.makedirs(newdir2) #Create config (configuration) directory to hold config files of replicas. for j in range(num_replicas): newdir3 = "%s/simfiles/%s/%s" % (output_path, "config", j) if not os.path.exists(newdir3): os.makedirs(newdir3) #Create directory to hold execution scripts of replicas. newdir4 = "%s/simfiles/%s" % (output_path, "runs") if not os.path.exists(newdir4): os.makedirs(newdir4) #Function to determine the replica exchange pairs that will be attempted for an #exchange at each MC step. def create_replica_exch_pairs(replica_list, num_replicas): #Compute random pair (replica, neighbor) for each step to attempt exchange. for i in range(monte_carlo_steps): replica_1 = random.randint(0, num_replicas-1) replica_2 = replica_1 + 1 if (replica_2 == num_replicas): replica_2 = replica_1 - 1 #List that stores replicas attempted for exchange at each step. replica_exch_list.append([]) replica_exch_list[i].append(replica_1) replica_exch_list[i].append(replica_2) #Store the steps at which each replica will be attempted for exchange. replica_list[replica_1].exch_steps.append(i) replica_list[replica_2].exch_steps.append(i) if debug_mode: print "For step %d, exchange will be attempted for replica %d and %d." % (i, replica_1, replica_2) #Main function. if __name__ == "__main__": #Create help string for user. usage_str = "Usage: %s " % sys.argv[0] help_str = "-n - specify a project name for using exclusive workers\n" help_str += "-x - specify the name of the xyz file for output\n" help_str += "-d - specify the name of the dcd file for output\n" help_str += "-m - specify the number of monte carlo steps\n" help_str += "-s - specify the number of mdsteps\n" help_str += "-p - specify the output_path for the output files generated\n" help_str += "-q - assign closer temperature values to the first and last quartile of the replicas.\n" help_str += "-i - assume ProtoMol is installed and available in PATH on worker site\n" help_str += "-b - use barrier in waiting for all replicas to finish their steps before attempting exchange.\n" help_str += "-l - print debuging information\n" help_str += "-h - help" #Check to see if there is error in the given command line arguments. try: opts, args = getopt.getopt(sys.argv[1:], "n:x:d:m:s:p:qiblh", ["help"]) except getopt.GetoptError, err: print str(err) print usage_str sys.exit(1) #Parse command line arguments. for o, a in opts: if o in ("-h", "--help"): print help_str sys.exit(0) elif o == "-l": debug_mode = True elif o in ("-x"): generate_xyz = True xyz_file_name = a elif o in ("-d"): generate_dcd = True dcd_file_name = a elif o in ("-n"): proj_name = a elif o in ("-p"): output_path = a elif o in ("-m"): monte_carlo_steps = int(a) elif o in ("-s"): md_steps = int(a) elif o == "-q": quart_temp_split = True elif o == "-i": protomol_local_install = True elif o == "-b": use_barrier = True #Check for the 6 mandatory arguments. if len(args) != 6: print usage_str sys.exit(1) if debug_mode: print "Debug mode on.." set_debug_flag("wq") set_debug_flag("debug") protomol_path = locate(EXECUTABLE) if protomol_path: command = "cp %s ." % protomol_path os.system(command) else: print "Error: Please add %s to your PATH." % (EXECUTABLE) sys.exit(1) #Begin timing after parsing command line arguments. total_run_time = time.time() #Parse command line to get input file names, # temperature range for simulation, # number of replicas to run. pdb_file = args[0] psf_file = args[1] par_file = args[2] min_temp = int(args[3]) max_temp = int(args[4]) num_replicas = int(args[5]) replica_list = [] #Split up the temperature range for assigning to each replica. inc = float(( max_temp - min_temp)) / float(num_replicas-1) temp_list = [] #Assign temperature to each replica. for x in range(num_replicas): #Quart split assigns closer temperature values # to the top and bottom 25% of replicas. if quart_temp_split: if x < math.ceil(0.25 * num_replicas): replica_temp = min_temp + (x * inc / 3) elif x >= math.ceil(0.75 * num_replicas): replica_temp = max_temp - (((num_replicas-1) - x) * inc / 3) else: replica_temp = min_temp + (x * inc) #If not quart split, split temperature range uniformly # among all replicas. else: replica_temp = min_temp + (x * inc) #Store the temperature values and replicas. temp_list.append(str(replica_temp)) replica_list.append(Replica(x, replica_temp)) #Initialize list for maintaining replica exchange matrix. replica_temp_execution_list.append([]) #Add the initial temperature value to the replica exchange matrix. for repl in range(num_replicas): replica_temp_execution_list[repl].append(replica_list[repl].temp) #Create directories for storing data from the run. make_directories(output_path, temp_list, num_replicas) #Create random replica pairs to check for exchange at each step. create_replica_exch_pairs(replica_list, num_replicas) #create config files here. for i in range(monte_carlo_steps): for j in range(num_replicas): generate_config(output_path, pdb_file, psf_file, par_file, i, md_steps, output_freq, replica_list[j]) replicas_to_run = [] for i in range(num_replicas): replicas_to_run.append(i) #Instantiate WQ. wq = create_wq() #Start the run. wq_main(wq, replica_list, replicas_to_run) #Track total run time. total_run_time = (time.time() - total_run_time) #Print stats on completion. print "Total Run Time: %f" % total_run_time print "Number of failures: %d" % num_task_resubmissions print "Replica Exchanges: %d" % num_replica_exchanges print "Acceptance Rate: %f" % ((num_replica_exchanges * 100) / monte_carlo_steps) #Write stats to a stats file stat_file_name = "%s/%s.stat" % (output_path, remove_trailing_dots(parse_file_name(pdb_file))) stat_file_stream = open(stat_file_name, "w") stat_file_stream.write("%s\n" % "Printing replica temperature execution matrix:") #Sort and format the replica exchange matrix. for itr in range(num_replicas): replica_temp_execution_list[itr].sort() unique(replica_temp_execution_list[itr]) stat_file_stream.write("Replica %d: %s\n" % (itr, replica_temp_execution_list[itr])) #If barrier version was used, write the MC step times to stats file. if use_barrier: #Write run time for each step to stats file stat_file_stream.write("\n\n%s\n" % "Printing run times for each monte carlo step:") count = 1 for i in mc_step_times: stat_file_stream.write("%d %f\n" % (count, i)) count += 1 stat_file_stream.close() sys.exit(0) cctools-4.0-source/apps/replica_exchange_protomol/ww_exteq_nowater1.pdb0000640060042600000500000012506412175446362025520 0ustar btovardipREMARK original generated coordinate pdb file ATOM 1 N LYS P 6 -12.740 67.537 74.583 1.00 0.00 WWDM N ATOM 2 HT1 LYS P 6 -12.108 67.383 75.412 1.00 0.00 WWDM H ATOM 3 HT2 LYS P 6 -12.286 68.229 73.936 1.00 0.00 WWDM H ATOM 4 HT3 LYS P 6 -13.642 67.959 74.919 1.00 0.00 WWDM H ATOM 5 CA LYS P 6 -12.974 66.235 73.893 1.00 0.00 WWDM C ATOM 6 HA LYS P 6 -13.593 65.643 74.551 1.00 0.00 WWDM H ATOM 7 CB LYS P 6 -13.724 66.508 72.560 1.00 0.00 WWDM C ATOM 8 HB1 LYS P 6 -14.701 66.996 72.790 1.00 0.00 WWDM H ATOM 9 HB2 LYS P 6 -13.135 67.222 71.939 1.00 0.00 WWDM H ATOM 10 CG LYS P 6 -14.000 65.260 71.704 1.00 0.00 WWDM C ATOM 11 HG1 LYS P 6 -13.040 64.836 71.330 1.00 0.00 WWDM H ATOM 12 HG2 LYS P 6 -14.501 64.479 72.321 1.00 0.00 WWDM H ATOM 13 CD LYS P 6 -14.904 65.582 70.504 1.00 0.00 WWDM C ATOM 14 HD1 LYS P 6 -15.892 65.913 70.901 1.00 0.00 WWDM H ATOM 15 HD2 LYS P 6 -14.466 66.437 69.935 1.00 0.00 WWDM H ATOM 16 CE LYS P 6 -15.096 64.391 69.557 1.00 0.00 WWDM C ATOM 17 HE1 LYS P 6 -14.168 64.193 68.975 1.00 0.00 WWDM H ATOM 18 HE2 LYS P 6 -15.370 63.474 70.135 1.00 0.00 WWDM H ATOM 19 NZ LYS P 6 -16.185 64.679 68.609 1.00 0.00 WWDM N ATOM 20 HZ1 LYS P 6 -17.079 64.769 69.155 1.00 0.00 WWDM H ATOM 21 HZ2 LYS P 6 -16.023 65.570 68.066 1.00 0.00 WWDM H ATOM 22 HZ3 LYS P 6 -16.331 63.867 67.960 1.00 0.00 WWDM H ATOM 23 C LYS P 6 -11.685 65.460 73.660 1.00 0.00 WWDM C ATOM 24 O LYS P 6 -10.677 66.028 73.242 1.00 0.00 WWDM O ATOM 25 N LEU P 7 -11.644 64.145 73.971 1.00 0.00 WWDM N ATOM 26 HN LEU P 7 -12.456 63.662 74.303 1.00 0.00 WWDM H ATOM 27 CA LEU P 7 -10.425 63.360 73.844 1.00 0.00 WWDM C ATOM 28 HA LEU P 7 -9.687 63.963 74.345 1.00 0.00 WWDM H ATOM 29 CB LEU P 7 -10.453 62.061 74.692 1.00 0.00 WWDM C ATOM 30 HB1 LEU P 7 -9.402 61.724 74.828 1.00 0.00 WWDM H ATOM 31 HB2 LEU P 7 -10.839 62.313 75.706 1.00 0.00 WWDM H ATOM 32 CG LEU P 7 -11.246 60.842 74.168 1.00 0.00 WWDM C ATOM 33 HG LEU P 7 -10.862 60.573 73.157 1.00 0.00 WWDM H ATOM 34 CD1 LEU P 7 -11.013 59.634 75.095 1.00 0.00 WWDM C ATOM 35 HD11 LEU P 7 -9.929 59.405 75.172 1.00 0.00 WWDM H ATOM 36 HD12 LEU P 7 -11.398 59.856 76.115 1.00 0.00 WWDM H ATOM 37 HD13 LEU P 7 -11.540 58.737 74.706 1.00 0.00 WWDM H ATOM 38 CD2 LEU P 7 -12.754 61.087 74.050 1.00 0.00 WWDM C ATOM 39 HD21 LEU P 7 -13.276 60.159 73.722 1.00 0.00 WWDM H ATOM 40 HD22 LEU P 7 -13.176 61.395 75.033 1.00 0.00 WWDM H ATOM 41 HD23 LEU P 7 -12.975 61.883 73.308 1.00 0.00 WWDM H ATOM 42 C LEU P 7 -9.927 63.102 72.403 1.00 0.00 WWDM C ATOM 43 O LEU P 7 -10.745 62.895 71.500 1.00 0.00 WWDM O ATOM 44 N PRO P 8 -8.617 63.078 72.112 1.00 0.00 WWDM N ATOM 45 CD PRO P 8 -7.594 63.740 72.931 1.00 0.00 WWDM C ATOM 46 HD1 PRO P 8 -7.956 64.706 73.355 1.00 0.00 WWDM H ATOM 47 HD2 PRO P 8 -7.284 63.053 73.749 1.00 0.00 WWDM H ATOM 48 CA PRO P 8 -8.081 62.721 70.795 1.00 0.00 WWDM C ATOM 49 HA PRO P 8 -8.464 63.467 70.112 1.00 0.00 WWDM H ATOM 50 CB PRO P 8 -6.559 62.865 70.957 1.00 0.00 WWDM C ATOM 51 HB1 PRO P 8 -6.055 63.099 69.997 1.00 0.00 WWDM H ATOM 52 HB2 PRO P 8 -6.115 61.940 71.388 1.00 0.00 WWDM H ATOM 53 CG PRO P 8 -6.420 63.995 71.979 1.00 0.00 WWDM C ATOM 54 HG1 PRO P 8 -6.557 64.979 71.475 1.00 0.00 WWDM H ATOM 55 HG2 PRO P 8 -5.439 63.981 72.501 1.00 0.00 WWDM H ATOM 56 C PRO P 8 -8.481 61.381 70.171 1.00 0.00 WWDM C ATOM 57 O PRO P 8 -8.648 61.411 68.951 1.00 0.00 WWDM O ATOM 58 N PRO P 9 -8.640 60.211 70.798 1.00 0.00 WWDM N ATOM 59 CD PRO P 9 -8.055 59.875 72.101 1.00 0.00 WWDM C ATOM 60 HD1 PRO P 9 -6.945 59.878 72.012 1.00 0.00 WWDM H ATOM 61 HD2 PRO P 9 -8.373 60.583 72.894 1.00 0.00 WWDM H ATOM 62 CA PRO P 9 -9.106 59.017 70.089 1.00 0.00 WWDM C ATOM 63 HA PRO P 9 -8.660 58.965 69.104 1.00 0.00 WWDM H ATOM 64 CB PRO P 9 -8.656 57.851 70.989 1.00 0.00 WWDM C ATOM 65 HB1 PRO P 9 -7.642 57.525 70.658 1.00 0.00 WWDM H ATOM 66 HB2 PRO P 9 -9.348 56.982 70.942 1.00 0.00 WWDM H ATOM 67 CG PRO P 9 -8.552 58.461 72.389 1.00 0.00 WWDM C ATOM 68 HG1 PRO P 9 -7.868 57.901 73.058 1.00 0.00 WWDM H ATOM 69 HG2 PRO P 9 -9.565 58.509 72.843 1.00 0.00 WWDM H ATOM 70 C PRO P 9 -10.613 59.032 69.892 1.00 0.00 WWDM C ATOM 71 O PRO P 9 -11.137 58.142 69.225 1.00 0.00 WWDM O ATOM 72 N GLY P 10 -11.338 60.022 70.457 1.00 0.00 WWDM N ATOM 73 HN GLY P 10 -10.870 60.753 70.955 1.00 0.00 WWDM H ATOM 74 CA GLY P 10 -12.793 60.105 70.391 1.00 0.00 WWDM C ATOM 75 HA1 GLY P 10 -13.114 60.794 71.151 1.00 0.00 WWDM H ATOM 76 HA2 GLY P 10 -13.204 59.117 70.531 1.00 0.00 WWDM H ATOM 77 C GLY P 10 -13.330 60.628 69.087 1.00 0.00 WWDM C ATOM 78 O GLY P 10 -14.543 60.705 68.889 1.00 0.00 WWDM O ATOM 79 N TRP P 11 -12.428 61.005 68.159 1.00 0.00 WWDM N ATOM 80 HN TRP P 11 -11.460 60.935 68.379 1.00 0.00 WWDM H ATOM 81 CA TRP P 11 -12.720 61.452 66.809 1.00 0.00 WWDM C ATOM 82 HA TRP P 11 -13.359 62.322 66.912 1.00 0.00 WWDM H ATOM 83 CB TRP P 11 -11.429 61.912 66.063 1.00 0.00 WWDM C ATOM 84 HB1 TRP P 11 -11.726 62.399 65.107 1.00 0.00 WWDM H ATOM 85 HB2 TRP P 11 -10.948 62.700 66.687 1.00 0.00 WWDM H ATOM 86 CG TRP P 11 -10.340 60.877 65.735 1.00 0.00 WWDM C ATOM 87 CD1 TRP P 11 -10.231 59.547 66.047 1.00 0.00 WWDM C ATOM 88 HD1 TRP P 11 -10.946 58.985 66.629 1.00 0.00 WWDM H ATOM 89 NE1 TRP P 11 -9.071 59.031 65.507 1.00 0.00 WWDM N ATOM 90 HE1 TRP P 11 -8.743 58.101 65.631 1.00 0.00 WWDM H ATOM 91 CE2 TRP P 11 -8.387 60.026 64.869 1.00 0.00 WWDM C ATOM 92 CD2 TRP P 11 -9.159 61.218 64.982 1.00 0.00 WWDM C ATOM 93 CE3 TRP P 11 -8.726 62.405 64.409 1.00 0.00 WWDM C ATOM 94 HE3 TRP P 11 -9.299 63.323 64.493 1.00 0.00 WWDM H ATOM 95 CZ3 TRP P 11 -7.504 62.405 63.719 1.00 0.00 WWDM C ATOM 96 HZ3 TRP P 11 -7.146 63.321 63.270 1.00 0.00 WWDM H ATOM 97 CZ2 TRP P 11 -7.178 60.037 64.193 1.00 0.00 WWDM C ATOM 98 HZ2 TRP P 11 -6.588 59.137 64.095 1.00 0.00 WWDM H ATOM 99 CH2 TRP P 11 -6.740 61.231 63.608 1.00 0.00 WWDM C ATOM 100 HH2 TRP P 11 -5.800 61.254 63.072 1.00 0.00 WWDM H ATOM 101 C TRP P 11 -13.509 60.452 65.964 1.00 0.00 WWDM C ATOM 102 O TRP P 11 -13.428 59.234 66.136 1.00 0.00 WWDM O ATOM 103 N GLU P 12 -14.347 60.952 65.042 1.00 0.00 WWDM N ATOM 104 HN GLU P 12 -14.422 61.949 64.895 1.00 0.00 WWDM H ATOM 105 CA GLU P 12 -15.164 60.104 64.200 1.00 0.00 WWDM C ATOM 106 HA GLU P 12 -15.244 59.117 64.629 1.00 0.00 WWDM H ATOM 107 CB GLU P 12 -16.606 60.645 64.069 1.00 0.00 WWDM C ATOM 108 HB1 GLU P 12 -16.954 60.943 65.084 1.00 0.00 WWDM H ATOM 109 HB2 GLU P 12 -16.619 61.562 63.441 1.00 0.00 WWDM H ATOM 110 CG GLU P 12 -17.580 59.578 63.519 1.00 0.00 WWDM C ATOM 111 HG1 GLU P 12 -17.274 59.253 62.502 1.00 0.00 WWDM H ATOM 112 HG2 GLU P 12 -17.571 58.689 64.188 1.00 0.00 WWDM H ATOM 113 CD GLU P 12 -18.994 60.097 63.431 1.00 0.00 WWDM C ATOM 114 OE1 GLU P 12 -19.876 59.610 64.195 1.00 0.00 WWDM O ATOM 115 OE2 GLU P 12 -19.279 60.956 62.551 1.00 0.00 WWDM O ATOM 116 C GLU P 12 -14.550 59.979 62.821 1.00 0.00 WWDM C ATOM 117 O GLU P 12 -14.246 60.978 62.169 1.00 0.00 WWDM O ATOM 118 N LYS P 13 -14.352 58.744 62.335 1.00 0.00 WWDM N ATOM 119 HN LYS P 13 -14.517 57.934 62.895 1.00 0.00 WWDM H ATOM 120 CA LYS P 13 -13.959 58.514 60.957 1.00 0.00 WWDM C ATOM 121 HA LYS P 13 -14.021 59.432 60.395 1.00 0.00 WWDM H ATOM 122 CB LYS P 13 -12.529 57.953 60.845 1.00 0.00 WWDM C ATOM 123 HB1 LYS P 13 -11.847 58.624 61.410 1.00 0.00 WWDM H ATOM 124 HB2 LYS P 13 -12.488 56.959 61.337 1.00 0.00 WWDM H ATOM 125 CG LYS P 13 -11.976 57.805 59.416 1.00 0.00 WWDM C ATOM 126 HG1 LYS P 13 -11.013 57.251 59.498 1.00 0.00 WWDM H ATOM 127 HG2 LYS P 13 -12.661 57.181 58.799 1.00 0.00 WWDM H ATOM 128 CD LYS P 13 -11.725 59.149 58.710 1.00 0.00 WWDM C ATOM 129 HD1 LYS P 13 -12.697 59.679 58.605 1.00 0.00 WWDM H ATOM 130 HD2 LYS P 13 -11.071 59.789 59.341 1.00 0.00 WWDM H ATOM 131 CE LYS P 13 -11.123 59.026 57.301 1.00 0.00 WWDM C ATOM 132 HE1 LYS P 13 -11.697 58.285 56.699 1.00 0.00 WWDM H ATOM 133 HE2 LYS P 13 -11.163 60.011 56.783 1.00 0.00 WWDM H ATOM 134 NZ LYS P 13 -9.702 58.609 57.332 1.00 0.00 WWDM N ATOM 135 HZ1 LYS P 13 -9.391 58.418 56.348 1.00 0.00 WWDM H ATOM 136 HZ2 LYS P 13 -9.096 59.347 57.775 1.00 0.00 WWDM H ATOM 137 HZ3 LYS P 13 -9.565 57.727 57.886 1.00 0.00 WWDM H ATOM 138 C LYS P 13 -14.945 57.550 60.335 1.00 0.00 WWDM C ATOM 139 O LYS P 13 -15.190 56.458 60.852 1.00 0.00 WWDM O ATOM 140 N ARG P 14 -15.567 57.968 59.225 1.00 0.00 WWDM N ATOM 141 HN ARG P 14 -15.363 58.871 58.834 1.00 0.00 WWDM H ATOM 142 CA ARG P 14 -16.567 57.207 58.522 1.00 0.00 WWDM C ATOM 143 HA ARG P 14 -16.829 56.323 59.082 1.00 0.00 WWDM H ATOM 144 CB ARG P 14 -17.828 58.048 58.257 1.00 0.00 WWDM C ATOM 145 HB1 ARG P 14 -17.539 58.984 57.731 1.00 0.00 WWDM H ATOM 146 HB2 ARG P 14 -18.535 57.489 57.606 1.00 0.00 WWDM H ATOM 147 CG ARG P 14 -18.568 58.405 59.557 1.00 0.00 WWDM C ATOM 148 HG1 ARG P 14 -18.881 57.460 60.059 1.00 0.00 WWDM H ATOM 149 HG2 ARG P 14 -17.873 58.942 60.244 1.00 0.00 WWDM H ATOM 150 CD ARG P 14 -19.789 59.290 59.325 1.00 0.00 WWDM C ATOM 151 HD1 ARG P 14 -19.473 60.287 58.938 1.00 0.00 WWDM H ATOM 152 HD2 ARG P 14 -20.491 58.841 58.592 1.00 0.00 WWDM H ATOM 153 NE ARG P 14 -20.424 59.463 60.661 1.00 0.00 WWDM N ATOM 154 HE ARG P 14 -19.958 60.047 61.353 1.00 0.00 WWDM H ATOM 155 CZ ARG P 14 -21.504 58.804 61.112 1.00 0.00 WWDM C ATOM 156 NH1 ARG P 14 -21.913 59.071 62.346 1.00 0.00 WWDM N ATOM 157 HH11 ARG P 14 -22.638 58.525 62.774 1.00 0.00 WWDM H ATOM 158 HH12 ARG P 14 -21.254 59.542 62.950 1.00 0.00 WWDM H ATOM 159 NH2 ARG P 14 -22.171 57.917 60.384 1.00 0.00 WWDM N ATOM 160 HH21 ARG P 14 -23.092 57.657 60.702 1.00 0.00 WWDM H ATOM 161 HH22 ARG P 14 -21.770 57.588 59.516 1.00 0.00 WWDM H ATOM 162 C ARG P 14 -16.028 56.748 57.192 1.00 0.00 WWDM C ATOM 163 O ARG P 14 -15.164 57.380 56.588 1.00 0.00 WWDM O ATOM 164 N MET P 15 -16.565 55.631 56.698 1.00 0.00 WWDM N ATOM 165 HN MET P 15 -17.294 55.150 57.197 1.00 0.00 WWDM H ATOM 166 CA MET P 15 -16.186 55.058 55.422 1.00 0.00 WWDM C ATOM 167 HA MET P 15 -15.583 55.756 54.862 1.00 0.00 WWDM H ATOM 168 CB MET P 15 -15.396 53.739 55.579 1.00 0.00 WWDM C ATOM 169 HB1 MET P 15 -15.998 53.005 56.154 1.00 0.00 WWDM H ATOM 170 HB2 MET P 15 -15.183 53.300 54.572 1.00 0.00 WWDM H ATOM 171 CG MET P 15 -14.037 53.925 56.289 1.00 0.00 WWDM C ATOM 172 HG1 MET P 15 -14.222 54.277 57.327 1.00 0.00 WWDM H ATOM 173 HG2 MET P 15 -13.545 52.934 56.375 1.00 0.00 WWDM H ATOM 174 SD MET P 15 -12.900 55.076 55.459 1.00 0.00 WWDM S ATOM 175 CE MET P 15 -11.575 54.837 56.674 1.00 0.00 WWDM C ATOM 176 HE1 MET P 15 -11.928 55.068 57.702 1.00 0.00 WWDM H ATOM 177 HE2 MET P 15 -11.222 53.783 56.662 1.00 0.00 WWDM H ATOM 178 HE3 MET P 15 -10.705 55.490 56.446 1.00 0.00 WWDM H ATOM 179 C MET P 15 -17.439 54.847 54.601 1.00 0.00 WWDM C ATOM 180 O MET P 15 -18.560 54.940 55.109 1.00 0.00 WWDM O ATOM 181 N SER P 16 -17.275 54.615 53.290 1.00 0.00 WWDM N ATOM 182 HN SER P 16 -16.354 54.611 52.911 1.00 0.00 WWDM H ATOM 183 CA SER P 16 -18.357 54.484 52.321 1.00 0.00 WWDM C ATOM 184 HA SER P 16 -18.887 55.420 52.333 1.00 0.00 WWDM H ATOM 185 CB SER P 16 -17.838 54.288 50.871 1.00 0.00 WWDM C ATOM 186 HB1 SER P 16 -17.189 53.366 50.831 1.00 0.00 WWDM H ATOM 187 HB2 SER P 16 -18.685 54.149 50.166 1.00 0.00 WWDM H ATOM 188 OG SER P 16 -17.083 55.436 50.444 1.00 0.00 WWDM O ATOM 189 HG1 SER P 16 -16.777 55.231 49.529 1.00 0.00 WWDM H ATOM 190 C SER P 16 -19.377 53.417 52.661 1.00 0.00 WWDM C ATOM 191 O SER P 16 -19.082 52.439 53.351 1.00 0.00 WWDM O ATOM 192 N ARG P 17 -20.636 53.650 52.242 1.00 0.00 WWDM N ATOM 193 HN ARG P 17 -20.820 54.407 51.590 1.00 0.00 WWDM H ATOM 194 CA ARG P 17 -21.794 53.061 52.891 1.00 0.00 WWDM C ATOM 195 HA ARG P 17 -21.498 52.164 53.432 1.00 0.00 WWDM H ATOM 196 CB ARG P 17 -22.345 54.111 53.896 1.00 0.00 WWDM C ATOM 197 HB1 ARG P 17 -22.656 55.020 53.337 1.00 0.00 WWDM H ATOM 198 HB2 ARG P 17 -21.502 54.406 54.573 1.00 0.00 WWDM H ATOM 199 CG ARG P 17 -23.528 53.617 54.759 1.00 0.00 WWDM C ATOM 200 HG1 ARG P 17 -24.413 53.470 54.108 1.00 0.00 WWDM H ATOM 201 HG2 ARG P 17 -23.229 52.619 55.162 1.00 0.00 WWDM H ATOM 202 CD ARG P 17 -23.921 54.525 55.917 1.00 0.00 WWDM C ATOM 203 HD1 ARG P 17 -23.056 54.733 56.589 1.00 0.00 WWDM H ATOM 204 HD2 ARG P 17 -24.353 55.488 55.552 1.00 0.00 WWDM H ATOM 205 NE ARG P 17 -24.950 53.743 56.667 1.00 0.00 WWDM N ATOM 206 HE ARG P 17 -25.285 52.869 56.279 1.00 0.00 WWDM H ATOM 207 CZ ARG P 17 -25.466 54.096 57.845 1.00 0.00 WWDM C ATOM 208 NH1 ARG P 17 -26.236 53.237 58.508 1.00 0.00 WWDM N ATOM 209 HH11 ARG P 17 -26.603 53.528 59.387 1.00 0.00 WWDM H ATOM 210 HH12 ARG P 17 -26.203 52.261 58.253 1.00 0.00 WWDM H ATOM 211 NH2 ARG P 17 -25.302 55.297 58.377 1.00 0.00 WWDM N ATOM 212 HH21 ARG P 17 -25.798 55.446 59.249 1.00 0.00 WWDM H ATOM 213 HH22 ARG P 17 -24.883 56.044 57.859 1.00 0.00 WWDM H ATOM 214 C ARG P 17 -22.899 52.631 51.927 1.00 0.00 WWDM C ATOM 215 O ARG P 17 -23.792 51.869 52.306 1.00 0.00 WWDM O ATOM 216 N ASP P 18 -22.843 53.009 50.633 1.00 0.00 WWDM N ATOM 217 HN ASP P 18 -22.121 53.624 50.312 1.00 0.00 WWDM H ATOM 218 CA ASP P 18 -23.795 52.527 49.646 1.00 0.00 WWDM C ATOM 219 HA ASP P 18 -24.786 52.772 50.005 1.00 0.00 WWDM H ATOM 220 CB ASP P 18 -23.581 53.187 48.255 1.00 0.00 WWDM C ATOM 221 HB1 ASP P 18 -22.580 52.902 47.856 1.00 0.00 WWDM H ATOM 222 HB2 ASP P 18 -24.344 52.817 47.538 1.00 0.00 WWDM H ATOM 223 CG ASP P 18 -23.668 54.690 48.295 1.00 0.00 WWDM C ATOM 224 OD1 ASP P 18 -24.779 55.225 48.551 1.00 0.00 WWDM O ATOM 225 OD2 ASP P 18 -22.639 55.369 48.009 1.00 0.00 WWDM O ATOM 226 C ASP P 18 -23.727 50.999 49.458 1.00 0.00 WWDM C ATOM 227 O ASP P 18 -22.727 50.479 48.975 1.00 0.00 WWDM O ATOM 228 N GLY P 20 -24.773 50.244 49.862 1.00 0.00 WWDM N ATOM 229 HN GLY P 20 -25.577 50.706 50.236 1.00 0.00 WWDM H ATOM 230 CA GLY P 20 -24.801 48.795 49.700 1.00 0.00 WWDM C ATOM 231 HA1 GLY P 20 -24.685 48.373 50.688 1.00 0.00 WWDM H ATOM 232 HA2 GLY P 20 -24.016 48.488 49.022 1.00 0.00 WWDM H ATOM 233 C GLY P 20 -26.081 48.255 49.132 1.00 0.00 WWDM C ATOM 234 O GLY P 20 -26.202 47.046 48.944 1.00 0.00 WWDM O ATOM 235 N ARG P 21 -27.062 49.114 48.823 1.00 0.00 WWDM N ATOM 236 HN ARG P 21 -26.937 50.098 48.953 1.00 0.00 WWDM H ATOM 237 CA ARG P 21 -28.342 48.722 48.269 1.00 0.00 WWDM C ATOM 238 HA ARG P 21 -28.631 47.775 48.708 1.00 0.00 WWDM H ATOM 239 CB ARG P 21 -29.425 49.782 48.643 1.00 0.00 WWDM C ATOM 240 HB1 ARG P 21 -29.399 49.899 49.753 1.00 0.00 WWDM H ATOM 241 HB2 ARG P 21 -29.136 50.764 48.200 1.00 0.00 WWDM H ATOM 242 CG ARG P 21 -30.876 49.460 48.228 1.00 0.00 WWDM C ATOM 243 HG1 ARG P 21 -30.953 49.492 47.116 1.00 0.00 WWDM H ATOM 244 HG2 ARG P 21 -31.124 48.428 48.557 1.00 0.00 WWDM H ATOM 245 CD ARG P 21 -31.918 50.417 48.829 1.00 0.00 WWDM C ATOM 246 HD1 ARG P 21 -31.938 50.329 49.940 1.00 0.00 WWDM H ATOM 247 HD2 ARG P 21 -31.695 51.468 48.539 1.00 0.00 WWDM H ATOM 248 NE ARG P 21 -33.244 49.999 48.274 1.00 0.00 WWDM N ATOM 249 HE ARG P 21 -33.303 49.201 47.652 1.00 0.00 WWDM H ATOM 250 CZ ARG P 21 -34.375 50.703 48.402 1.00 0.00 WWDM C ATOM 251 NH1 ARG P 21 -35.451 50.321 47.715 1.00 0.00 WWDM N ATOM 252 HH11 ARG P 21 -36.194 50.989 47.592 1.00 0.00 WWDM H ATOM 253 HH12 ARG P 21 -35.384 49.543 47.086 1.00 0.00 WWDM H ATOM 254 NH2 ARG P 21 -34.465 51.784 49.170 1.00 0.00 WWDM N ATOM 255 HH21 ARG P 21 -35.383 52.092 49.429 1.00 0.00 WWDM H ATOM 256 HH22 ARG P 21 -33.687 52.014 49.775 1.00 0.00 WWDM H ATOM 257 C ARG P 21 -28.238 48.525 46.766 1.00 0.00 WWDM C ATOM 258 O ARG P 21 -27.434 49.175 46.096 1.00 0.00 WWDM O ATOM 259 N VAL P 22 -29.046 47.613 46.192 1.00 0.00 WWDM N ATOM 260 HN VAL P 22 -29.657 47.055 46.760 1.00 0.00 WWDM H ATOM 261 CA VAL P 22 -29.121 47.387 44.756 1.00 0.00 WWDM C ATOM 262 HA VAL P 22 -28.417 48.036 44.251 1.00 0.00 WWDM H ATOM 263 CB VAL P 22 -28.762 45.949 44.359 1.00 0.00 WWDM C ATOM 264 HB VAL P 22 -27.761 45.731 44.804 1.00 0.00 WWDM H ATOM 265 CG1 VAL P 22 -29.755 44.915 44.928 1.00 0.00 WWDM C ATOM 266 HG11 VAL P 22 -29.811 44.984 46.033 1.00 0.00 WWDM H ATOM 267 HG12 VAL P 22 -30.774 45.062 44.513 1.00 0.00 WWDM H ATOM 268 HG13 VAL P 22 -29.418 43.889 44.671 1.00 0.00 WWDM H ATOM 269 CG2 VAL P 22 -28.621 45.832 42.827 1.00 0.00 WWDM C ATOM 270 HG21 VAL P 22 -29.592 46.010 42.323 1.00 0.00 WWDM H ATOM 271 HG22 VAL P 22 -27.872 46.562 42.451 1.00 0.00 WWDM H ATOM 272 HG23 VAL P 22 -28.275 44.810 42.563 1.00 0.00 WWDM H ATOM 273 C VAL P 22 -30.507 47.791 44.276 1.00 0.00 WWDM C ATOM 274 O VAL P 22 -31.511 47.516 44.934 1.00 0.00 WWDM O ATOM 275 N TYR P 23 -30.601 48.500 43.133 1.00 0.00 WWDM N ATOM 276 HN TYR P 23 -29.785 48.755 42.612 1.00 0.00 WWDM H ATOM 277 CA TYR P 23 -31.856 49.022 42.642 1.00 0.00 WWDM C ATOM 278 HA TYR P 23 -32.670 48.773 43.310 1.00 0.00 WWDM H ATOM 279 CB TYR P 23 -31.807 50.562 42.470 1.00 0.00 WWDM C ATOM 280 HB1 TYR P 23 -30.876 50.851 41.934 1.00 0.00 WWDM H ATOM 281 HB2 TYR P 23 -32.678 50.931 41.870 1.00 0.00 WWDM H ATOM 282 CG TYR P 23 -31.841 51.309 43.775 1.00 0.00 WWDM C ATOM 283 CD1 TYR P 23 -30.680 51.894 44.303 1.00 0.00 WWDM C ATOM 284 HD1 TYR P 23 -29.738 51.762 43.795 1.00 0.00 WWDM H ATOM 285 CE1 TYR P 23 -30.747 52.700 45.450 1.00 0.00 WWDM C ATOM 286 HE1 TYR P 23 -29.849 53.166 45.831 1.00 0.00 WWDM H ATOM 287 CZ TYR P 23 -31.982 52.939 46.065 1.00 0.00 WWDM C ATOM 288 OH TYR P 23 -32.083 53.799 47.176 1.00 0.00 WWDM O ATOM 289 HH TYR P 23 -31.180 53.960 47.523 1.00 0.00 WWDM H ATOM 290 CD2 TYR P 23 -33.069 51.518 44.428 1.00 0.00 WWDM C ATOM 291 HD2 TYR P 23 -33.969 51.070 44.027 1.00 0.00 WWDM H ATOM 292 CE2 TYR P 23 -33.139 52.343 45.560 1.00 0.00 WWDM C ATOM 293 HE2 TYR P 23 -34.091 52.514 46.037 1.00 0.00 WWDM H ATOM 294 C TYR P 23 -32.207 48.434 41.280 1.00 0.00 WWDM C ATOM 295 O TYR P 23 -31.532 48.656 40.274 1.00 0.00 WWDM O ATOM 296 N TYR P 24 -33.315 47.685 41.222 1.00 0.00 WWDM N ATOM 297 HN TYR P 24 -33.814 47.463 42.060 1.00 0.00 WWDM H ATOM 298 CA TYR P 24 -33.938 47.260 39.978 1.00 0.00 WWDM C ATOM 299 HA TYR P 24 -33.801 48.047 39.247 1.00 0.00 WWDM H ATOM 300 CB TYR P 24 -33.347 45.952 39.379 1.00 0.00 WWDM C ATOM 301 HB1 TYR P 24 -33.938 45.621 38.497 1.00 0.00 WWDM H ATOM 302 HB2 TYR P 24 -32.314 46.159 39.023 1.00 0.00 WWDM H ATOM 303 CG TYR P 24 -33.272 44.815 40.367 1.00 0.00 WWDM C ATOM 304 CD1 TYR P 24 -34.350 43.929 40.529 1.00 0.00 WWDM C ATOM 305 HD1 TYR P 24 -35.254 44.080 39.958 1.00 0.00 WWDM H ATOM 306 CE1 TYR P 24 -34.258 42.848 41.417 1.00 0.00 WWDM C ATOM 307 HE1 TYR P 24 -35.095 42.172 41.525 1.00 0.00 WWDM H ATOM 308 CZ TYR P 24 -33.079 42.635 42.141 1.00 0.00 WWDM C ATOM 309 OH TYR P 24 -32.972 41.535 43.013 1.00 0.00 WWDM O ATOM 310 HH TYR P 24 -33.799 41.017 42.939 1.00 0.00 WWDM H ATOM 311 CD2 TYR P 24 -32.097 44.595 41.107 1.00 0.00 WWDM C ATOM 312 HD2 TYR P 24 -31.262 45.269 40.978 1.00 0.00 WWDM H ATOM 313 CE2 TYR P 24 -32.002 43.514 41.994 1.00 0.00 WWDM C ATOM 314 HE2 TYR P 24 -31.091 43.348 42.547 1.00 0.00 WWDM H ATOM 315 C TYR P 24 -35.440 47.160 40.197 1.00 0.00 WWDM C ATOM 316 O TYR P 24 -35.904 46.795 41.283 1.00 0.00 WWDM O ATOM 317 N PHE P 25 -36.235 47.548 39.185 1.00 0.00 WWDM N ATOM 318 HN PHE P 25 -35.841 47.822 38.297 1.00 0.00 WWDM H ATOM 319 CA PHE P 25 -37.668 47.720 39.340 1.00 0.00 WWDM C ATOM 320 HA PHE P 25 -37.996 47.291 40.277 1.00 0.00 WWDM H ATOM 321 CB PHE P 25 -38.067 49.217 39.294 1.00 0.00 WWDM C ATOM 322 HB1 PHE P 25 -37.651 49.700 38.386 1.00 0.00 WWDM H ATOM 323 HB2 PHE P 25 -39.169 49.338 39.293 1.00 0.00 WWDM H ATOM 324 CG PHE P 25 -37.535 49.929 40.507 1.00 0.00 WWDM C ATOM 325 CD1 PHE P 25 -36.319 50.631 40.461 1.00 0.00 WWDM C ATOM 326 HD1 PHE P 25 -35.757 50.669 39.539 1.00 0.00 WWDM H ATOM 327 CE1 PHE P 25 -35.830 51.283 41.600 1.00 0.00 WWDM C ATOM 328 HE1 PHE P 25 -34.899 51.828 41.549 1.00 0.00 WWDM H ATOM 329 CZ PHE P 25 -36.559 51.244 42.796 1.00 0.00 WWDM C ATOM 330 HZ PHE P 25 -36.190 51.756 43.674 1.00 0.00 WWDM H ATOM 331 CD2 PHE P 25 -38.254 49.891 41.714 1.00 0.00 WWDM C ATOM 332 HD2 PHE P 25 -39.190 49.354 41.760 1.00 0.00 WWDM H ATOM 333 CE2 PHE P 25 -37.772 50.548 42.852 1.00 0.00 WWDM C ATOM 334 HE2 PHE P 25 -38.337 50.519 43.772 1.00 0.00 WWDM H ATOM 335 C PHE P 25 -38.412 46.984 38.252 1.00 0.00 WWDM C ATOM 336 O PHE P 25 -37.989 46.954 37.096 1.00 0.00 WWDM O ATOM 337 N ASN P 26 -39.559 46.364 38.587 1.00 0.00 WWDM N ATOM 338 HN ASN P 26 -39.901 46.380 39.539 1.00 0.00 WWDM H ATOM 339 CA ASN P 26 -40.387 45.704 37.596 1.00 0.00 WWDM C ATOM 340 HA ASN P 26 -40.375 46.322 36.708 1.00 0.00 WWDM H ATOM 341 CB ASN P 26 -39.872 44.294 37.176 1.00 0.00 WWDM C ATOM 342 HB1 ASN P 26 -40.617 43.771 36.542 1.00 0.00 WWDM H ATOM 343 HB2 ASN P 26 -38.960 44.423 36.559 1.00 0.00 WWDM H ATOM 344 CG ASN P 26 -39.548 43.404 38.373 1.00 0.00 WWDM C ATOM 345 OD1 ASN P 26 -40.441 42.877 39.046 1.00 0.00 WWDM O ATOM 346 ND2 ASN P 26 -38.240 43.199 38.638 1.00 0.00 WWDM N ATOM 347 HD21 ASN P 26 -38.009 42.545 39.356 1.00 0.00 WWDM H ATOM 348 HD22 ASN P 26 -37.551 43.620 38.049 1.00 0.00 WWDM H ATOM 349 C ASN P 26 -41.859 45.642 37.987 1.00 0.00 WWDM C ATOM 350 O ASN P 26 -42.243 45.651 39.154 1.00 0.00 WWDM O ATOM 351 N HSD P 27 -42.720 45.599 36.962 1.00 0.00 WWDM N ATOM 352 HN HSD P 27 -42.344 45.653 36.029 1.00 0.00 WWDM H ATOM 353 CA HSD P 27 -44.153 45.456 37.110 1.00 0.00 WWDM C ATOM 354 HA HSD P 27 -44.404 45.147 38.114 1.00 0.00 WWDM H ATOM 355 CB HSD P 27 -44.848 46.799 36.771 1.00 0.00 WWDM C ATOM 356 HB1 HSD P 27 -44.370 47.593 37.390 1.00 0.00 WWDM H ATOM 357 HB2 HSD P 27 -44.665 47.073 35.705 1.00 0.00 WWDM H ATOM 358 ND1 HSD P 27 -47.296 46.147 36.369 1.00 0.00 WWDM N ATOM 359 HD1 HSD P 27 -47.131 45.404 35.715 1.00 0.00 WWDM H ATOM 360 CG HSD P 27 -46.332 46.866 37.047 1.00 0.00 WWDM C ATOM 361 CE1 HSD P 27 -48.501 46.529 36.854 1.00 0.00 WWDM C ATOM 362 HE1 HSD P 27 -49.448 46.112 36.493 1.00 0.00 WWDM H ATOM 363 NE2 HSD P 27 -48.378 47.456 37.788 1.00 0.00 WWDM N ATOM 364 CD2 HSD P 27 -47.012 47.654 37.924 1.00 0.00 WWDM C ATOM 365 HD2 HSD P 27 -46.628 48.368 38.639 1.00 0.00 WWDM H ATOM 366 C HSD P 27 -44.652 44.382 36.166 1.00 0.00 WWDM C ATOM 367 O HSD P 27 -45.601 43.667 36.485 1.00 0.00 WWDM O ATOM 368 N ILE P 28 -43.989 44.194 35.001 1.00 0.00 WWDM N ATOM 369 HN ILE P 28 -43.205 44.765 34.740 1.00 0.00 WWDM H ATOM 370 CA ILE P 28 -44.278 43.109 34.073 1.00 0.00 WWDM C ATOM 371 HA ILE P 28 -45.339 43.130 33.872 1.00 0.00 WWDM H ATOM 372 CB ILE P 28 -43.534 43.264 32.743 1.00 0.00 WWDM C ATOM 373 HB ILE P 28 -42.442 43.212 32.951 1.00 0.00 WWDM H ATOM 374 CG2 ILE P 28 -43.877 42.113 31.766 1.00 0.00 WWDM C ATOM 375 HG21 ILE P 28 -43.520 41.131 32.145 1.00 0.00 WWDM H ATOM 376 HG22 ILE P 28 -44.975 42.056 31.608 1.00 0.00 WWDM H ATOM 377 HG23 ILE P 28 -43.391 42.304 30.782 1.00 0.00 WWDM H ATOM 378 CG1 ILE P 28 -43.789 44.641 32.074 1.00 0.00 WWDM C ATOM 379 HG11 ILE P 28 -43.412 45.454 32.735 1.00 0.00 WWDM H ATOM 380 HG12 ILE P 28 -43.188 44.685 31.134 1.00 0.00 WWDM H ATOM 381 CD ILE P 28 -45.256 44.930 31.728 1.00 0.00 WWDM C ATOM 382 HD1 ILE P 28 -45.890 44.963 32.639 1.00 0.00 WWDM H ATOM 383 HD2 ILE P 28 -45.333 45.922 31.232 1.00 0.00 WWDM H ATOM 384 HD3 ILE P 28 -45.668 44.166 31.035 1.00 0.00 WWDM H ATOM 385 C ILE P 28 -43.964 41.760 34.699 1.00 0.00 WWDM C ATOM 386 O ILE P 28 -42.870 41.515 35.215 1.00 0.00 WWDM O ATOM 387 N THR P 29 -44.938 40.837 34.667 1.00 0.00 WWDM N ATOM 388 HN THR P 29 -45.816 41.058 34.248 1.00 0.00 WWDM H ATOM 389 CA THR P 29 -44.834 39.552 35.340 1.00 0.00 WWDM C ATOM 390 HA THR P 29 -43.798 39.341 35.564 1.00 0.00 WWDM H ATOM 391 CB THR P 29 -45.608 39.539 36.657 1.00 0.00 WWDM C ATOM 392 HB THR P 29 -45.287 40.444 37.228 1.00 0.00 WWDM H ATOM 393 OG1 THR P 29 -45.328 38.395 37.454 1.00 0.00 WWDM O ATOM 394 HG1 THR P 29 -45.468 38.717 38.369 1.00 0.00 WWDM H ATOM 395 CG2 THR P 29 -47.127 39.612 36.444 1.00 0.00 WWDM C ATOM 396 HG21 THR P 29 -47.408 40.500 35.838 1.00 0.00 WWDM H ATOM 397 HG22 THR P 29 -47.515 38.695 35.948 1.00 0.00 WWDM H ATOM 398 HG23 THR P 29 -47.639 39.701 37.426 1.00 0.00 WWDM H ATOM 399 C THR P 29 -45.288 38.452 34.404 1.00 0.00 WWDM C ATOM 400 O THR P 29 -45.860 38.704 33.340 1.00 0.00 WWDM O ATOM 401 N ASN P 30 -44.990 37.185 34.745 1.00 0.00 WWDM N ATOM 402 HN ASN P 30 -44.585 37.031 35.646 1.00 0.00 WWDM H ATOM 403 CA ASN P 30 -45.367 36.014 33.982 1.00 0.00 WWDM C ATOM 404 HA ASN P 30 -45.040 36.183 32.964 1.00 0.00 WWDM H ATOM 405 CB ASN P 30 -44.634 34.743 34.492 1.00 0.00 WWDM C ATOM 406 HB1 ASN P 30 -44.938 33.848 33.910 1.00 0.00 WWDM H ATOM 407 HB2 ASN P 30 -43.541 34.884 34.348 1.00 0.00 WWDM H ATOM 408 CG ASN P 30 -44.846 34.489 35.985 1.00 0.00 WWDM C ATOM 409 OD1 ASN P 30 -44.131 35.028 36.833 1.00 0.00 WWDM O ATOM 410 ND2 ASN P 30 -45.834 33.629 36.328 1.00 0.00 WWDM N ATOM 411 HD21 ASN P 30 -45.839 33.277 37.257 1.00 0.00 WWDM H ATOM 412 HD22 ASN P 30 -46.446 33.268 35.629 1.00 0.00 WWDM H ATOM 413 C ASN P 30 -46.879 35.784 33.884 1.00 0.00 WWDM C ATOM 414 O ASN P 30 -47.628 36.072 34.813 1.00 0.00 WWDM O ATOM 415 N ALA P 31 -47.356 35.240 32.746 1.00 0.00 WWDM N ATOM 416 HN ALA P 31 -46.757 35.003 31.989 1.00 0.00 WWDM H ATOM 417 CA ALA P 31 -48.760 34.929 32.558 1.00 0.00 WWDM C ATOM 418 HA ALA P 31 -49.359 35.445 33.301 1.00 0.00 WWDM H ATOM 419 CB ALA P 31 -49.223 35.380 31.161 1.00 0.00 WWDM C ATOM 420 HB1 ALA P 31 -49.078 36.477 31.050 1.00 0.00 WWDM H ATOM 421 HB2 ALA P 31 -48.643 34.873 30.360 1.00 0.00 WWDM H ATOM 422 HB3 ALA P 31 -50.303 35.169 31.013 1.00 0.00 WWDM H ATOM 423 C ALA P 31 -48.983 33.437 32.728 1.00 0.00 WWDM C ATOM 424 O ALA P 31 -48.427 32.608 32.005 1.00 0.00 WWDM O ATOM 425 N SER P 32 -49.808 33.053 33.722 1.00 0.00 WWDM N ATOM 426 HN SER P 32 -50.255 33.755 34.295 1.00 0.00 WWDM H ATOM 427 CA SER P 32 -50.111 31.663 34.054 1.00 0.00 WWDM C ATOM 428 HA SER P 32 -49.281 31.039 33.755 1.00 0.00 WWDM H ATOM 429 CB SER P 32 -50.337 31.485 35.581 1.00 0.00 WWDM C ATOM 430 HB1 SER P 32 -49.470 31.943 36.109 1.00 0.00 WWDM H ATOM 431 HB2 SER P 32 -51.241 32.048 35.896 1.00 0.00 WWDM H ATOM 432 OG SER P 32 -50.429 30.111 35.978 1.00 0.00 WWDM O ATOM 433 HG1 SER P 32 -50.413 30.139 36.958 1.00 0.00 WWDM H ATOM 434 C SER P 32 -51.345 31.216 33.292 1.00 0.00 WWDM C ATOM 435 O SER P 32 -52.462 31.657 33.567 1.00 0.00 WWDM O ATOM 436 N GLN P 33 -51.152 30.342 32.286 1.00 0.00 WWDM N ATOM 437 HN GLN P 33 -50.250 29.918 32.160 1.00 0.00 WWDM H ATOM 438 CA GLN P 33 -52.134 30.074 31.257 1.00 0.00 WWDM C ATOM 439 HA GLN P 33 -53.055 30.593 31.481 1.00 0.00 WWDM H ATOM 440 CB GLN P 33 -51.576 30.590 29.907 1.00 0.00 WWDM C ATOM 441 HB1 GLN P 33 -51.275 31.649 30.060 1.00 0.00 WWDM H ATOM 442 HB2 GLN P 33 -50.652 30.015 29.664 1.00 0.00 WWDM H ATOM 443 CG GLN P 33 -52.562 30.520 28.718 1.00 0.00 WWDM C ATOM 444 HG1 GLN P 33 -52.885 29.469 28.546 1.00 0.00 WWDM H ATOM 445 HG2 GLN P 33 -53.463 31.136 28.915 1.00 0.00 WWDM H ATOM 446 CD GLN P 33 -51.874 30.995 27.445 1.00 0.00 WWDM C ATOM 447 OE1 GLN P 33 -51.227 30.222 26.733 1.00 0.00 WWDM O ATOM 448 NE2 GLN P 33 -51.948 32.311 27.150 1.00 0.00 WWDM N ATOM 449 HE21 GLN P 33 -51.529 32.619 26.306 1.00 0.00 WWDM H ATOM 450 HE22 GLN P 33 -52.466 32.942 27.741 1.00 0.00 WWDM H ATOM 451 C GLN P 33 -52.465 28.589 31.135 1.00 0.00 WWDM C ATOM 452 O GLN P 33 -51.587 27.730 31.014 1.00 0.00 WWDM O ATOM 453 N PHE P 34 -53.774 28.261 31.148 1.00 0.00 WWDM N ATOM 454 HN PHE P 34 -54.448 28.993 31.251 1.00 0.00 WWDM H ATOM 455 CA PHE P 34 -54.302 26.923 30.965 1.00 0.00 WWDM C ATOM 456 HA PHE P 34 -53.613 26.211 31.397 1.00 0.00 WWDM H ATOM 457 CB PHE P 34 -55.680 26.865 31.681 1.00 0.00 WWDM C ATOM 458 HB1 PHE P 34 -55.540 27.179 32.738 1.00 0.00 WWDM H ATOM 459 HB2 PHE P 34 -56.393 27.576 31.206 1.00 0.00 WWDM H ATOM 460 CG PHE P 34 -56.305 25.499 31.716 1.00 0.00 WWDM C ATOM 461 CD1 PHE P 34 -55.715 24.468 32.458 1.00 0.00 WWDM C ATOM 462 HD1 PHE P 34 -54.799 24.656 32.999 1.00 0.00 WWDM H ATOM 463 CE1 PHE P 34 -56.309 23.202 32.536 1.00 0.00 WWDM C ATOM 464 HE1 PHE P 34 -55.836 22.416 33.115 1.00 0.00 WWDM H ATOM 465 CZ PHE P 34 -57.517 22.962 31.865 1.00 0.00 WWDM C ATOM 466 HZ PHE P 34 -57.978 21.987 31.923 1.00 0.00 WWDM H ATOM 467 CD2 PHE P 34 -57.512 25.240 31.039 1.00 0.00 WWDM C ATOM 468 HD2 PHE P 34 -57.967 26.019 30.452 1.00 0.00 WWDM H ATOM 469 CE2 PHE P 34 -58.116 23.979 31.112 1.00 0.00 WWDM C ATOM 470 HE2 PHE P 34 -59.033 23.786 30.569 1.00 0.00 WWDM H ATOM 471 C PHE P 34 -54.454 26.612 29.471 1.00 0.00 WWDM C ATOM 472 O PHE P 34 -54.760 27.497 28.669 1.00 0.00 WWDM O ATOM 473 N GLU P 35 -54.261 25.345 29.050 1.00 0.00 WWDM N ATOM 474 HN GLU P 35 -53.941 24.650 29.703 1.00 0.00 WWDM H ATOM 475 CA GLU P 35 -54.355 24.992 27.641 1.00 0.00 WWDM C ATOM 476 HA GLU P 35 -55.194 25.534 27.222 1.00 0.00 WWDM H ATOM 477 CB GLU P 35 -53.086 25.408 26.831 1.00 0.00 WWDM C ATOM 478 HB1 GLU P 35 -53.050 24.882 25.855 1.00 0.00 WWDM H ATOM 479 HB2 GLU P 35 -53.208 26.487 26.589 1.00 0.00 WWDM H ATOM 480 CG GLU P 35 -51.714 25.284 27.542 1.00 0.00 WWDM C ATOM 481 HG1 GLU P 35 -50.918 25.595 26.835 1.00 0.00 WWDM H ATOM 482 HG2 GLU P 35 -51.683 25.991 28.400 1.00 0.00 WWDM H ATOM 483 CD GLU P 35 -51.354 23.906 28.041 1.00 0.00 WWDM C ATOM 484 OE1 GLU P 35 -51.180 22.957 27.236 1.00 0.00 WWDM O ATOM 485 OE2 GLU P 35 -51.153 23.767 29.276 1.00 0.00 WWDM O ATOM 486 C GLU P 35 -54.707 23.529 27.357 1.00 0.00 WWDM C ATOM 487 O GLU P 35 -54.723 23.111 26.196 1.00 0.00 WWDM O ATOM 488 N ARG P 36 -55.092 22.720 28.369 1.00 0.00 WWDM N ATOM 489 HN ARG P 36 -55.084 23.044 29.311 1.00 0.00 WWDM H ATOM 490 CA ARG P 36 -55.566 21.355 28.150 1.00 0.00 WWDM C ATOM 491 HA ARG P 36 -54.744 20.831 27.681 1.00 0.00 WWDM H ATOM 492 CB ARG P 36 -55.922 20.623 29.466 1.00 0.00 WWDM C ATOM 493 HB1 ARG P 36 -56.772 21.153 29.954 1.00 0.00 WWDM H ATOM 494 HB2 ARG P 36 -56.280 19.597 29.218 1.00 0.00 WWDM H ATOM 495 CG ARG P 36 -54.784 20.467 30.486 1.00 0.00 WWDM C ATOM 496 HG1 ARG P 36 -53.892 20.028 29.989 1.00 0.00 WWDM H ATOM 497 HG2 ARG P 36 -54.505 21.467 30.894 1.00 0.00 WWDM H ATOM 498 CD ARG P 36 -55.239 19.547 31.620 1.00 0.00 WWDM C ATOM 499 HD1 ARG P 36 -56.161 19.950 32.102 1.00 0.00 WWDM H ATOM 500 HD2 ARG P 36 -55.447 18.535 31.213 1.00 0.00 WWDM H ATOM 501 NE ARG P 36 -54.156 19.452 32.634 1.00 0.00 WWDM N ATOM 502 HE ARG P 36 -53.308 19.981 32.546 1.00 0.00 WWDM H ATOM 503 CZ ARG P 36 -54.303 18.772 33.777 1.00 0.00 WWDM C ATOM 504 NH1 ARG P 36 -53.329 18.820 34.681 1.00 0.00 WWDM N ATOM 505 HH11 ARG P 36 -53.495 18.426 35.599 1.00 0.00 WWDM H ATOM 506 HH12 ARG P 36 -52.544 19.387 34.487 1.00 0.00 WWDM H ATOM 507 NH2 ARG P 36 -55.382 18.039 34.025 1.00 0.00 WWDM N ATOM 508 HH21 ARG P 36 -55.373 17.424 34.823 1.00 0.00 WWDM H ATOM 509 HH22 ARG P 36 -56.019 17.845 33.284 1.00 0.00 WWDM H ATOM 510 C ARG P 36 -56.819 21.237 27.264 1.00 0.00 WWDM C ATOM 511 O ARG P 36 -57.671 22.137 27.290 1.00 0.00 WWDM O ATOM 512 N PRO P 37 -57.036 20.166 26.501 1.00 0.00 WWDM N ATOM 513 CD PRO P 37 -55.979 19.245 26.080 1.00 0.00 WWDM C ATOM 514 HD1 PRO P 37 -55.039 19.786 25.837 1.00 0.00 WWDM H ATOM 515 HD2 PRO P 37 -55.802 18.498 26.887 1.00 0.00 WWDM H ATOM 516 CA PRO P 37 -58.289 19.905 25.792 1.00 0.00 WWDM C ATOM 517 HA PRO P 37 -58.464 20.736 25.121 1.00 0.00 WWDM H ATOM 518 CB PRO P 37 -58.039 18.584 25.049 1.00 0.00 WWDM C ATOM 519 HB1 PRO P 37 -58.602 18.528 24.095 1.00 0.00 WWDM H ATOM 520 HB2 PRO P 37 -58.314 17.710 25.685 1.00 0.00 WWDM H ATOM 521 CG PRO P 37 -56.527 18.562 24.826 1.00 0.00 WWDM C ATOM 522 HG1 PRO P 37 -56.273 19.177 23.937 1.00 0.00 WWDM H ATOM 523 HG2 PRO P 37 -56.126 17.534 24.689 1.00 0.00 WWDM H ATOM 524 C PRO P 37 -59.516 19.794 26.691 1.00 0.00 WWDM C ATOM 525 O PRO P 37 -60.611 20.174 26.264 1.00 0.00 WWDM O ATOM 526 N SER P 38 -59.366 19.264 27.919 1.00 0.00 WWDM N ATOM 527 HN SER P 38 -58.493 18.853 28.191 1.00 0.00 WWDM H ATOM 528 CA SER P 38 -60.457 19.155 28.870 1.00 0.00 WWDM C ATOM 529 HA SER P 38 -61.125 19.994 28.731 1.00 0.00 WWDM H ATOM 530 CB SER P 38 -61.243 17.826 28.705 1.00 0.00 WWDM C ATOM 531 HB1 SER P 38 -61.453 17.670 27.625 1.00 0.00 WWDM H ATOM 532 HB2 SER P 38 -60.617 16.969 29.046 1.00 0.00 WWDM H ATOM 533 OG SER P 38 -62.482 17.843 29.420 1.00 0.00 WWDM O ATOM 534 HG1 SER P 38 -63.180 18.093 28.784 1.00 0.00 WWDM H ATOM 535 C SER P 38 -59.915 19.237 30.287 1.00 0.00 WWDM C ATOM 536 O SER P 38 -58.782 18.839 30.569 1.00 0.00 WWDM O ATOM 537 C GLY P 39 -61.298 20.781 33.383 1.00 0.00 WWDM C ATOM 538 OT1 GLY P 39 -62.500 20.423 33.520 1.00 0.00 WWDM O ATOM 539 OT2 GLY P 39 -60.877 21.866 33.858 1.00 0.00 WWDM O ATOM 540 N GLY P 39 -60.712 19.782 31.228 1.00 0.00 WWDM N ATOM 541 HN GLY P 39 -61.632 20.096 31.001 1.00 0.00 WWDM H ATOM 542 CA GLY P 39 -60.317 19.888 32.622 1.00 0.00 WWDM C ATOM 543 HA1 GLY P 39 -59.341 20.349 32.673 1.00 0.00 WWDM H ATOM 544 HA2 GLY P 39 -60.345 18.903 33.065 1.00 0.00 WWDM H END cctools-4.0-source/apps/replica_exchange_protomol/ww_exteq_nowater1.psf0000640060042600000500000037362212175446362025550 0ustar btovardipPSF 6 !NTITLE REMARKS original generated structure x-plor psf file REMARKS 2 patches were applied to the molecule. REMARKS topology ../top_all22_prot.inp REMARKS segment WWDM { first NTER; last CTER; auto angles dihedrals } REMARKS defaultpatch NTER WWDM:6 REMARKS defaultpatch CTER WWDM:39 544 !NATOM 1 WWDM 6 LYS N NH3 -0.300000 14.0070 0 2 WWDM 6 LYS HT1 HC 0.330000 1.0080 0 3 WWDM 6 LYS HT2 HC 0.330000 1.0080 0 4 WWDM 6 LYS HT3 HC 0.330000 1.0080 0 5 WWDM 6 LYS CA CT1 0.210000 12.0110 0 6 WWDM 6 LYS HA HB 0.100000 1.0080 0 7 WWDM 6 LYS CB CT2 -0.180000 12.0110 0 8 WWDM 6 LYS HB1 HA 0.090000 1.0080 0 9 WWDM 6 LYS HB2 HA 0.090000 1.0080 0 10 WWDM 6 LYS CG CT2 -0.180000 12.0110 0 11 WWDM 6 LYS HG1 HA 0.090000 1.0080 0 12 WWDM 6 LYS HG2 HA 0.090000 1.0080 0 13 WWDM 6 LYS CD CT2 -0.180000 12.0110 0 14 WWDM 6 LYS HD1 HA 0.090000 1.0080 0 15 WWDM 6 LYS HD2 HA 0.090000 1.0080 0 16 WWDM 6 LYS CE CT2 0.210000 12.0110 0 17 WWDM 6 LYS HE1 HA 0.050000 1.0080 0 18 WWDM 6 LYS HE2 HA 0.050000 1.0080 0 19 WWDM 6 LYS NZ NH3 -0.300000 14.0070 0 20 WWDM 6 LYS HZ1 HC 0.330000 1.0080 0 21 WWDM 6 LYS HZ2 HC 0.330000 1.0080 0 22 WWDM 6 LYS HZ3 HC 0.330000 1.0080 0 23 WWDM 6 LYS C C 0.510000 12.0110 0 24 WWDM 6 LYS O O -0.510000 15.9990 0 25 WWDM 7 LEU N NH1 -0.470000 14.0070 0 26 WWDM 7 LEU HN H 0.310000 1.0080 0 27 WWDM 7 LEU CA CT1 0.070000 12.0110 0 28 WWDM 7 LEU HA HB 0.090000 1.0080 0 29 WWDM 7 LEU CB CT2 -0.180000 12.0110 0 30 WWDM 7 LEU HB1 HA 0.090000 1.0080 0 31 WWDM 7 LEU HB2 HA 0.090000 1.0080 0 32 WWDM 7 LEU CG CT1 -0.090000 12.0110 0 33 WWDM 7 LEU HG HA 0.090000 1.0080 0 34 WWDM 7 LEU CD1 CT3 -0.270000 12.0110 0 35 WWDM 7 LEU HD11 HA 0.090000 1.0080 0 36 WWDM 7 LEU HD12 HA 0.090000 1.0080 0 37 WWDM 7 LEU HD13 HA 0.090000 1.0080 0 38 WWDM 7 LEU CD2 CT3 -0.270000 12.0110 0 39 WWDM 7 LEU HD21 HA 0.090000 1.0080 0 40 WWDM 7 LEU HD22 HA 0.090000 1.0080 0 41 WWDM 7 LEU HD23 HA 0.090000 1.0080 0 42 WWDM 7 LEU C C 0.510000 12.0110 0 43 WWDM 7 LEU O O -0.510000 15.9990 0 44 WWDM 8 PRO N N -0.290000 14.0070 0 45 WWDM 8 PRO CD CP3 0.000000 12.0110 0 46 WWDM 8 PRO HD1 HA 0.090000 1.0080 0 47 WWDM 8 PRO HD2 HA 0.090000 1.0080 0 48 WWDM 8 PRO CA CP1 0.020000 12.0110 0 49 WWDM 8 PRO HA HB 0.090000 1.0080 0 50 WWDM 8 PRO CB CP2 -0.180000 12.0110 0 51 WWDM 8 PRO HB1 HA 0.090000 1.0080 0 52 WWDM 8 PRO HB2 HA 0.090000 1.0080 0 53 WWDM 8 PRO CG CP2 -0.180000 12.0110 0 54 WWDM 8 PRO HG1 HA 0.090000 1.0080 0 55 WWDM 8 PRO HG2 HA 0.090000 1.0080 0 56 WWDM 8 PRO C C 0.510000 12.0110 0 57 WWDM 8 PRO O O -0.510000 15.9990 0 58 WWDM 9 PRO N N -0.290000 14.0070 0 59 WWDM 9 PRO CD CP3 0.000000 12.0110 0 60 WWDM 9 PRO HD1 HA 0.090000 1.0080 0 61 WWDM 9 PRO HD2 HA 0.090000 1.0080 0 62 WWDM 9 PRO CA CP1 0.020000 12.0110 0 63 WWDM 9 PRO HA HB 0.090000 1.0080 0 64 WWDM 9 PRO CB CP2 -0.180000 12.0110 0 65 WWDM 9 PRO HB1 HA 0.090000 1.0080 0 66 WWDM 9 PRO HB2 HA 0.090000 1.0080 0 67 WWDM 9 PRO CG CP2 -0.180000 12.0110 0 68 WWDM 9 PRO HG1 HA 0.090000 1.0080 0 69 WWDM 9 PRO HG2 HA 0.090000 1.0080 0 70 WWDM 9 PRO C C 0.510000 12.0110 0 71 WWDM 9 PRO O O -0.510000 15.9990 0 72 WWDM 10 GLY N NH1 -0.470000 14.0070 0 73 WWDM 10 GLY HN H 0.310000 1.0080 0 74 WWDM 10 GLY CA CT2 -0.020000 12.0110 0 75 WWDM 10 GLY HA1 HB 0.090000 1.0080 0 76 WWDM 10 GLY HA2 HB 0.090000 1.0080 0 77 WWDM 10 GLY C C 0.510000 12.0110 0 78 WWDM 10 GLY O O -0.510000 15.9990 0 79 WWDM 11 TRP N NH1 -0.470000 14.0070 0 80 WWDM 11 TRP HN H 0.310000 1.0080 0 81 WWDM 11 TRP CA CT1 0.070000 12.0110 0 82 WWDM 11 TRP HA HB 0.090000 1.0080 0 83 WWDM 11 TRP CB CT2 -0.180000 12.0110 0 84 WWDM 11 TRP HB1 HA 0.090000 1.0080 0 85 WWDM 11 TRP HB2 HA 0.090000 1.0080 0 86 WWDM 11 TRP CG CY -0.030000 12.0110 0 87 WWDM 11 TRP CD1 CA 0.035000 12.0110 0 88 WWDM 11 TRP HD1 HP 0.115000 1.0080 0 89 WWDM 11 TRP NE1 NY -0.610000 14.0070 0 90 WWDM 11 TRP HE1 H 0.380000 1.0080 0 91 WWDM 11 TRP CE2 CPT 0.130000 12.0110 0 92 WWDM 11 TRP CD2 CPT -0.020000 12.0110 0 93 WWDM 11 TRP CE3 CA -0.115000 12.0110 0 94 WWDM 11 TRP HE3 HP 0.115000 1.0080 0 95 WWDM 11 TRP CZ3 CA -0.115000 12.0110 0 96 WWDM 11 TRP HZ3 HP 0.115000 1.0080 0 97 WWDM 11 TRP CZ2 CA -0.115000 12.0110 0 98 WWDM 11 TRP HZ2 HP 0.115000 1.0080 0 99 WWDM 11 TRP CH2 CA -0.115000 12.0110 0 100 WWDM 11 TRP HH2 HP 0.115000 1.0080 0 101 WWDM 11 TRP C C 0.510000 12.0110 0 102 WWDM 11 TRP O O -0.510000 15.9990 0 103 WWDM 12 GLU N NH1 -0.470000 14.0070 0 104 WWDM 12 GLU HN H 0.310000 1.0080 0 105 WWDM 12 GLU CA CT1 0.070000 12.0110 0 106 WWDM 12 GLU HA HB 0.090000 1.0080 0 107 WWDM 12 GLU CB CT2 -0.180000 12.0110 0 108 WWDM 12 GLU HB1 HA 0.090000 1.0080 0 109 WWDM 12 GLU HB2 HA 0.090000 1.0080 0 110 WWDM 12 GLU CG CT2 -0.280000 12.0110 0 111 WWDM 12 GLU HG1 HA 0.090000 1.0080 0 112 WWDM 12 GLU HG2 HA 0.090000 1.0080 0 113 WWDM 12 GLU CD CC 0.620000 12.0110 0 114 WWDM 12 GLU OE1 OC -0.760000 15.9990 0 115 WWDM 12 GLU OE2 OC -0.760000 15.9990 0 116 WWDM 12 GLU C C 0.510000 12.0110 0 117 WWDM 12 GLU O O -0.510000 15.9990 0 118 WWDM 13 LYS N NH1 -0.470000 14.0070 0 119 WWDM 13 LYS HN H 0.310000 1.0080 0 120 WWDM 13 LYS CA CT1 0.070000 12.0110 0 121 WWDM 13 LYS HA HB 0.090000 1.0080 0 122 WWDM 13 LYS CB CT2 -0.180000 12.0110 0 123 WWDM 13 LYS HB1 HA 0.090000 1.0080 0 124 WWDM 13 LYS HB2 HA 0.090000 1.0080 0 125 WWDM 13 LYS CG CT2 -0.180000 12.0110 0 126 WWDM 13 LYS HG1 HA 0.090000 1.0080 0 127 WWDM 13 LYS HG2 HA 0.090000 1.0080 0 128 WWDM 13 LYS CD CT2 -0.180000 12.0110 0 129 WWDM 13 LYS HD1 HA 0.090000 1.0080 0 130 WWDM 13 LYS HD2 HA 0.090000 1.0080 0 131 WWDM 13 LYS CE CT2 0.210000 12.0110 0 132 WWDM 13 LYS HE1 HA 0.050000 1.0080 0 133 WWDM 13 LYS HE2 HA 0.050000 1.0080 0 134 WWDM 13 LYS NZ NH3 -0.300000 14.0070 0 135 WWDM 13 LYS HZ1 HC 0.330000 1.0080 0 136 WWDM 13 LYS HZ2 HC 0.330000 1.0080 0 137 WWDM 13 LYS HZ3 HC 0.330000 1.0080 0 138 WWDM 13 LYS C C 0.510000 12.0110 0 139 WWDM 13 LYS O O -0.510000 15.9990 0 140 WWDM 14 ARG N NH1 -0.470000 14.0070 0 141 WWDM 14 ARG HN H 0.310000 1.0080 0 142 WWDM 14 ARG CA CT1 0.070000 12.0110 0 143 WWDM 14 ARG HA HB 0.090000 1.0080 0 144 WWDM 14 ARG CB CT2 -0.180000 12.0110 0 145 WWDM 14 ARG HB1 HA 0.090000 1.0080 0 146 WWDM 14 ARG HB2 HA 0.090000 1.0080 0 147 WWDM 14 ARG CG CT2 -0.180000 12.0110 0 148 WWDM 14 ARG HG1 HA 0.090000 1.0080 0 149 WWDM 14 ARG HG2 HA 0.090000 1.0080 0 150 WWDM 14 ARG CD CT2 0.200000 12.0110 0 151 WWDM 14 ARG HD1 HA 0.090000 1.0080 0 152 WWDM 14 ARG HD2 HA 0.090000 1.0080 0 153 WWDM 14 ARG NE NC2 -0.700000 14.0070 0 154 WWDM 14 ARG HE HC 0.440000 1.0080 0 155 WWDM 14 ARG CZ C 0.640000 12.0110 0 156 WWDM 14 ARG NH1 NC2 -0.800000 14.0070 0 157 WWDM 14 ARG HH11 HC 0.460000 1.0080 0 158 WWDM 14 ARG HH12 HC 0.460000 1.0080 0 159 WWDM 14 ARG NH2 NC2 -0.800000 14.0070 0 160 WWDM 14 ARG HH21 HC 0.460000 1.0080 0 161 WWDM 14 ARG HH22 HC 0.460000 1.0080 0 162 WWDM 14 ARG C C 0.510000 12.0110 0 163 WWDM 14 ARG O O -0.510000 15.9990 0 164 WWDM 15 MET N NH1 -0.470000 14.0070 0 165 WWDM 15 MET HN H 0.310000 1.0080 0 166 WWDM 15 MET CA CT1 0.070000 12.0110 0 167 WWDM 15 MET HA HB 0.090000 1.0080 0 168 WWDM 15 MET CB CT2 -0.180000 12.0110 0 169 WWDM 15 MET HB1 HA 0.090000 1.0080 0 170 WWDM 15 MET HB2 HA 0.090000 1.0080 0 171 WWDM 15 MET CG CT2 -0.140000 12.0110 0 172 WWDM 15 MET HG1 HA 0.090000 1.0080 0 173 WWDM 15 MET HG2 HA 0.090000 1.0080 0 174 WWDM 15 MET SD S -0.090000 32.0600 0 175 WWDM 15 MET CE CT3 -0.220000 12.0110 0 176 WWDM 15 MET HE1 HA 0.090000 1.0080 0 177 WWDM 15 MET HE2 HA 0.090000 1.0080 0 178 WWDM 15 MET HE3 HA 0.090000 1.0080 0 179 WWDM 15 MET C C 0.510000 12.0110 0 180 WWDM 15 MET O O -0.510000 15.9990 0 181 WWDM 16 SER N NH1 -0.470000 14.0070 0 182 WWDM 16 SER HN H 0.310000 1.0080 0 183 WWDM 16 SER CA CT1 0.070000 12.0110 0 184 WWDM 16 SER HA HB 0.090000 1.0080 0 185 WWDM 16 SER CB CT2 0.050000 12.0110 0 186 WWDM 16 SER HB1 HA 0.090000 1.0080 0 187 WWDM 16 SER HB2 HA 0.090000 1.0080 0 188 WWDM 16 SER OG OH1 -0.660000 15.9990 0 189 WWDM 16 SER HG1 H 0.430000 1.0080 0 190 WWDM 16 SER C C 0.510000 12.0110 0 191 WWDM 16 SER O O -0.510000 15.9990 0 192 WWDM 17 ARG N NH1 -0.470000 14.0070 0 193 WWDM 17 ARG HN H 0.310000 1.0080 0 194 WWDM 17 ARG CA CT1 0.070000 12.0110 0 195 WWDM 17 ARG HA HB 0.090000 1.0080 0 196 WWDM 17 ARG CB CT2 -0.180000 12.0110 0 197 WWDM 17 ARG HB1 HA 0.090000 1.0080 0 198 WWDM 17 ARG HB2 HA 0.090000 1.0080 0 199 WWDM 17 ARG CG CT2 -0.180000 12.0110 0 200 WWDM 17 ARG HG1 HA 0.090000 1.0080 0 201 WWDM 17 ARG HG2 HA 0.090000 1.0080 0 202 WWDM 17 ARG CD CT2 0.200000 12.0110 0 203 WWDM 17 ARG HD1 HA 0.090000 1.0080 0 204 WWDM 17 ARG HD2 HA 0.090000 1.0080 0 205 WWDM 17 ARG NE NC2 -0.700000 14.0070 0 206 WWDM 17 ARG HE HC 0.440000 1.0080 0 207 WWDM 17 ARG CZ C 0.640000 12.0110 0 208 WWDM 17 ARG NH1 NC2 -0.800000 14.0070 0 209 WWDM 17 ARG HH11 HC 0.460000 1.0080 0 210 WWDM 17 ARG HH12 HC 0.460000 1.0080 0 211 WWDM 17 ARG NH2 NC2 -0.800000 14.0070 0 212 WWDM 17 ARG HH21 HC 0.460000 1.0080 0 213 WWDM 17 ARG HH22 HC 0.460000 1.0080 0 214 WWDM 17 ARG C C 0.510000 12.0110 0 215 WWDM 17 ARG O O -0.510000 15.9990 0 216 WWDM 18 ASP N NH1 -0.470000 14.0070 0 217 WWDM 18 ASP HN H 0.310000 1.0080 0 218 WWDM 18 ASP CA CT1 0.070000 12.0110 0 219 WWDM 18 ASP HA HB 0.090000 1.0080 0 220 WWDM 18 ASP CB CT2 -0.280000 12.0110 0 221 WWDM 18 ASP HB1 HA 0.090000 1.0080 0 222 WWDM 18 ASP HB2 HA 0.090000 1.0080 0 223 WWDM 18 ASP CG CC 0.620000 12.0110 0 224 WWDM 18 ASP OD1 OC -0.760000 15.9990 0 225 WWDM 18 ASP OD2 OC -0.760000 15.9990 0 226 WWDM 18 ASP C C 0.510000 12.0110 0 227 WWDM 18 ASP O O -0.510000 15.9990 0 228 WWDM 20 GLY N NH1 -0.470000 14.0070 0 229 WWDM 20 GLY HN H 0.310000 1.0080 0 230 WWDM 20 GLY CA CT2 -0.020000 12.0110 0 231 WWDM 20 GLY HA1 HB 0.090000 1.0080 0 232 WWDM 20 GLY HA2 HB 0.090000 1.0080 0 233 WWDM 20 GLY C C 0.510000 12.0110 0 234 WWDM 20 GLY O O -0.510000 15.9990 0 235 WWDM 21 ARG N NH1 -0.470000 14.0070 0 236 WWDM 21 ARG HN H 0.310000 1.0080 0 237 WWDM 21 ARG CA CT1 0.070000 12.0110 0 238 WWDM 21 ARG HA HB 0.090000 1.0080 0 239 WWDM 21 ARG CB CT2 -0.180000 12.0110 0 240 WWDM 21 ARG HB1 HA 0.090000 1.0080 0 241 WWDM 21 ARG HB2 HA 0.090000 1.0080 0 242 WWDM 21 ARG CG CT2 -0.180000 12.0110 0 243 WWDM 21 ARG HG1 HA 0.090000 1.0080 0 244 WWDM 21 ARG HG2 HA 0.090000 1.0080 0 245 WWDM 21 ARG CD CT2 0.200000 12.0110 0 246 WWDM 21 ARG HD1 HA 0.090000 1.0080 0 247 WWDM 21 ARG HD2 HA 0.090000 1.0080 0 248 WWDM 21 ARG NE NC2 -0.700000 14.0070 0 249 WWDM 21 ARG HE HC 0.440000 1.0080 0 250 WWDM 21 ARG CZ C 0.640000 12.0110 0 251 WWDM 21 ARG NH1 NC2 -0.800000 14.0070 0 252 WWDM 21 ARG HH11 HC 0.460000 1.0080 0 253 WWDM 21 ARG HH12 HC 0.460000 1.0080 0 254 WWDM 21 ARG NH2 NC2 -0.800000 14.0070 0 255 WWDM 21 ARG HH21 HC 0.460000 1.0080 0 256 WWDM 21 ARG HH22 HC 0.460000 1.0080 0 257 WWDM 21 ARG C C 0.510000 12.0110 0 258 WWDM 21 ARG O O -0.510000 15.9990 0 259 WWDM 22 VAL N NH1 -0.470000 14.0070 0 260 WWDM 22 VAL HN H 0.310000 1.0080 0 261 WWDM 22 VAL CA CT1 0.070000 12.0110 0 262 WWDM 22 VAL HA HB 0.090000 1.0080 0 263 WWDM 22 VAL CB CT1 -0.090000 12.0110 0 264 WWDM 22 VAL HB HA 0.090000 1.0080 0 265 WWDM 22 VAL CG1 CT3 -0.270000 12.0110 0 266 WWDM 22 VAL HG11 HA 0.090000 1.0080 0 267 WWDM 22 VAL HG12 HA 0.090000 1.0080 0 268 WWDM 22 VAL HG13 HA 0.090000 1.0080 0 269 WWDM 22 VAL CG2 CT3 -0.270000 12.0110 0 270 WWDM 22 VAL HG21 HA 0.090000 1.0080 0 271 WWDM 22 VAL HG22 HA 0.090000 1.0080 0 272 WWDM 22 VAL HG23 HA 0.090000 1.0080 0 273 WWDM 22 VAL C C 0.510000 12.0110 0 274 WWDM 22 VAL O O -0.510000 15.9990 0 275 WWDM 23 TYR N NH1 -0.470000 14.0070 0 276 WWDM 23 TYR HN H 0.310000 1.0080 0 277 WWDM 23 TYR CA CT1 0.070000 12.0110 0 278 WWDM 23 TYR HA HB 0.090000 1.0080 0 279 WWDM 23 TYR CB CT2 -0.180000 12.0110 0 280 WWDM 23 TYR HB1 HA 0.090000 1.0080 0 281 WWDM 23 TYR HB2 HA 0.090000 1.0080 0 282 WWDM 23 TYR CG CA 0.000000 12.0110 0 283 WWDM 23 TYR CD1 CA -0.115000 12.0110 0 284 WWDM 23 TYR HD1 HP 0.115000 1.0080 0 285 WWDM 23 TYR CE1 CA -0.115000 12.0110 0 286 WWDM 23 TYR HE1 HP 0.115000 1.0080 0 287 WWDM 23 TYR CZ CA 0.110000 12.0110 0 288 WWDM 23 TYR OH OH1 -0.540000 15.9990 0 289 WWDM 23 TYR HH H 0.430000 1.0080 0 290 WWDM 23 TYR CD2 CA -0.115000 12.0110 0 291 WWDM 23 TYR HD2 HP 0.115000 1.0080 0 292 WWDM 23 TYR CE2 CA -0.115000 12.0110 0 293 WWDM 23 TYR HE2 HP 0.115000 1.0080 0 294 WWDM 23 TYR C C 0.510000 12.0110 0 295 WWDM 23 TYR O O -0.510000 15.9990 0 296 WWDM 24 TYR N NH1 -0.470000 14.0070 0 297 WWDM 24 TYR HN H 0.310000 1.0080 0 298 WWDM 24 TYR CA CT1 0.070000 12.0110 0 299 WWDM 24 TYR HA HB 0.090000 1.0080 0 300 WWDM 24 TYR CB CT2 -0.180000 12.0110 0 301 WWDM 24 TYR HB1 HA 0.090000 1.0080 0 302 WWDM 24 TYR HB2 HA 0.090000 1.0080 0 303 WWDM 24 TYR CG CA 0.000000 12.0110 0 304 WWDM 24 TYR CD1 CA -0.115000 12.0110 0 305 WWDM 24 TYR HD1 HP 0.115000 1.0080 0 306 WWDM 24 TYR CE1 CA -0.115000 12.0110 0 307 WWDM 24 TYR HE1 HP 0.115000 1.0080 0 308 WWDM 24 TYR CZ CA 0.110000 12.0110 0 309 WWDM 24 TYR OH OH1 -0.540000 15.9990 0 310 WWDM 24 TYR HH H 0.430000 1.0080 0 311 WWDM 24 TYR CD2 CA -0.115000 12.0110 0 312 WWDM 24 TYR HD2 HP 0.115000 1.0080 0 313 WWDM 24 TYR CE2 CA -0.115000 12.0110 0 314 WWDM 24 TYR HE2 HP 0.115000 1.0080 0 315 WWDM 24 TYR C C 0.510000 12.0110 0 316 WWDM 24 TYR O O -0.510000 15.9990 0 317 WWDM 25 PHE N NH1 -0.470000 14.0070 0 318 WWDM 25 PHE HN H 0.310000 1.0080 0 319 WWDM 25 PHE CA CT1 0.070000 12.0110 0 320 WWDM 25 PHE HA HB 0.090000 1.0080 0 321 WWDM 25 PHE CB CT2 -0.180000 12.0110 0 322 WWDM 25 PHE HB1 HA 0.090000 1.0080 0 323 WWDM 25 PHE HB2 HA 0.090000 1.0080 0 324 WWDM 25 PHE CG CA 0.000000 12.0110 0 325 WWDM 25 PHE CD1 CA -0.115000 12.0110 0 326 WWDM 25 PHE HD1 HP 0.115000 1.0080 0 327 WWDM 25 PHE CE1 CA -0.115000 12.0110 0 328 WWDM 25 PHE HE1 HP 0.115000 1.0080 0 329 WWDM 25 PHE CZ CA -0.115000 12.0110 0 330 WWDM 25 PHE HZ HP 0.115000 1.0080 0 331 WWDM 25 PHE CD2 CA -0.115000 12.0110 0 332 WWDM 25 PHE HD2 HP 0.115000 1.0080 0 333 WWDM 25 PHE CE2 CA -0.115000 12.0110 0 334 WWDM 25 PHE HE2 HP 0.115000 1.0080 0 335 WWDM 25 PHE C C 0.510000 12.0110 0 336 WWDM 25 PHE O O -0.510000 15.9990 0 337 WWDM 26 ASN N NH1 -0.470000 14.0070 0 338 WWDM 26 ASN HN H 0.310000 1.0080 0 339 WWDM 26 ASN CA CT1 0.070000 12.0110 0 340 WWDM 26 ASN HA HB 0.090000 1.0080 0 341 WWDM 26 ASN CB CT2 -0.180000 12.0110 0 342 WWDM 26 ASN HB1 HA 0.090000 1.0080 0 343 WWDM 26 ASN HB2 HA 0.090000 1.0080 0 344 WWDM 26 ASN CG CC 0.550000 12.0110 0 345 WWDM 26 ASN OD1 O -0.550000 15.9990 0 346 WWDM 26 ASN ND2 NH2 -0.620000 14.0070 0 347 WWDM 26 ASN HD21 H 0.320000 1.0080 0 348 WWDM 26 ASN HD22 H 0.300000 1.0080 0 349 WWDM 26 ASN C C 0.510000 12.0110 0 350 WWDM 26 ASN O O -0.510000 15.9990 0 351 WWDM 27 HSD N NH1 -0.470000 14.0070 0 352 WWDM 27 HSD HN H 0.310000 1.0080 0 353 WWDM 27 HSD CA CT1 0.070000 12.0110 0 354 WWDM 27 HSD HA HB 0.090000 1.0080 0 355 WWDM 27 HSD CB CT2 -0.090000 12.0110 0 356 WWDM 27 HSD HB1 HA 0.090000 1.0080 0 357 WWDM 27 HSD HB2 HA 0.090000 1.0080 0 358 WWDM 27 HSD ND1 NR1 -0.360000 14.0070 0 359 WWDM 27 HSD HD1 H 0.320000 1.0080 0 360 WWDM 27 HSD CG CPH1 -0.050000 12.0110 0 361 WWDM 27 HSD CE1 CPH2 0.250000 12.0110 0 362 WWDM 27 HSD HE1 HR1 0.130000 1.0080 0 363 WWDM 27 HSD NE2 NR2 -0.700000 14.0070 0 364 WWDM 27 HSD CD2 CPH1 0.220000 12.0110 0 365 WWDM 27 HSD HD2 HR3 0.100000 1.0080 0 366 WWDM 27 HSD C C 0.510000 12.0110 0 367 WWDM 27 HSD O O -0.510000 15.9990 0 368 WWDM 28 ILE N NH1 -0.470000 14.0070 0 369 WWDM 28 ILE HN H 0.310000 1.0080 0 370 WWDM 28 ILE CA CT1 0.070000 12.0110 0 371 WWDM 28 ILE HA HB 0.090000 1.0080 0 372 WWDM 28 ILE CB CT1 -0.090000 12.0110 0 373 WWDM 28 ILE HB HA 0.090000 1.0080 0 374 WWDM 28 ILE CG2 CT3 -0.270000 12.0110 0 375 WWDM 28 ILE HG21 HA 0.090000 1.0080 0 376 WWDM 28 ILE HG22 HA 0.090000 1.0080 0 377 WWDM 28 ILE HG23 HA 0.090000 1.0080 0 378 WWDM 28 ILE CG1 CT2 -0.180000 12.0110 0 379 WWDM 28 ILE HG11 HA 0.090000 1.0080 0 380 WWDM 28 ILE HG12 HA 0.090000 1.0080 0 381 WWDM 28 ILE CD CT3 -0.270000 12.0110 0 382 WWDM 28 ILE HD1 HA 0.090000 1.0080 0 383 WWDM 28 ILE HD2 HA 0.090000 1.0080 0 384 WWDM 28 ILE HD3 HA 0.090000 1.0080 0 385 WWDM 28 ILE C C 0.510000 12.0110 0 386 WWDM 28 ILE O O -0.510000 15.9990 0 387 WWDM 29 THR N NH1 -0.470000 14.0070 0 388 WWDM 29 THR HN H 0.310000 1.0080 0 389 WWDM 29 THR CA CT1 0.070000 12.0110 0 390 WWDM 29 THR HA HB 0.090000 1.0080 0 391 WWDM 29 THR CB CT1 0.140000 12.0110 0 392 WWDM 29 THR HB HA 0.090000 1.0080 0 393 WWDM 29 THR OG1 OH1 -0.660000 15.9990 0 394 WWDM 29 THR HG1 H 0.430000 1.0080 0 395 WWDM 29 THR CG2 CT3 -0.270000 12.0110 0 396 WWDM 29 THR HG21 HA 0.090000 1.0080 0 397 WWDM 29 THR HG22 HA 0.090000 1.0080 0 398 WWDM 29 THR HG23 HA 0.090000 1.0080 0 399 WWDM 29 THR C C 0.510000 12.0110 0 400 WWDM 29 THR O O -0.510000 15.9990 0 401 WWDM 30 ASN N NH1 -0.470000 14.0070 0 402 WWDM 30 ASN HN H 0.310000 1.0080 0 403 WWDM 30 ASN CA CT1 0.070000 12.0110 0 404 WWDM 30 ASN HA HB 0.090000 1.0080 0 405 WWDM 30 ASN CB CT2 -0.180000 12.0110 0 406 WWDM 30 ASN HB1 HA 0.090000 1.0080 0 407 WWDM 30 ASN HB2 HA 0.090000 1.0080 0 408 WWDM 30 ASN CG CC 0.550000 12.0110 0 409 WWDM 30 ASN OD1 O -0.550000 15.9990 0 410 WWDM 30 ASN ND2 NH2 -0.620000 14.0070 0 411 WWDM 30 ASN HD21 H 0.320000 1.0080 0 412 WWDM 30 ASN HD22 H 0.300000 1.0080 0 413 WWDM 30 ASN C C 0.510000 12.0110 0 414 WWDM 30 ASN O O -0.510000 15.9990 0 415 WWDM 31 ALA N NH1 -0.470000 14.0070 0 416 WWDM 31 ALA HN H 0.310000 1.0080 0 417 WWDM 31 ALA CA CT1 0.070000 12.0110 0 418 WWDM 31 ALA HA HB 0.090000 1.0080 0 419 WWDM 31 ALA CB CT3 -0.270000 12.0110 0 420 WWDM 31 ALA HB1 HA 0.090000 1.0080 0 421 WWDM 31 ALA HB2 HA 0.090000 1.0080 0 422 WWDM 31 ALA HB3 HA 0.090000 1.0080 0 423 WWDM 31 ALA C C 0.510000 12.0110 0 424 WWDM 31 ALA O O -0.510000 15.9990 0 425 WWDM 32 SER N NH1 -0.470000 14.0070 0 426 WWDM 32 SER HN H 0.310000 1.0080 0 427 WWDM 32 SER CA CT1 0.070000 12.0110 0 428 WWDM 32 SER HA HB 0.090000 1.0080 0 429 WWDM 32 SER CB CT2 0.050000 12.0110 0 430 WWDM 32 SER HB1 HA 0.090000 1.0080 0 431 WWDM 32 SER HB2 HA 0.090000 1.0080 0 432 WWDM 32 SER OG OH1 -0.660000 15.9990 0 433 WWDM 32 SER HG1 H 0.430000 1.0080 0 434 WWDM 32 SER C C 0.510000 12.0110 0 435 WWDM 32 SER O O -0.510000 15.9990 0 436 WWDM 33 GLN N NH1 -0.470000 14.0070 0 437 WWDM 33 GLN HN H 0.310000 1.0080 0 438 WWDM 33 GLN CA CT1 0.070000 12.0110 0 439 WWDM 33 GLN HA HB 0.090000 1.0080 0 440 WWDM 33 GLN CB CT2 -0.180000 12.0110 0 441 WWDM 33 GLN HB1 HA 0.090000 1.0080 0 442 WWDM 33 GLN HB2 HA 0.090000 1.0080 0 443 WWDM 33 GLN CG CT2 -0.180000 12.0110 0 444 WWDM 33 GLN HG1 HA 0.090000 1.0080 0 445 WWDM 33 GLN HG2 HA 0.090000 1.0080 0 446 WWDM 33 GLN CD CC 0.550000 12.0110 0 447 WWDM 33 GLN OE1 O -0.550000 15.9990 0 448 WWDM 33 GLN NE2 NH2 -0.620000 14.0070 0 449 WWDM 33 GLN HE21 H 0.320000 1.0080 0 450 WWDM 33 GLN HE22 H 0.300000 1.0080 0 451 WWDM 33 GLN C C 0.510000 12.0110 0 452 WWDM 33 GLN O O -0.510000 15.9990 0 453 WWDM 34 PHE N NH1 -0.470000 14.0070 0 454 WWDM 34 PHE HN H 0.310000 1.0080 0 455 WWDM 34 PHE CA CT1 0.070000 12.0110 0 456 WWDM 34 PHE HA HB 0.090000 1.0080 0 457 WWDM 34 PHE CB CT2 -0.180000 12.0110 0 458 WWDM 34 PHE HB1 HA 0.090000 1.0080 0 459 WWDM 34 PHE HB2 HA 0.090000 1.0080 0 460 WWDM 34 PHE CG CA 0.000000 12.0110 0 461 WWDM 34 PHE CD1 CA -0.115000 12.0110 0 462 WWDM 34 PHE HD1 HP 0.115000 1.0080 0 463 WWDM 34 PHE CE1 CA -0.115000 12.0110 0 464 WWDM 34 PHE HE1 HP 0.115000 1.0080 0 465 WWDM 34 PHE CZ CA -0.115000 12.0110 0 466 WWDM 34 PHE HZ HP 0.115000 1.0080 0 467 WWDM 34 PHE CD2 CA -0.115000 12.0110 0 468 WWDM 34 PHE HD2 HP 0.115000 1.0080 0 469 WWDM 34 PHE CE2 CA -0.115000 12.0110 0 470 WWDM 34 PHE HE2 HP 0.115000 1.0080 0 471 WWDM 34 PHE C C 0.510000 12.0110 0 472 WWDM 34 PHE O O -0.510000 15.9990 0 473 WWDM 35 GLU N NH1 -0.470000 14.0070 0 474 WWDM 35 GLU HN H 0.310000 1.0080 0 475 WWDM 35 GLU CA CT1 0.070000 12.0110 0 476 WWDM 35 GLU HA HB 0.090000 1.0080 0 477 WWDM 35 GLU CB CT2 -0.180000 12.0110 0 478 WWDM 35 GLU HB1 HA 0.090000 1.0080 0 479 WWDM 35 GLU HB2 HA 0.090000 1.0080 0 480 WWDM 35 GLU CG CT2 -0.280000 12.0110 0 481 WWDM 35 GLU HG1 HA 0.090000 1.0080 0 482 WWDM 35 GLU HG2 HA 0.090000 1.0080 0 483 WWDM 35 GLU CD CC 0.620000 12.0110 0 484 WWDM 35 GLU OE1 OC -0.760000 15.9990 0 485 WWDM 35 GLU OE2 OC -0.760000 15.9990 0 486 WWDM 35 GLU C C 0.510000 12.0110 0 487 WWDM 35 GLU O O -0.510000 15.9990 0 488 WWDM 36 ARG N NH1 -0.470000 14.0070 0 489 WWDM 36 ARG HN H 0.310000 1.0080 0 490 WWDM 36 ARG CA CT1 0.070000 12.0110 0 491 WWDM 36 ARG HA HB 0.090000 1.0080 0 492 WWDM 36 ARG CB CT2 -0.180000 12.0110 0 493 WWDM 36 ARG HB1 HA 0.090000 1.0080 0 494 WWDM 36 ARG HB2 HA 0.090000 1.0080 0 495 WWDM 36 ARG CG CT2 -0.180000 12.0110 0 496 WWDM 36 ARG HG1 HA 0.090000 1.0080 0 497 WWDM 36 ARG HG2 HA 0.090000 1.0080 0 498 WWDM 36 ARG CD CT2 0.200000 12.0110 0 499 WWDM 36 ARG HD1 HA 0.090000 1.0080 0 500 WWDM 36 ARG HD2 HA 0.090000 1.0080 0 501 WWDM 36 ARG NE NC2 -0.700000 14.0070 0 502 WWDM 36 ARG HE HC 0.440000 1.0080 0 503 WWDM 36 ARG CZ C 0.640000 12.0110 0 504 WWDM 36 ARG NH1 NC2 -0.800000 14.0070 0 505 WWDM 36 ARG HH11 HC 0.460000 1.0080 0 506 WWDM 36 ARG HH12 HC 0.460000 1.0080 0 507 WWDM 36 ARG NH2 NC2 -0.800000 14.0070 0 508 WWDM 36 ARG HH21 HC 0.460000 1.0080 0 509 WWDM 36 ARG HH22 HC 0.460000 1.0080 0 510 WWDM 36 ARG C C 0.510000 12.0110 0 511 WWDM 36 ARG O O -0.510000 15.9990 0 512 WWDM 37 PRO N N -0.290000 14.0070 0 513 WWDM 37 PRO CD CP3 0.000000 12.0110 0 514 WWDM 37 PRO HD1 HA 0.090000 1.0080 0 515 WWDM 37 PRO HD2 HA 0.090000 1.0080 0 516 WWDM 37 PRO CA CP1 0.020000 12.0110 0 517 WWDM 37 PRO HA HB 0.090000 1.0080 0 518 WWDM 37 PRO CB CP2 -0.180000 12.0110 0 519 WWDM 37 PRO HB1 HA 0.090000 1.0080 0 520 WWDM 37 PRO HB2 HA 0.090000 1.0080 0 521 WWDM 37 PRO CG CP2 -0.180000 12.0110 0 522 WWDM 37 PRO HG1 HA 0.090000 1.0080 0 523 WWDM 37 PRO HG2 HA 0.090000 1.0080 0 524 WWDM 37 PRO C C 0.510000 12.0110 0 525 WWDM 37 PRO O O -0.510000 15.9990 0 526 WWDM 38 SER N NH1 -0.470000 14.0070 0 527 WWDM 38 SER HN H 0.310000 1.0080 0 528 WWDM 38 SER CA CT1 0.070000 12.0110 0 529 WWDM 38 SER HA HB 0.090000 1.0080 0 530 WWDM 38 SER CB CT2 0.050000 12.0110 0 531 WWDM 38 SER HB1 HA 0.090000 1.0080 0 532 WWDM 38 SER HB2 HA 0.090000 1.0080 0 533 WWDM 38 SER OG OH1 -0.660000 15.9990 0 534 WWDM 38 SER HG1 H 0.430000 1.0080 0 535 WWDM 38 SER C C 0.510000 12.0110 0 536 WWDM 38 SER O O -0.510000 15.9990 0 537 WWDM 39 GLY C CC 0.340000 12.0110 0 538 WWDM 39 GLY OT1 OC -0.670000 15.9990 0 539 WWDM 39 GLY OT2 OC -0.670000 15.9990 0 540 WWDM 39 GLY N NH1 -0.470000 14.0070 0 541 WWDM 39 GLY HN H 0.310000 1.0080 0 542 WWDM 39 GLY CA CT2 -0.020000 12.0110 0 543 WWDM 39 GLY HA1 HB 0.090000 1.0080 0 544 WWDM 39 GLY HA2 HB 0.090000 1.0080 0 553 !NBOND: bonds 1 5 2 1 3 1 4 1 5 6 7 5 7 8 7 9 10 7 10 11 10 12 13 10 13 14 13 15 16 13 16 17 16 18 19 16 19 20 19 21 19 22 23 5 23 25 24 23 25 26 25 27 27 28 29 27 29 30 29 31 32 29 32 33 34 32 34 35 34 36 34 37 38 32 38 39 38 40 38 41 42 27 42 44 43 42 44 48 44 45 46 45 47 45 48 50 49 48 50 53 51 50 52 50 53 45 54 53 55 53 56 48 56 58 57 56 58 62 58 59 60 59 61 59 62 64 63 62 64 67 65 64 66 64 67 59 68 67 69 67 70 62 70 72 71 70 72 73 72 74 74 75 74 76 77 74 77 79 78 77 79 80 79 81 81 82 83 81 83 84 83 85 86 83 87 88 87 86 89 87 89 91 89 90 91 92 92 86 92 93 93 94 95 99 95 96 95 93 97 91 97 98 99 100 99 97 101 81 101 103 102 101 103 104 103 105 105 106 107 105 107 108 107 109 110 107 110 111 110 112 113 110 113 114 115 113 116 105 116 118 117 116 118 119 118 120 120 121 122 120 122 123 122 124 125 122 125 126 125 127 128 125 128 129 128 130 131 128 131 132 131 133 134 131 134 135 134 136 134 137 138 120 138 140 139 138 140 141 140 142 142 143 144 142 144 145 144 146 147 144 147 148 147 149 150 147 150 151 150 152 153 150 153 154 155 153 155 156 156 157 156 158 159 155 159 160 159 161 162 142 162 164 163 162 164 165 164 166 166 167 168 166 168 169 168 170 171 168 171 172 171 173 174 171 175 174 175 176 175 177 175 178 179 166 179 181 180 179 181 182 181 183 183 184 185 183 185 186 185 187 188 185 188 189 190 183 190 192 191 190 192 193 192 194 194 195 196 194 196 197 196 198 199 196 199 200 199 201 202 199 202 203 202 204 205 202 205 206 207 205 207 208 208 209 208 210 211 207 211 212 211 213 214 194 214 216 215 214 216 217 216 218 218 219 220 218 220 221 220 222 223 220 223 224 225 223 226 218 226 228 227 226 228 229 228 230 230 231 230 232 233 230 233 235 234 233 235 236 235 237 237 238 239 237 239 240 239 241 242 239 242 243 242 244 245 242 245 246 245 247 248 245 248 249 250 248 250 251 251 252 251 253 254 250 254 255 254 256 257 237 257 259 258 257 259 260 259 261 261 262 263 261 263 264 265 263 265 266 265 267 265 268 269 263 269 270 269 271 269 272 273 261 273 275 274 273 275 276 275 277 277 278 279 277 279 280 279 281 282 279 283 284 283 282 285 283 285 286 285 287 287 292 288 287 288 289 290 282 290 291 292 293 292 290 294 277 294 296 295 294 296 297 296 298 298 299 300 298 300 301 300 302 303 300 304 305 304 303 306 304 306 307 306 308 308 313 309 308 309 310 311 303 311 312 313 314 313 311 315 298 315 317 316 315 317 318 317 319 319 320 321 319 321 322 321 323 324 321 325 326 325 324 327 325 327 328 329 333 329 327 329 330 331 324 331 332 333 331 333 334 335 319 335 337 336 335 337 338 337 339 339 340 341 339 341 342 341 343 344 341 344 345 346 344 346 347 346 348 349 339 349 351 349 350 351 352 351 353 353 354 355 353 355 356 355 357 358 360 358 359 360 355 360 364 361 358 361 362 361 363 363 364 364 365 366 353 366 368 367 366 368 369 368 370 370 371 372 370 372 373 374 372 374 375 374 376 374 377 378 372 378 379 378 380 381 378 381 382 381 383 381 384 385 370 385 387 386 385 387 388 387 389 389 390 391 389 391 392 393 391 393 394 395 391 395 396 395 397 395 398 399 389 399 401 400 399 401 402 401 403 403 404 405 403 405 406 405 407 408 405 408 409 410 408 410 411 410 412 413 403 413 415 413 414 415 416 415 417 417 418 419 417 419 420 419 421 419 422 423 417 423 425 424 423 425 426 425 427 427 428 429 427 429 430 429 431 432 429 432 433 434 427 434 436 435 434 436 437 436 438 438 439 440 438 440 441 440 442 443 440 443 444 443 445 446 443 446 447 448 446 448 449 448 450 451 438 451 453 452 451 453 454 453 455 455 456 457 455 457 458 457 459 460 457 461 462 461 460 463 461 463 464 465 469 465 463 465 466 467 460 467 468 469 467 469 470 471 455 471 473 472 471 473 474 473 475 475 476 477 475 477 478 477 479 480 477 480 481 480 482 483 480 483 484 485 483 486 475 486 488 487 486 488 489 488 490 490 491 492 490 492 493 492 494 495 492 495 496 495 497 498 495 498 499 498 500 501 498 501 502 503 501 503 504 504 505 504 506 507 503 507 508 507 509 510 490 510 512 511 510 512 516 512 513 514 513 515 513 516 518 517 516 518 521 519 518 520 518 521 513 522 521 523 521 524 516 524 526 525 524 526 527 526 528 528 529 530 528 530 531 530 532 533 530 533 534 535 528 535 540 536 535 537 539 537 538 537 542 540 541 540 542 542 543 542 544 989 !NTHETA: angles 1 5 6 1 5 23 2 1 5 2 1 4 2 1 3 3 1 5 3 1 4 4 1 5 5 23 24 5 23 25 5 7 9 5 7 8 5 7 10 7 10 12 7 10 11 7 10 13 7 5 6 7 5 23 7 5 1 8 7 9 10 13 15 10 13 14 10 13 16 10 7 9 10 7 8 11 10 12 13 16 18 13 16 17 13 16 19 13 10 12 13 10 11 14 13 15 16 19 22 16 19 21 16 19 20 16 13 15 16 13 14 17 16 18 19 16 18 19 16 17 20 19 22 20 19 21 21 19 22 23 5 6 25 27 28 25 27 42 25 23 24 26 25 23 26 25 27 27 42 43 27 42 44 27 29 31 27 29 30 27 29 32 27 25 23 29 32 33 29 32 38 29 32 34 29 27 28 29 27 42 29 27 25 30 29 31 32 38 41 32 38 40 32 38 39 32 34 37 32 34 36 32 34 35 32 29 31 32 29 30 34 32 33 34 32 38 35 34 37 35 34 36 36 34 37 38 32 33 39 38 41 39 38 40 40 38 41 42 27 28 44 48 49 44 48 50 44 45 47 44 45 46 44 42 43 45 53 55 45 53 54 45 44 42 46 45 47 48 56 57 48 56 58 48 50 52 48 50 51 48 50 53 48 44 42 48 44 45 50 53 55 50 53 54 50 53 45 50 48 49 51 50 52 53 50 52 53 50 51 53 45 47 53 45 46 53 45 44 54 53 55 56 48 49 56 48 50 56 48 44 58 62 63 58 62 64 58 59 61 58 59 60 58 56 57 59 67 69 59 67 68 59 58 56 60 59 61 62 70 71 62 70 72 62 64 66 62 64 65 62 64 67 62 58 56 62 58 59 64 67 69 64 67 68 64 67 59 64 62 63 65 64 66 67 64 66 67 64 65 67 59 61 67 59 60 67 59 58 68 67 69 70 62 63 70 62 64 70 62 58 72 74 76 72 74 75 72 74 77 72 70 71 73 72 70 73 72 74 74 77 78 74 77 79 74 72 70 75 74 76 77 74 76 77 74 75 79 81 82 79 81 101 79 77 78 80 79 77 80 79 81 81 101 102 81 101 103 81 83 85 81 83 84 81 83 86 81 79 77 83 86 87 83 86 92 83 81 82 83 81 101 83 81 79 84 83 85 86 92 91 86 92 93 86 83 85 86 83 84 87 89 90 87 89 91 88 87 86 89 91 92 89 87 86 89 87 88 91 97 99 91 97 98 91 89 90 92 93 95 92 93 94 92 86 87 93 92 91 94 93 95 95 99 97 95 99 100 96 95 93 97 91 92 97 91 89 98 97 99 99 95 93 99 95 96 100 99 97 101 81 82 103 105 106 103 105 116 103 101 102 104 103 101 104 103 105 105 116 117 105 116 118 105 107 109 105 107 108 105 107 110 105 103 101 107 110 112 107 110 111 107 110 113 107 105 106 107 105 116 107 105 103 108 107 109 110 113 114 110 113 115 110 107 109 110 107 108 111 110 112 113 110 112 113 110 111 115 113 114 116 105 106 118 120 121 118 120 138 118 116 117 119 118 116 119 118 120 120 138 139 120 138 140 120 122 124 120 122 123 120 122 125 120 118 116 122 125 127 122 125 126 122 125 128 122 120 121 122 120 138 122 120 118 123 122 124 125 128 130 125 128 129 125 128 131 125 122 124 125 122 123 126 125 127 128 131 133 128 131 132 128 131 134 128 125 127 128 125 126 129 128 130 131 134 137 131 134 136 131 134 135 131 128 130 131 128 129 132 131 133 134 131 133 134 131 132 135 134 137 135 134 136 136 134 137 138 120 121 140 142 143 140 142 162 140 138 139 141 140 138 141 140 142 142 162 163 142 162 164 142 144 146 142 144 145 142 144 147 142 140 138 144 147 149 144 147 148 144 147 150 144 142 143 144 142 162 144 142 140 145 144 146 147 150 152 147 150 151 147 150 153 147 144 146 147 144 145 148 147 149 150 153 154 150 153 155 150 147 149 150 147 148 151 150 152 153 155 156 153 155 159 153 150 152 153 150 151 155 159 161 155 159 160 155 153 154 157 156 155 157 156 158 158 156 155 159 155 156 160 159 161 162 142 143 164 166 167 164 166 179 164 162 163 165 164 162 165 164 166 166 179 180 166 179 181 166 168 170 166 168 169 166 168 171 166 164 162 168 171 173 168 171 172 168 171 174 168 166 167 168 166 179 168 166 164 169 168 170 171 174 175 171 168 170 171 168 169 172 171 173 174 175 178 174 175 177 174 175 176 174 171 173 174 171 172 176 175 178 176 175 177 177 175 178 179 166 167 181 183 184 181 183 190 181 179 180 182 181 179 182 181 183 183 190 191 183 190 192 183 185 187 183 185 186 183 185 188 183 181 179 185 188 189 185 183 184 185 183 190 185 183 181 186 185 187 188 185 187 188 185 186 190 183 184 192 194 195 192 194 214 192 190 191 193 192 190 193 192 194 194 214 215 194 214 216 194 196 198 194 196 197 194 196 199 194 192 190 196 199 201 196 199 200 196 199 202 196 194 195 196 194 214 196 194 192 197 196 198 199 202 204 199 202 203 199 202 205 199 196 198 199 196 197 200 199 201 202 205 206 202 205 207 202 199 201 202 199 200 203 202 204 205 207 208 205 207 211 205 202 204 205 202 203 207 211 213 207 211 212 207 205 206 209 208 207 209 208 210 210 208 207 211 207 208 212 211 213 214 194 195 216 218 219 216 218 226 216 214 215 217 216 214 217 216 218 218 226 227 218 226 228 218 220 222 218 220 221 218 220 223 218 216 214 220 223 224 220 223 225 220 218 219 220 218 226 220 218 216 221 220 222 223 220 222 223 220 221 225 223 224 226 218 219 228 230 232 228 230 231 228 230 233 228 226 227 229 228 226 229 228 230 230 233 234 230 233 235 230 228 226 231 230 232 233 230 232 233 230 231 235 237 238 235 237 257 235 233 234 236 235 233 236 235 237 237 257 258 237 257 259 237 239 241 237 239 240 237 239 242 237 235 233 239 242 244 239 242 243 239 242 245 239 237 238 239 237 257 239 237 235 240 239 241 242 245 247 242 245 246 242 245 248 242 239 241 242 239 240 243 242 244 245 248 249 245 248 250 245 242 244 245 242 243 246 245 247 248 250 251 248 250 254 248 245 247 248 245 246 250 254 256 250 254 255 250 248 249 252 251 250 252 251 253 253 251 250 254 250 251 255 254 256 257 237 238 259 261 262 259 261 273 259 257 258 260 259 257 260 259 261 261 273 274 261 273 275 261 263 264 261 263 269 261 263 265 261 259 257 263 269 272 263 269 271 263 269 270 263 265 268 263 265 267 263 265 266 263 261 262 263 261 273 263 261 259 265 263 264 265 263 269 266 265 268 266 265 267 267 265 268 269 263 264 270 269 272 270 269 271 271 269 272 273 261 262 275 277 278 275 277 294 275 273 274 276 275 273 276 275 277 277 294 295 277 294 296 277 279 281 277 279 280 277 279 282 277 275 273 279 282 283 279 282 290 279 277 278 279 277 294 279 277 275 280 279 281 282 290 292 282 290 291 282 279 281 282 279 280 283 285 287 283 285 286 284 283 282 285 283 282 285 283 284 286 285 287 287 292 290 287 292 293 287 288 289 288 287 285 290 282 283 291 290 292 292 287 285 292 287 288 293 292 290 294 277 278 296 298 299 296 298 315 296 294 295 297 296 294 297 296 298 298 315 316 298 315 317 298 300 302 298 300 301 298 300 303 298 296 294 300 303 304 300 303 311 300 298 299 300 298 315 300 298 296 301 300 302 303 311 313 303 311 312 303 300 302 303 300 301 304 306 308 304 306 307 305 304 303 306 304 303 306 304 305 307 306 308 308 313 311 308 313 314 308 309 310 309 308 306 311 303 304 312 311 313 313 308 306 313 308 309 314 313 311 315 298 299 317 319 320 317 319 335 317 315 316 318 317 315 318 317 319 319 335 336 319 335 337 319 321 323 319 321 322 319 321 324 319 317 315 321 324 325 321 324 331 321 319 320 321 319 335 321 319 317 322 321 323 324 331 333 324 331 332 324 321 323 324 321 322 325 327 329 325 327 328 326 325 324 327 329 330 327 325 324 327 325 326 328 327 329 329 333 334 329 333 331 331 333 334 331 324 325 332 331 333 333 329 330 333 329 327 335 319 320 337 339 340 337 339 349 337 335 336 338 337 335 338 337 339 339 349 350 339 349 351 339 341 343 339 341 342 339 341 344 339 337 335 341 344 345 341 344 346 341 339 340 341 339 349 341 339 337 342 341 343 344 346 348 344 346 347 344 341 343 344 341 342 346 344 345 347 346 348 349 339 340 351 353 354 351 353 366 351 349 350 352 351 349 352 351 353 353 366 367 353 366 368 353 355 357 353 355 356 353 355 360 353 351 349 355 360 364 355 360 358 355 353 354 355 353 366 355 353 351 356 355 357 358 361 363 358 361 362 358 360 364 360 358 359 360 358 361 360 355 357 360 355 356 361 358 359 362 361 363 363 364 360 363 364 365 364 363 361 365 364 360 366 353 354 368 370 371 368 370 385 368 366 367 369 368 366 369 368 370 370 385 386 370 385 387 370 372 373 370 372 374 370 372 378 370 368 366 372 378 380 372 378 379 372 378 381 372 374 377 372 374 376 372 374 375 372 370 371 372 370 385 372 370 368 374 372 373 375 374 377 375 374 376 376 374 377 378 381 384 378 381 383 378 381 382 378 372 373 378 372 374 379 378 380 381 378 380 381 378 379 382 381 384 382 381 383 383 381 384 385 370 371 387 389 390 387 389 399 387 385 386 388 387 385 388 387 389 389 399 400 389 399 401 389 391 392 389 391 395 389 391 393 389 387 385 391 395 398 391 395 397 391 395 396 391 393 394 391 389 390 391 389 399 391 389 387 393 391 392 393 391 395 395 391 392 396 395 398 396 395 397 397 395 398 399 389 390 401 403 404 401 403 413 401 399 400 402 401 399 402 401 403 403 413 414 403 413 415 403 405 407 403 405 406 403 405 408 403 401 399 405 408 409 405 408 410 405 403 404 405 403 413 405 403 401 406 405 407 408 410 412 408 410 411 408 405 407 408 405 406 410 408 409 411 410 412 413 403 404 415 417 418 415 417 423 415 413 414 416 415 413 416 415 417 417 423 424 417 423 425 417 419 422 417 419 421 417 419 420 417 415 413 419 417 418 419 417 423 419 417 415 420 419 422 420 419 421 421 419 422 423 417 418 425 427 428 425 427 434 425 423 424 426 425 423 426 425 427 427 434 435 427 434 436 427 429 431 427 429 430 427 429 432 427 425 423 429 432 433 429 427 428 429 427 434 429 427 425 430 429 431 432 429 431 432 429 430 434 427 428 436 438 439 436 438 451 436 434 435 437 436 434 437 436 438 438 451 452 438 451 453 438 440 442 438 440 441 438 440 443 438 436 434 440 443 445 440 443 444 440 443 446 440 438 439 440 438 451 440 438 436 441 440 442 443 446 447 443 446 448 443 440 442 443 440 441 444 443 445 446 448 450 446 448 449 446 443 445 446 443 444 448 446 447 449 448 450 451 438 439 453 455 456 453 455 471 453 451 452 454 453 451 454 453 455 455 471 472 455 471 473 455 457 459 455 457 458 455 457 460 455 453 451 457 460 461 457 460 467 457 455 456 457 455 471 457 455 453 458 457 459 460 467 469 460 467 468 460 457 459 460 457 458 461 463 465 461 463 464 462 461 460 463 465 466 463 461 460 463 461 462 464 463 465 465 469 470 465 469 467 467 469 470 467 460 461 468 467 469 469 465 466 469 465 463 471 455 456 473 475 476 473 475 486 473 471 472 474 473 471 474 473 475 475 486 487 475 486 488 475 477 479 475 477 478 475 477 480 475 473 471 477 480 482 477 480 481 477 480 483 477 475 476 477 475 486 477 475 473 478 477 479 480 483 484 480 483 485 480 477 479 480 477 478 481 480 482 483 480 482 483 480 481 485 483 484 486 475 476 488 490 491 488 490 510 488 486 487 489 488 486 489 488 490 490 510 511 490 510 512 490 492 494 490 492 493 490 492 495 490 488 486 492 495 497 492 495 496 492 495 498 492 490 491 492 490 510 492 490 488 493 492 494 495 498 500 495 498 499 495 498 501 495 492 494 495 492 493 496 495 497 498 501 502 498 501 503 498 495 497 498 495 496 499 498 500 501 503 504 501 503 507 501 498 500 501 498 499 503 507 509 503 507 508 503 501 502 505 504 503 505 504 506 506 504 503 507 503 504 508 507 509 510 490 491 512 516 517 512 516 518 512 513 515 512 513 514 512 510 511 513 521 523 513 521 522 513 512 510 514 513 515 516 524 525 516 524 526 516 518 520 516 518 519 516 518 521 516 512 510 516 512 513 518 521 523 518 521 522 518 521 513 518 516 517 519 518 520 521 518 520 521 518 519 521 513 515 521 513 514 521 513 512 522 521 523 524 516 517 524 516 518 524 516 512 526 528 529 526 528 535 526 524 525 527 526 524 527 526 528 528 535 536 528 535 540 528 530 532 528 530 531 528 530 533 528 526 524 530 533 534 530 528 529 530 528 535 530 528 526 531 530 532 533 530 532 533 530 531 535 528 529 537 542 544 537 542 543 538 537 542 539 537 542 539 537 538 540 542 544 540 542 543 540 542 537 540 535 536 541 540 535 541 540 542 542 540 535 543 542 544 1460 !NPHI: dihedrals 1 5 7 10 1 5 7 8 1 5 7 9 1 5 23 25 1 5 23 24 2 1 5 7 2 1 5 23 2 1 5 6 3 1 5 7 3 1 5 23 3 1 5 6 4 1 5 7 4 1 5 23 4 1 5 6 5 23 25 26 5 23 25 27 5 7 10 13 5 7 10 11 5 7 10 12 6 5 7 10 6 5 7 8 6 5 7 9 6 5 23 25 6 5 23 24 7 10 13 16 7 10 13 14 7 10 13 15 7 5 23 25 7 5 23 24 8 7 5 23 8 7 10 13 8 7 10 11 8 7 10 12 9 7 5 23 9 7 10 13 9 7 10 11 9 7 10 12 10 13 16 19 10 13 16 17 10 13 16 18 10 7 5 23 11 10 13 16 11 10 13 14 11 10 13 15 12 10 13 16 12 10 13 14 12 10 13 15 13 16 19 20 13 16 19 21 13 16 19 22 14 13 16 19 14 13 16 17 14 13 16 18 15 13 16 19 15 13 16 17 15 13 16 18 17 16 19 20 17 16 19 21 17 16 19 22 18 16 19 20 18 16 19 21 18 16 19 22 23 25 27 29 23 25 27 42 23 25 27 28 24 23 25 26 24 23 25 27 25 27 29 32 25 27 29 30 25 27 29 31 25 27 42 44 25 27 42 43 26 25 27 29 26 25 27 42 26 25 27 28 27 42 44 48 27 42 44 45 27 29 32 34 27 29 32 38 27 29 32 33 28 27 29 32 28 27 29 30 28 27 29 31 28 27 42 44 28 27 42 43 29 32 34 35 29 32 34 36 29 32 34 37 29 32 38 39 29 32 38 40 29 32 38 41 29 27 42 44 29 27 42 43 30 29 27 42 30 29 32 34 30 29 32 38 30 29 32 33 31 29 27 42 31 29 32 34 31 29 32 38 31 29 32 33 32 29 27 42 33 32 34 35 33 32 34 36 33 32 34 37 33 32 38 39 33 32 38 40 33 32 38 41 34 32 38 39 34 32 38 40 34 32 38 41 35 34 32 38 36 34 32 38 37 34 32 38 42 44 48 56 42 44 48 50 42 44 48 49 42 44 45 53 42 44 45 46 42 44 45 47 43 42 44 48 43 42 44 45 44 48 56 58 44 48 56 57 44 48 50 53 44 48 50 51 44 48 50 52 44 45 53 50 44 45 53 54 44 45 53 55 45 53 50 48 45 53 50 51 45 53 50 52 45 44 48 56 45 44 48 50 45 44 48 49 46 45 53 50 46 45 53 54 46 45 53 55 46 45 44 48 47 45 53 50 47 45 53 54 47 45 53 55 47 45 44 48 48 56 58 62 48 56 58 59 48 50 53 54 48 50 53 55 48 44 45 53 49 48 56 58 49 48 56 57 49 48 50 53 49 48 50 51 49 48 50 52 50 48 56 58 50 48 56 57 51 50 48 56 51 50 53 54 51 50 53 55 52 50 48 56 52 50 53 54 52 50 53 55 53 50 48 56 56 58 62 70 56 58 62 64 56 58 62 63 56 58 59 67 56 58 59 60 56 58 59 61 57 56 58 62 57 56 58 59 58 62 70 72 58 62 70 71 58 62 64 67 58 62 64 65 58 62 64 66 58 59 67 64 58 59 67 68 58 59 67 69 59 67 64 62 59 67 64 65 59 67 64 66 59 58 62 70 59 58 62 64 59 58 62 63 60 59 67 64 60 59 67 68 60 59 67 69 60 59 58 62 61 59 67 64 61 59 67 68 61 59 67 69 61 59 58 62 62 70 72 73 62 70 72 74 62 64 67 68 62 64 67 69 62 58 59 67 63 62 70 72 63 62 70 71 63 62 64 67 63 62 64 65 63 62 64 66 64 62 70 72 64 62 70 71 65 64 62 70 65 64 67 68 65 64 67 69 66 64 62 70 66 64 67 68 66 64 67 69 67 64 62 70 70 72 74 77 70 72 74 75 70 72 74 76 71 70 72 73 71 70 72 74 72 74 77 79 72 74 77 78 73 72 74 77 73 72 74 75 73 72 74 76 74 77 79 80 74 77 79 81 75 74 77 79 75 74 77 78 76 74 77 79 76 74 77 78 77 79 81 83 77 79 81 101 77 79 81 82 78 77 79 80 78 77 79 81 79 81 83 86 79 81 83 84 79 81 83 85 79 81 101 103 79 81 101 102 80 79 81 83 80 79 81 101 80 79 81 82 81 101 103 104 81 101 103 105 81 83 86 92 81 83 86 87 82 81 83 86 82 81 83 84 82 81 83 85 82 81 101 103 82 81 101 102 83 86 92 93 83 86 92 91 83 86 87 89 83 86 87 88 83 81 101 103 83 81 101 102 84 83 81 101 84 83 86 92 84 83 86 87 85 83 81 101 85 83 86 92 85 83 86 87 86 92 93 94 86 92 93 95 86 92 91 97 86 92 91 89 86 87 89 91 86 87 89 90 86 83 81 101 87 89 91 97 87 89 91 92 87 86 92 93 87 86 92 91 88 87 89 91 88 87 89 90 88 87 86 92 89 91 97 98 89 91 97 99 89 91 92 93 89 87 86 92 90 89 91 97 90 89 91 92 91 97 99 95 91 97 99 100 91 92 93 94 91 92 93 95 92 93 95 99 92 93 95 96 92 91 97 98 92 91 97 99 93 95 99 100 93 95 99 97 93 92 91 97 94 93 95 99 94 93 95 96 95 99 97 98 96 95 99 100 96 95 99 97 98 97 99 100 101 103 105 107 101 103 105 116 101 103 105 106 102 101 103 104 102 101 103 105 103 105 107 110 103 105 107 108 103 105 107 109 103 105 116 118 103 105 116 117 104 103 105 107 104 103 105 116 104 103 105 106 105 116 118 119 105 116 118 120 105 107 110 113 105 107 110 111 105 107 110 112 106 105 107 110 106 105 107 108 106 105 107 109 106 105 116 118 106 105 116 117 107 110 113 115 107 110 113 114 107 105 116 118 107 105 116 117 108 107 105 116 108 107 110 113 108 107 110 111 108 107 110 112 109 107 105 116 109 107 110 113 109 107 110 111 109 107 110 112 110 107 105 116 111 110 113 115 111 110 113 114 112 110 113 115 112 110 113 114 116 118 120 122 116 118 120 138 116 118 120 121 117 116 118 119 117 116 118 120 118 120 122 125 118 120 122 123 118 120 122 124 118 120 138 140 118 120 138 139 119 118 120 122 119 118 120 138 119 118 120 121 120 138 140 141 120 138 140 142 120 122 125 128 120 122 125 126 120 122 125 127 121 120 122 125 121 120 122 123 121 120 122 124 121 120 138 140 121 120 138 139 122 125 128 131 122 125 128 129 122 125 128 130 122 120 138 140 122 120 138 139 123 122 120 138 123 122 125 128 123 122 125 126 123 122 125 127 124 122 120 138 124 122 125 128 124 122 125 126 124 122 125 127 125 128 131 134 125 128 131 132 125 128 131 133 125 122 120 138 126 125 128 131 126 125 128 129 126 125 128 130 127 125 128 131 127 125 128 129 127 125 128 130 128 131 134 135 128 131 134 136 128 131 134 137 129 128 131 134 129 128 131 132 129 128 131 133 130 128 131 134 130 128 131 132 130 128 131 133 132 131 134 135 132 131 134 136 132 131 134 137 133 131 134 135 133 131 134 136 133 131 134 137 138 140 142 144 138 140 142 162 138 140 142 143 139 138 140 141 139 138 140 142 140 142 144 147 140 142 144 145 140 142 144 146 140 142 162 164 140 142 162 163 141 140 142 144 141 140 142 162 141 140 142 143 142 162 164 165 142 162 164 166 142 144 147 150 142 144 147 148 142 144 147 149 143 142 144 147 143 142 144 145 143 142 144 146 143 142 162 164 143 142 162 163 144 147 150 153 144 147 150 151 144 147 150 152 144 142 162 164 144 142 162 163 145 144 142 162 145 144 147 150 145 144 147 148 145 144 147 149 146 144 142 162 146 144 147 150 146 144 147 148 146 144 147 149 147 150 153 155 147 150 153 154 147 144 142 162 148 147 150 153 148 147 150 151 148 147 150 152 149 147 150 153 149 147 150 151 149 147 150 152 150 153 155 159 150 153 155 156 151 150 153 155 151 150 153 154 152 150 153 155 152 150 153 154 153 155 159 160 153 155 159 161 153 155 156 157 153 155 156 158 154 153 155 159 154 153 155 156 156 155 159 160 156 155 159 161 157 156 155 159 158 156 155 159 162 164 166 168 162 164 166 179 162 164 166 167 163 162 164 165 163 162 164 166 164 166 168 171 164 166 168 169 164 166 168 170 164 166 179 181 164 166 179 180 165 164 166 168 165 164 166 179 165 164 166 167 166 179 181 182 166 179 181 183 166 168 171 174 166 168 171 172 166 168 171 173 167 166 168 171 167 166 168 169 167 166 168 170 167 166 179 181 167 166 179 180 168 171 174 175 168 166 179 181 168 166 179 180 169 168 166 179 169 168 171 174 169 168 171 172 169 168 171 173 170 168 166 179 170 168 171 174 170 168 171 172 170 168 171 173 171 174 175 176 171 174 175 177 171 174 175 178 171 168 166 179 172 171 174 175 173 171 174 175 179 181 183 185 179 181 183 190 179 181 183 184 180 179 181 182 180 179 181 183 181 183 185 188 181 183 185 186 181 183 185 187 181 183 190 192 181 183 190 191 182 181 183 185 182 181 183 190 182 181 183 184 183 190 192 193 183 190 192 194 183 185 188 189 184 183 185 188 184 183 185 186 184 183 185 187 184 183 190 192 184 183 190 191 185 183 190 192 185 183 190 191 186 185 183 190 186 185 188 189 187 185 183 190 187 185 188 189 188 185 183 190 190 192 194 196 190 192 194 214 190 192 194 195 191 190 192 193 191 190 192 194 192 194 196 199 192 194 196 197 192 194 196 198 192 194 214 216 192 194 214 215 193 192 194 196 193 192 194 214 193 192 194 195 194 214 216 217 194 214 216 218 194 196 199 202 194 196 199 200 194 196 199 201 195 194 196 199 195 194 196 197 195 194 196 198 195 194 214 216 195 194 214 215 196 199 202 205 196 199 202 203 196 199 202 204 196 194 214 216 196 194 214 215 197 196 194 214 197 196 199 202 197 196 199 200 197 196 199 201 198 196 194 214 198 196 199 202 198 196 199 200 198 196 199 201 199 202 205 207 199 202 205 206 199 196 194 214 200 199 202 205 200 199 202 203 200 199 202 204 201 199 202 205 201 199 202 203 201 199 202 204 202 205 207 211 202 205 207 208 203 202 205 207 203 202 205 206 204 202 205 207 204 202 205 206 205 207 211 212 205 207 211 213 205 207 208 209 205 207 208 210 206 205 207 211 206 205 207 208 208 207 211 212 208 207 211 213 209 208 207 211 210 208 207 211 214 216 218 220 214 216 218 226 214 216 218 219 215 214 216 217 215 214 216 218 216 218 220 223 216 218 220 221 216 218 220 222 216 218 226 228 216 218 226 227 217 216 218 220 217 216 218 226 217 216 218 219 218 226 228 229 218 226 228 230 218 220 223 225 218 220 223 224 219 218 220 223 219 218 220 221 219 218 220 222 219 218 226 228 219 218 226 227 220 218 226 228 220 218 226 227 221 220 218 226 221 220 223 225 221 220 223 224 222 220 218 226 222 220 223 225 222 220 223 224 223 220 218 226 226 228 230 233 226 228 230 231 226 228 230 232 227 226 228 229 227 226 228 230 228 230 233 235 228 230 233 234 229 228 230 233 229 228 230 231 229 228 230 232 230 233 235 236 230 233 235 237 231 230 233 235 231 230 233 234 232 230 233 235 232 230 233 234 233 235 237 239 233 235 237 257 233 235 237 238 234 233 235 236 234 233 235 237 235 237 239 242 235 237 239 240 235 237 239 241 235 237 257 259 235 237 257 258 236 235 237 239 236 235 237 257 236 235 237 238 237 257 259 260 237 257 259 261 237 239 242 245 237 239 242 243 237 239 242 244 238 237 239 242 238 237 239 240 238 237 239 241 238 237 257 259 238 237 257 258 239 242 245 248 239 242 245 246 239 242 245 247 239 237 257 259 239 237 257 258 240 239 237 257 240 239 242 245 240 239 242 243 240 239 242 244 241 239 237 257 241 239 242 245 241 239 242 243 241 239 242 244 242 245 248 250 242 245 248 249 242 239 237 257 243 242 245 248 243 242 245 246 243 242 245 247 244 242 245 248 244 242 245 246 244 242 245 247 245 248 250 254 245 248 250 251 246 245 248 250 246 245 248 249 247 245 248 250 247 245 248 249 248 250 254 255 248 250 254 256 248 250 251 252 248 250 251 253 249 248 250 254 249 248 250 251 251 250 254 255 251 250 254 256 252 251 250 254 253 251 250 254 257 259 261 263 257 259 261 273 257 259 261 262 258 257 259 260 258 257 259 261 259 261 263 265 259 261 263 269 259 261 263 264 259 261 273 275 259 261 273 274 260 259 261 263 260 259 261 273 260 259 261 262 261 273 275 276 261 273 275 277 261 263 265 266 261 263 265 267 261 263 265 268 261 263 269 270 261 263 269 271 261 263 269 272 262 261 263 265 262 261 263 269 262 261 263 264 262 261 273 275 262 261 273 274 263 261 273 275 263 261 273 274 264 263 261 273 264 263 265 266 264 263 265 267 264 263 265 268 264 263 269 270 264 263 269 271 264 263 269 272 265 263 261 273 265 263 269 270 265 263 269 271 265 263 269 272 266 265 263 269 267 265 263 269 268 265 263 269 269 263 261 273 273 275 277 279 273 275 277 294 273 275 277 278 274 273 275 276 274 273 275 277 275 277 279 282 275 277 279 280 275 277 279 281 275 277 294 296 275 277 294 295 276 275 277 279 276 275 277 294 276 275 277 278 277 294 296 297 277 294 296 298 277 279 282 290 277 279 282 283 278 277 279 282 278 277 279 280 278 277 279 281 278 277 294 296 278 277 294 295 279 282 290 291 279 282 290 292 279 282 283 285 279 282 283 284 279 277 294 296 279 277 294 295 280 279 277 294 280 279 282 290 280 279 282 283 281 279 277 294 281 279 282 290 281 279 282 283 282 290 292 287 282 290 292 293 282 283 285 286 282 283 285 287 282 279 277 294 283 285 287 292 283 285 287 288 283 282 290 291 283 282 290 292 284 283 285 286 284 283 285 287 284 283 282 290 285 287 292 293 285 287 292 290 285 287 288 289 285 283 282 290 286 285 287 292 286 285 287 288 287 292 290 291 288 287 292 293 288 287 292 290 289 288 287 292 291 290 292 293 294 296 298 300 294 296 298 315 294 296 298 299 295 294 296 297 295 294 296 298 296 298 300 303 296 298 300 301 296 298 300 302 296 298 315 317 296 298 315 316 297 296 298 300 297 296 298 315 297 296 298 299 298 315 317 318 298 315 317 319 298 300 303 311 298 300 303 304 299 298 300 303 299 298 300 301 299 298 300 302 299 298 315 317 299 298 315 316 300 303 311 312 300 303 311 313 300 303 304 306 300 303 304 305 300 298 315 317 300 298 315 316 301 300 298 315 301 300 303 311 301 300 303 304 302 300 298 315 302 300 303 311 302 300 303 304 303 311 313 308 303 311 313 314 303 304 306 307 303 304 306 308 303 300 298 315 304 306 308 313 304 306 308 309 304 303 311 312 304 303 311 313 305 304 306 307 305 304 306 308 305 304 303 311 306 308 313 314 306 308 313 311 306 308 309 310 306 304 303 311 307 306 308 313 307 306 308 309 308 313 311 312 309 308 313 314 309 308 313 311 310 309 308 313 312 311 313 314 315 317 319 321 315 317 319 335 315 317 319 320 316 315 317 318 316 315 317 319 317 319 321 324 317 319 321 322 317 319 321 323 317 319 335 337 317 319 335 336 318 317 319 321 318 317 319 335 318 317 319 320 319 335 337 338 319 335 337 339 319 321 324 331 319 321 324 325 320 319 321 324 320 319 321 322 320 319 321 323 320 319 335 337 320 319 335 336 321 324 331 332 321 324 331 333 321 324 325 327 321 324 325 326 321 319 335 337 321 319 335 336 322 321 319 335 322 321 324 331 322 321 324 325 323 321 319 335 323 321 324 331 323 321 324 325 324 331 333 329 324 331 333 334 324 325 327 328 324 325 327 329 324 321 319 335 325 327 329 333 325 327 329 330 325 324 331 332 325 324 331 333 326 325 327 328 326 325 327 329 326 325 324 331 327 329 333 331 327 329 333 334 327 325 324 331 328 327 329 333 328 327 329 330 329 333 331 332 330 329 333 331 330 329 333 334 332 331 333 334 335 337 339 341 335 337 339 349 335 337 339 340 336 335 337 338 336 335 337 339 337 339 341 344 337 339 341 342 337 339 341 343 337 339 349 351 337 339 349 350 338 337 339 341 338 337 339 349 338 337 339 340 339 349 351 352 339 349 351 353 339 341 344 346 339 341 344 345 340 339 341 344 340 339 341 342 340 339 341 343 340 339 349 351 340 339 349 350 341 344 346 347 341 344 346 348 341 339 349 351 341 339 349 350 342 341 339 349 342 341 344 346 342 341 344 345 343 341 339 349 343 341 344 346 343 341 344 345 344 341 339 349 345 344 346 347 345 344 346 348 349 351 353 355 349 351 353 366 349 351 353 354 350 349 351 352 350 349 351 353 351 353 355 360 351 353 355 356 351 353 355 357 351 353 366 368 351 353 366 367 352 351 353 355 352 351 353 366 352 351 353 354 353 366 368 369 353 366 368 370 353 355 360 358 353 355 360 364 354 353 355 360 354 353 355 356 354 353 355 357 354 353 366 368 354 353 366 367 355 360 358 361 355 360 358 359 355 360 364 363 355 360 364 365 355 353 366 368 355 353 366 367 356 355 353 366 356 355 360 358 356 355 360 364 357 355 353 366 357 355 360 358 357 355 360 364 358 361 363 364 358 360 364 363 358 360 364 365 359 358 360 364 359 358 361 362 359 358 361 363 360 364 363 361 360 358 361 362 360 358 361 363 360 355 353 366 361 363 364 365 361 358 360 364 362 361 363 364 366 368 370 372 366 368 370 385 366 368 370 371 367 366 368 369 367 366 368 370 368 370 372 378 368 370 372 374 368 370 372 373 368 370 385 387 368 370 385 386 369 368 370 372 369 368 370 385 369 368 370 371 370 385 387 388 370 385 387 389 370 372 378 381 370 372 378 379 370 372 378 380 370 372 374 375 370 372 374 376 370 372 374 377 371 370 372 378 371 370 372 374 371 370 372 373 371 370 385 387 371 370 385 386 372 378 381 382 372 378 381 383 372 378 381 384 372 370 385 387 372 370 385 386 373 372 370 385 373 372 378 381 373 372 378 379 373 372 378 380 373 372 374 375 373 372 374 376 373 372 374 377 374 372 370 385 374 372 378 381 374 372 378 379 374 372 378 380 375 374 372 378 376 374 372 378 377 374 372 378 378 372 370 385 379 378 381 382 379 378 381 383 379 378 381 384 380 378 381 382 380 378 381 383 380 378 381 384 385 387 389 391 385 387 389 399 385 387 389 390 386 385 387 388 386 385 387 389 387 389 391 393 387 389 391 395 387 389 391 392 387 389 399 401 387 389 399 400 388 387 389 391 388 387 389 399 388 387 389 390 389 399 401 402 389 399 401 403 389 391 393 394 389 391 395 396 389 391 395 397 389 391 395 398 390 389 391 393 390 389 391 395 390 389 391 392 390 389 399 401 390 389 399 400 391 389 399 401 391 389 399 400 392 391 389 399 392 391 393 394 392 391 395 396 392 391 395 397 392 391 395 398 393 391 389 399 393 391 395 396 393 391 395 397 393 391 395 398 394 393 391 395 395 391 389 399 399 401 403 405 399 401 403 413 399 401 403 404 400 399 401 402 400 399 401 403 401 403 405 408 401 403 405 406 401 403 405 407 401 403 413 415 401 403 413 414 402 401 403 405 402 401 403 413 402 401 403 404 403 413 415 416 403 413 415 417 403 405 408 410 403 405 408 409 404 403 405 408 404 403 405 406 404 403 405 407 404 403 413 415 404 403 413 414 405 408 410 411 405 408 410 412 405 403 413 415 405 403 413 414 406 405 403 413 406 405 408 410 406 405 408 409 407 405 403 413 407 405 408 410 407 405 408 409 408 405 403 413 409 408 410 411 409 408 410 412 413 415 417 419 413 415 417 423 413 415 417 418 414 413 415 416 414 413 415 417 415 417 419 420 415 417 419 421 415 417 419 422 415 417 423 425 415 417 423 424 416 415 417 419 416 415 417 423 416 415 417 418 417 423 425 426 417 423 425 427 418 417 419 420 418 417 419 421 418 417 419 422 418 417 423 425 418 417 423 424 419 417 423 425 419 417 423 424 420 419 417 423 421 419 417 423 422 419 417 423 423 425 427 429 423 425 427 434 423 425 427 428 424 423 425 426 424 423 425 427 425 427 429 432 425 427 429 430 425 427 429 431 425 427 434 436 425 427 434 435 426 425 427 429 426 425 427 434 426 425 427 428 427 434 436 437 427 434 436 438 427 429 432 433 428 427 429 432 428 427 429 430 428 427 429 431 428 427 434 436 428 427 434 435 429 427 434 436 429 427 434 435 430 429 427 434 430 429 432 433 431 429 427 434 431 429 432 433 432 429 427 434 434 436 438 440 434 436 438 451 434 436 438 439 435 434 436 437 435 434 436 438 436 438 440 443 436 438 440 441 436 438 440 442 436 438 451 453 436 438 451 452 437 436 438 440 437 436 438 451 437 436 438 439 438 451 453 454 438 451 453 455 438 440 443 446 438 440 443 444 438 440 443 445 439 438 440 443 439 438 440 441 439 438 440 442 439 438 451 453 439 438 451 452 440 443 446 448 440 443 446 447 440 438 451 453 440 438 451 452 441 440 438 451 441 440 443 446 441 440 443 444 441 440 443 445 442 440 438 451 442 440 443 446 442 440 443 444 442 440 443 445 443 446 448 449 443 446 448 450 443 440 438 451 444 443 446 448 444 443 446 447 445 443 446 448 445 443 446 447 447 446 448 449 447 446 448 450 451 453 455 457 451 453 455 471 451 453 455 456 452 451 453 454 452 451 453 455 453 455 457 460 453 455 457 458 453 455 457 459 453 455 471 473 453 455 471 472 454 453 455 457 454 453 455 471 454 453 455 456 455 471 473 474 455 471 473 475 455 457 460 467 455 457 460 461 456 455 457 460 456 455 457 458 456 455 457 459 456 455 471 473 456 455 471 472 457 460 467 468 457 460 467 469 457 460 461 463 457 460 461 462 457 455 471 473 457 455 471 472 458 457 455 471 458 457 460 467 458 457 460 461 459 457 455 471 459 457 460 467 459 457 460 461 460 467 469 465 460 467 469 470 460 461 463 464 460 461 463 465 460 457 455 471 461 463 465 469 461 463 465 466 461 460 467 468 461 460 467 469 462 461 463 464 462 461 463 465 462 461 460 467 463 465 469 467 463 465 469 470 463 461 460 467 464 463 465 469 464 463 465 466 465 469 467 468 466 465 469 467 466 465 469 470 468 467 469 470 471 473 475 477 471 473 475 486 471 473 475 476 472 471 473 474 472 471 473 475 473 475 477 480 473 475 477 478 473 475 477 479 473 475 486 488 473 475 486 487 474 473 475 477 474 473 475 486 474 473 475 476 475 486 488 489 475 486 488 490 475 477 480 483 475 477 480 481 475 477 480 482 476 475 477 480 476 475 477 478 476 475 477 479 476 475 486 488 476 475 486 487 477 480 483 485 477 480 483 484 477 475 486 488 477 475 486 487 478 477 475 486 478 477 480 483 478 477 480 481 478 477 480 482 479 477 475 486 479 477 480 483 479 477 480 481 479 477 480 482 480 477 475 486 481 480 483 485 481 480 483 484 482 480 483 485 482 480 483 484 486 488 490 492 486 488 490 510 486 488 490 491 487 486 488 489 487 486 488 490 488 490 492 495 488 490 492 493 488 490 492 494 488 490 510 512 488 490 510 511 489 488 490 492 489 488 490 510 489 488 490 491 490 510 512 516 490 510 512 513 490 492 495 498 490 492 495 496 490 492 495 497 491 490 492 495 491 490 492 493 491 490 492 494 491 490 510 512 491 490 510 511 492 495 498 501 492 495 498 499 492 495 498 500 492 490 510 512 492 490 510 511 493 492 490 510 493 492 495 498 493 492 495 496 493 492 495 497 494 492 490 510 494 492 495 498 494 492 495 496 494 492 495 497 495 498 501 503 495 498 501 502 495 492 490 510 496 495 498 501 496 495 498 499 496 495 498 500 497 495 498 501 497 495 498 499 497 495 498 500 498 501 503 507 498 501 503 504 499 498 501 503 499 498 501 502 500 498 501 503 500 498 501 502 501 503 507 508 501 503 507 509 501 503 504 505 501 503 504 506 502 501 503 507 502 501 503 504 504 503 507 508 504 503 507 509 505 504 503 507 506 504 503 507 510 512 516 524 510 512 516 518 510 512 516 517 510 512 513 521 510 512 513 514 510 512 513 515 511 510 512 516 511 510 512 513 512 516 524 526 512 516 524 525 512 516 518 521 512 516 518 519 512 516 518 520 512 513 521 518 512 513 521 522 512 513 521 523 513 521 518 516 513 521 518 519 513 521 518 520 513 512 516 524 513 512 516 518 513 512 516 517 514 513 521 518 514 513 521 522 514 513 521 523 514 513 512 516 515 513 521 518 515 513 521 522 515 513 521 523 515 513 512 516 516 524 526 527 516 524 526 528 516 518 521 522 516 518 521 523 516 512 513 521 517 516 524 526 517 516 524 525 517 516 518 521 517 516 518 519 517 516 518 520 518 516 524 526 518 516 524 525 519 518 516 524 519 518 521 522 519 518 521 523 520 518 516 524 520 518 521 522 520 518 521 523 521 518 516 524 524 526 528 530 524 526 528 535 524 526 528 529 525 524 526 527 525 524 526 528 526 528 530 533 526 528 530 531 526 528 530 532 526 528 535 540 526 528 535 536 527 526 528 530 527 526 528 535 527 526 528 529 528 535 540 541 528 535 540 542 528 530 533 534 529 528 530 533 529 528 530 531 529 528 530 532 529 528 535 540 529 528 535 536 530 528 535 540 530 528 535 536 531 530 528 535 531 530 533 534 532 530 528 535 532 530 533 534 533 530 528 535 535 540 542 537 535 540 542 543 535 540 542 544 536 535 540 541 536 535 540 542 537 542 540 541 538 537 542 540 538 537 542 543 538 537 542 544 539 537 542 540 539 537 542 543 539 537 542 544 541 540 542 543 541 540 542 544 90 !NIMPHI: impropers 23 5 25 24 25 23 27 26 42 27 44 43 44 42 48 45 56 48 58 57 58 56 62 59 70 62 72 71 72 70 74 73 77 74 79 78 79 77 81 80 101 81 103 102 103 101 105 104 113 110 115 114 116 105 118 117 118 116 120 119 138 120 140 139 140 138 142 141 155 156 159 153 162 142 164 163 164 162 166 165 179 166 181 180 181 179 183 182 190 183 192 191 192 190 194 193 207 208 211 205 214 194 216 215 216 214 218 217 223 220 225 224 226 218 228 227 228 226 230 229 233 230 235 234 235 233 237 236 250 251 254 248 257 237 259 258 259 257 261 260 273 261 275 274 275 273 277 276 294 277 296 295 296 294 298 297 315 298 317 316 317 315 319 318 335 319 337 336 337 335 339 338 344 346 341 345 344 341 346 345 346 344 347 348 346 344 348 347 349 339 351 350 351 349 353 352 358 360 361 359 358 361 360 359 361 358 363 362 361 363 358 362 364 360 363 365 364 363 360 365 366 353 368 367 368 366 370 369 385 370 387 386 387 385 389 388 399 389 401 400 401 399 403 402 408 410 405 409 408 405 410 409 410 408 411 412 410 408 412 411 413 403 415 414 415 413 417 416 423 417 425 424 425 423 427 426 434 427 436 435 436 434 438 437 446 448 443 447 446 443 448 447 448 446 449 450 448 446 450 449 451 438 453 452 453 451 455 454 471 455 473 472 473 471 475 474 483 480 485 484 486 475 488 487 488 486 490 489 503 504 507 501 510 490 512 511 512 510 516 513 524 516 526 525 526 524 528 527 535 528 540 536 537 542 539 538 540 535 542 541 0 !NDON: donors 0 !NACC: acceptors 0 !NNB 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 !NGRP 0 0 0 cctools-4.0-source/apps/sweeper/0000751060042600000500000000000012175446362015574 5ustar btovardipcctools-4.0-source/apps/sweeper/README0000640060042600000500000000462712175446362016465 0ustar btovardipDEPENDENCIES: - CCTools http://nd.edu/~ccl/software/download.shtml - MySQL for Python http://sourceforge.net/projects/mysql-python/ - MyWorkQueue http://developer.cse.nd.edu/gf/project/myworkqueue/ - Connector/C++ http://dev.mysql.com/downloads/connector/cpp/ - A MySQL database http://www.mysql.com/downloads/ INSTALLATION: - Download and install the current unstable version of cctools http://nd.edu/~ccl/software/files/cctools-current-source.tar.gz - Sweeper.py will be in the source files in cctools/apps/sweeper - Download and install MySQL for Python http://sourceforge.net/projects/mysql-python/ - $PYTHONPATH needs to have a path to MySQL for Python - For easy installation, navigate to cctools/lib/python2.6/site-packages and run the command “easy_install -d . MySQL-python†- Download and build MyWorkQueue http://developer.cse.nd.edu/gf/project/myworkqueue/ - svn checkout http://developer.cse.nd.edu/svn/myworkqueue - Download and install Connector/C++ http://dev.mysql.com/downloads/connector/cpp/ - Ensure that MyWorkQueue’s ./build links to the correct location of Connector/C++ - Modify the constants in the beginning MyWorkQueue to correspond with your setup - To build, run ./build - Create a database with the command ./ -v -mysql_host -mysql_schema -user -p -create USAGE: - Sweeper has verbose enabled by default. To turn off verbose mode, define your variable as sweeper.Sweeper(0) - Below is a simple code which outputs 20, 40, 60, 80 to a file named out: #!/usr/bin/python import sweeper x = sweeper.Sweeper() x.addprog("echo") x.addsweep(xrange(20,100,20)) x.addparameter('> out') x.addoutput("out") x.sqldbsubmit('host', 'user', 'schemaname', 'password') - If your program needs to run in a specific environment, use setenv(‘pathtoenv’) to specify an environment. (the environment must contain a script env.sh that sets up the environment) - If you want to tag the parameters that were run and add them to the database, use addtuple(‘flag’, ‘sweep’, ‘tag’) to specify what parameter was run, the values, and the tag describing it. - If you have commands stored in the database, run MyWorkQueue with the command "mywq -v -hostname -port -name -local -remote -mysql_host -mysql_schema -user -p" cctools-4.0-source/apps/sweeper/sweeper.py0000640060042600000500000004552212175446362017630 0ustar btovardip# -*- coding: utf-8 -*- # Copyright (C) 2012- The University of Notre Dame # This software is distributed under the GNU General Public License. # See the file COPYING for details. # # This program provides a simple api to sweep though a range of parameters # and store the output in progname/param/ # from work_queue import * import itertools, sys, os, re, hashlib, mmap, _mysql MAX_FILES_IN_DIR = 10000 # not sure what the max is for AFS, but in testing mkdir fails at 31000+ class Sweeper: """Provides a simple api for a program to sweep through a range of parameters. Usage: import sweeper x = sweeper.Sweeper()""" def __init__(self, verbose=1): self.vb = verbose # turn on/off verbose mode self.port = WORK_QUEUE_RANDOM_PORT # random, default is 9123 self.progname = "" # the program to sweep with self.envpath = "" # path to a environment set up script self.paramvalues = [] # list of arguments e.g. -l -o 27 self.command = [] # list of the full command to be run self.sweeps = [] # list of variables to sweep over self.inputlist = [] # list of input files self.outputlist = [] # list of output files self.keys = [] # list of keys self.env = '' # the environment def addprog(self, progname): """The program (sans parameters) to sweep with. Usage: x.addprog("echo") @param progname The base program that will be run.""" self.command.append(progname) # remove the file extension so we can create a nice directory self.progname, sep, tail = progname.partition('.') if self.vb: print 'added program = %s' % (progname) def setenv(self, pathtoenv): """Set the path to a env script to set up an environment for the command to run in. Usage: x.setenv("env.sh") @param pathtoenv The path to a script to run first.""" self.envpath = os.path.abspath(pathtoenv) if self.vb: print 'added environment script = %s' % (self.envpath) def setenvdir(self, pathtoenvdir, caching=2): """Specify a directory to be submitted that contains an environment for the worker to run in, a script will still have to set the env up. Usage: x.setenvdir('myenvdir') x.setenv('env.sh') # set ups env on worker using myenvdir @param pathtoenvdir The path to the directory. @param caching Set caching to on or off 2 == on 1 == off.""" self.env = os.path.abspath(pathtoenvdir) r = [] r.append(self.env) r.append(caching) r.append(self._checksum(pathtoenvdir)) self.inputlist.append(r) if self.vb: print 'added environment directory = %s caching = %s' % (self.env, caching) def addtuple(self, flag, iterlist, key=''): """Add a flag/sweep pair to the command. This has the same functionality as addparameter() and addsweep() used together. Usage: x.addtuple("-n", xrange(1,10,2), 'lagtime') @param flag The flag to be added to the command. @param iterlist An interable list object that contains the values to sweep over. @param key A key to tag these commands with in a MyWorkQueue database.""" self.command.append(str(flag)) self.command.append('%s') self.paramvalues.append('%s') self.sweeps.append(iterlist) if self.vb: print 'added tuple = %s sweep = %s' % (flag, iterlist) self.keys.append(key) if key is not '': if self.vb: print 'added key = %s' % (key) def addparameter(self, param): """Add a parameter to the list of parameters(arguments). Usage: x.addparameter("-n") x.addsweep(xrange(1,10,2)) x.addparameter("> out") @param param The argument to be added.""" self.command.append(str(param)) if self.vb: print 'added parameter = %s' % (param) def addinput(self, input, caching=2): """Add a file (or directory) to the input list. Usage: x.addinput("infile") @param input The file or directory to be included as input. @param caching Set caching to on or off 2 == on 1 == off.""" r = [] r.append(input) r.append(caching) r.append(self._checksum(input)) self.inputlist.append(r) if self.vb: print 'added input = %s caching = %s' % (input, caching) def addoutput(self, output, caching=1): """Add a file (or directory) to the output list. Output will be placed in progname/parameters/ Usage: a.addoutput("outfile") @param output The file to be recieved back from the worker as output. @param caching Set caching to on or off 2 == on 1 == off.""" r = [] r.append(output) r.append(caching) self.outputlist.append(r) if self.vb: print 'added output = %s caching = %s' % (output, caching) def addsweep(self, iterlist, key=''): """Add a sweep to the command. Usage: x.addsweep(xrange(1,10,2)) @param iterlist An iterable object that contains the values to sweep over. @param key A key to tag these commands with in a MyWorkQueue database.""" self.command.append("%s") self.paramvalues.append("%s") self.sweeps.append(iterlist) if self.vb: print 'added sweep = %s' % (iterlist) self.keys.append(key) if key is not '': if self.vb: print 'added key = %s' % (key) def addmetadata(self, key, value, dbconn): """Add a metadata key value pair to the database. Usage: x.addmetadata('lagtime','30',dbconn) @param key A key to tag a command with in a MyWorkQueue database. @param value A value to be paired with the key. @param dbconn A _mysql database connection object.""" dbconn.query("""INSERT INTO metadata VALUES (meta_id, \'%s\', \'%s\')""" % (key, value)) def associatemetadata(self, cid, mid, dbconn): """Associate a command_id with a meta_id (key value pair). Usage: x.associatemetadata('4232','1234',dbconn) @param cid A command_id. @param mid A meta_id. @param dbconn A _mysql database connection object.""" dbconn.query("""INSERT INTO cmdmeta VALUES (%d, %d)""" % (cid, mid)) def sweep(self, interpreter='bash'): """Sweep over the command. @param interpreter The interpreter to run the script with.""" try: self.q = WorkQueue(self.port) except: print "Work Queue init failed!" sys.exit(1) print "listening on port %d..." % self.q.port regex = re.compile('[:/" ()<>|?*]|(\\\)') filenum = 0 # count how many files are created in the dir dirnum = 0 # used to identify a output dir for sweeps of greater than the max number of files in a dir for item in itertools.product(*self.sweeps): commdir = '_'.join(self.command) % (item) # we want to replace illegal file characters with _ commdir = regex.sub('_', commdir) filenum += 1 if filenum >= MAX_FILES_IN_DIR: filenum = 0 dirnum += 1 os.system("mkdir -p %s-sweep%d/%s" % (self.progname, dirnum, commdir)) if self.vb: print 'created directory = %s-sweep%d/%s' % (self.progname, dirnum, commdir) # create the commad command = ' '.join(self.command) % (item) if self.vb: print 'created command = %s' % (command) if (self.envpath): # if a env script was specified try: env = open(self.envpath).read() except: print 'error: could not open', self.envpath print 'exiting' sys.exit(1) else: env = "" # combine an env script and the command into one script = """%(env)s%(command)s\n""" % {'env': env, 'command': command} fo = open('%s-sweep%d/%s/%s-script' % (self.progname, dirnum, commdir, commdir), 'w') fo.write(script) fo.close if self.vb: print 'created script = %s-sweep%d/%s/%s-script' % (self.progname, dirnum, commdir, commdir) taskcommand = '%s script.sh' % (interpreter) # run with bash if self.vb: print 'created taskcommand = %s' % (taskcommand) t = Task(taskcommand) t.specify_buffer(script, 'script.sh') for input in self.inputlist: if input[1] == 2: # 2 means caching should be true # the input is usually the same for all the commands t.specify_file(os.path.abspath(input[0]), input[0], WORK_QUEUE_INPUT, cache=True) else: t.specify_file(os.path.abspath(input[0]), input[0], WORK_QUEUE_INPUT, cache=False) for output in self.outputlist: # we want the output on the remote machine to go to progname-sweep/params/ on the local machine if output[1] == 2: # 2 means caching should be true t.specify_file("%s-sweep/%s/%s" % (self.progname, commdir, output[0]), output[0], WORK_QUEUE_OUTPUT, cache=True) else: t.specify_file("%s-sweep/%s/%s" % (self.progname, commdir, output[0]), output[0], WORK_QUEUE_OUTPUT, cache=False) taskid = self.q.submit(t) print "submitted task (id# %d): %s" % (taskid, t.command) print "waiting for tasks to complete..." while not self.q.empty(): t = self.q.wait(5) if t: print "task (id# %d) complete %s (return code %d)" % (t.id, t.command, t.return_status) print "all tasks complete!" print 'output and a copy of the script run by each worker located in %s-sweep' % (self.progname) def sqldbsubmit(self, host, user, dbname, pw, interpreter='bash'): """Submit the commands to a MyWorkQueue MySQL database Usage: x.sqldbsubmit('cvrl-sql.crc.nd.edu', 'ccl', 'ccltest', 'secret/mysql.pwd') @param host The MySQL host. @param user The MySQL user. @param dbname The name of the db @param pwfile A file containing the pw for the mysql server. @param interpreter The interpreter to run the script""" # create the db object db = _mysql.connect(host=host, user=user, db=dbname, passwd=pw) if self.vb: print 'connected to mysql server = %s user = %s using database = %s' % (host, user, dbname) # if the tables metadata or cmdmeta do not exist, create them db.query("""CREATE TABLE IF NOT EXISTS %s.metadata (meta_id int(11) auto_increment NOT NULL, label varchar(256) default NULL, value varchar(256) default NULL, PRIMARY KEY (meta_id)) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;""" % dbname) if self.vb: print 'created metadata table in %s' % (dbname) db.query("""CREATE TABLE IF NOT EXISTS %s.cmdmeta (command_id int(11) NOT NULL, meta_id int(11) NOT NULL) ENGINE=MyISAM DEFAULT CHARSET=utf8;""" % dbname) if self.vb: print 'created cmdmeta table in %s' % (dbname) # we want to replace all illegal file characters with _ regex = re.compile('[:/" ()<>|?*]|(\\\)') filenum = 0 # used to identify a output dir for sweeps of greater than MAX_FILES_IN_DIR number of files in a dir dirnum = 0 # identifies the output dir for item in itertools.product(*self.sweeps): commdir = '_'.join(self.command) % (item) # replace illegal characters with _ commdir = regex.sub('_', commdir) filenum += 1 if filenum >= MAX_FILES_IN_DIR: filenum = 0 dirnum += 1 os.system("mkdir -p %s-sweep%d/%s" % (self.progname, dirnum, commdir)) if self.vb: print 'created directory = %s-sweep%d/%s' % (self.progname, dirnum, commdir) command = ' '.join(self.command) % (item) # create the command if self.vb: print 'created command = %s' % (command) outputdir = '%s-sweep%d/%s/' % (self.progname, dirnum, commdir) # this is the location of the script on the master localpath = os.path.abspath('%s-sweep%d/%s/%s-script' % (self.progname, dirnum, commdir, commdir)) # location of the script on the worker remotepath = '%s-script' % (commdir) dbcommand = '%s ./' % (interpreter)+remotepath if self._checkdup(dbcommand, db): # if the command and it's input is identical continue if (self.envpath): # if a env script was specified try: env = open(self.envpath).read() except: print 'error: could not open', self.envpath print 'exiting' sys.exit(1) else: env = "" # combine the env script and the command into one script = """%(env)s%(command)s\n""" % {'env': env, 'command': command} fo = open(localpath, 'w') fo.write(script) fo.close() if self.vb: print 'created script = %s-sweep%d/%s/%s-script' % (self.progname, dirnum, commdir, commdir) #INSERT INTO commands VALUES (command_id, username, personal_id, name, command, status, stdout) #INSERT INTO files VALUES (fileid, command_id, local_path, remote_path, type, flags, checksum) # add the command to the table db.query("""INSERT INTO %s.commands VALUES (command_id, \'%s\', personal_id, name, \'%s\', 2, stdout, \'%s\')""" % (dbname, user, dbcommand, self.env)) for value,key in itertools.izip(item,self.keys): if key is not '': self.addmetadata(key,value,db) db.query("""INSERT INTO cmdmeta VALUES ((SELECT MAX(command_id) FROM commands LIMIT 1), (SELECT MAX(meta_id) from metadata LIMIT 1))""") # add script as input so it is sent to the worker - no caching # get the checksum of the input script (localpath) db.query("""INSERT INTO %s.files VALUES (fileid, command_id, \'%s\', \'%s\', 1, 1, \'%s\')""" % (dbname, localpath, remotepath, self._checksum(localpath))) # add the input files to the myworkqueue db for input in self.inputlist: db.query("""INSERT INTO %s.files VALUES (fileid, command_id, \'%s\', \'%s\', 1, %s, \'%s\')""" % (dbname, os.path.abspath(input[0]), input[0], input[1], input[2])) # add the output files to the myworkqueue db for output in self.outputlist: db.query("""INSERT INTO %s.files VALUES (fileid, command_id, \'%s\', \'%s\', 2, %s, checksum)""" % (dbname, os.path.abspath(outputdir+output[0]), output[0], output[1])) # each command in the commands table has a unique command_id, this needs to be associated with the correct input/output files db.query("""UPDATE %s.files SET files.command_id=(SELECT MAX(command_id) FROM %s.commands WHERE command=\'%s\' LIMIT 1) WHERE files.command_id=0""" % (dbname, dbname, dbcommand)) def _checksum(self, filename): """Get the sha1 checksum of a file or directory. @param filename The path to a file or directory to hash. @return The sha1 hash.""" #try: # f = open(localpath) # # this is faster but doesn't seem to work in ND afs space # map = mmap.mmap(f.fileno(), 0, flags=mmap.MAP_PRIVATE, prot=mmap.PROT_READ) # return hashlib.sha1(map).hexdigest() #except: # slightly slower but always works #print filename if os.path.isdir(filename) == True: # it a dir, we have to hash slighly differently SHAhash = hashlib.sha1() if not os.path.exists(filename): return -1 try: for root, dirs, files, in os.walk(filename): for names in files: filepath = os.path.join(root, names) try: f1 = open(filepath, 'rb') except: f1.close() continue while 1: buf = f1.read(4096) if not buf : break SHAhash.update(hashlib.sha1(buf).hexdigest()) f1.close() except: import traceback traceback.print_exc() return -2 return SHAhash.hexdigest() else: return hashlib.sha1(open(filename, 'rb').read()).hexdigest() def _checkdup(self, dbcommand, dbconn): """Check for a duplicate command and inputfiles. @param dbcommand A command to check, ex. 'bash ./echo_5__out'. @param dbconn A _mysql database connection object. @return 1 Indicates that the files and input are identical. @return 0 Indicates that the files or command has been changed.""" dbconn.query("""SELECT command_id FROM commands WHERE command='%s'""" % (dbcommand)) r = dbconn.store_result() cid = -1 # we want the command_id to be -1 if we can't find a duplicate # fetch_row returns a tuple, we only need the cid for tuple in r.fetch_row(): for i in tuple: # if we found a duplicate cid = i # if we did not find a duplicate if cid < 0: if self.vb: print 'new command =', dbcommand return 0 # new command, input everything if self.vb: print 'duplicte command = %s cid = %s' % (dbcommand, cid) # find the files associated with this commnand_id dbconn.query("""SELECT remote_path,checksum FROM files WHERE command_id='%s'""" % (cid)) r = dbconn.store_result() for file, hash in r.fetch_row(maxrows=0): for input in self.inputlist: if file in input and hash not in input: if self.vb: print 'file changed', file, hash #dbconn.query("""UPDATE commands SET status=2 WHERE command_id='%s'""" % (cid)) update command to Avaliable return 0 # file changed, insert command anyway if self.vb: print 'files identical, doing nothing to command = %s cid = %s (no new command inserted)' % (dbcommand, cid) return 1 cctools-4.0-source/cctools.indent0000751060042600000500000000036212175446362016034 0ustar btovardip#!/bin/sh # Standard indenting options for the cctools. # Run "cctools.indent filename" to properly indent a file. indent $@ -bap -br -brs -cdw -ce -cli0 -nfca -nhnl -nprs -nsaf -nsai -nsaw -nsob -npcs -npro -nss -l256 -nbfda -ut -i8 -npsl cctools-4.0-source/chirp/0000751060042600000500000000000012175446362014264 5ustar btovardipcctools-4.0-source/chirp/Makefile0000640060042600000500000000025212175446362015723 0ustar btovardipinclude ../Makefile.config include ../Makefile.rules all test install clean: for p in src test; do cd $$p && $(MAKE) $@ && cd .. ; done .PHONY: all test install clean cctools-4.0-source/chirp/src/0000751060042600000500000000000012175446362015053 5ustar btovardipcctools-4.0-source/chirp/src/.gitignore0000640060042600000500000000042212175446362017041 0ustar btovardipchirp_put chirp_stream_files chirp_distribute chirp chirp_benchmark chirp_md5sum chirp_get chirp_matrix_verify chirp_fuse chirp_server chirp_matrix_benchmark libchirp.a chirp_migrate chirp_matrix_roc chirp_status chirp_partition_stream chirp_server_hdfs libchirp_client.so cctools-4.0-source/chirp/src/Makefile0000640060042600000500000000662512175446362016524 0ustar btovardipinclude ../../Makefile.config include ../../Makefile.rules LOCAL_LDFLAGS = -ldttools -lchirp ${CCTOOLS_INTERNAL_LDFLAGS} LIBRARY_SOURCES = chirp_global.c chirp_multi.c chirp_recursive.c chirp_reli.c chirp_client.c chirp_matrix.c chirp_stream.c chirp_ticket.c SERVER_SOURCES = chirp_stats.c chirp_thirdput.c chirp_alloc.c chirp_audit.c chirp_acl.c chirp_group.c chirp_filesystem.c chirp_fs_hdfs.c chirp_fs_local.c chirp_fs_chirp.c chirp_ticket.c PROGRAMS=chirp chirp_get chirp_put chirp_server chirp_status chirp_benchmark chirp_stream_files chirp_fuse chirp_distribute SCRIPTS=chirp_audit_cluster chirp_server_hdfs LIBRARIES=libchirp.a libchirp_client.${CCTOOLS_DYNAMIC_SUFFIX} PUBLIC_HEADERS=chirp_global.h chirp_multi.h chirp_reli.h chirp_client.h chirp_stream.h chirp_protocol.h chirp_matrix.h chirp_types.h chirp_recursive.h TARGETS = ${PROGRAMS} ${LIBRARIES} LIBRARY_OBJECTS = ${LIBRARY_SOURCES:%.c=%.o} SERVER_OBJECTS = ${SERVER_SOURCES:%.c=%.o} DTTOOLS_STATIC_LIBRARY = ../../dttools/src/libdttools.a CHIRP_STATIC_LIBRARY = libchirp.a STATIC_LIBRARIES = ${CHIRP_STATIC_LIBRARY} ${DTTOOLS_STATIC_LIBRARY} all: ${TARGETS} # This is the library intended to be used by clients of the system. libchirp.a: ${LIBRARY_OBJECTS} ${CCTOOLS_AR} rv $@ $^ ranlib $@ # This object exists primarily to get a linkable object for use # by ROOT and other systems that want to load Chirp dynamically. # Note that we explicitly include auth_all.o and ${CCTOOLS_DYNAMIC_AUTH_LIBS} # to force the inclusion of the various authentication infrastructures. libchirp_client.${CCTOOLS_DYNAMIC_SUFFIX}: ${LIBRARY_OBJECTS} ../../dttools/src/auth_all.o ${DTTOOLS_STATIC_LIBRARY} ${CCTOOLS_LD} ${CCTOOLS_DYNAMIC_FLAG} -o $@ $^ ${CCTOOLS_DYNAMIC_AUTH_LIBS} chirp: chirp_tool.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${CCTOOLS_READLINE_LDFLAGS} ${LOCAL_LDFLAGS} chirp_server: chirp_server.o ${SERVER_OBJECTS} ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_get: chirp_get.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_put: chirp_put.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_benchmark: chirp_benchmark.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_status: chirp_status.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_fuse: chirp_fuse.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_distribute: chirp_distribute.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_matrix_benchmark: chirp_matrix_benchmark.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_matrix_roc: chirp_matrix_roc.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_matrix_verify: chirp_matrix_verify.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} chirp_stream_files: chirp_stream_files.o ${STATIC_LIBRARIES} ${CCTOOLS_LD} -o $@ $^ ${LOCAL_LDFLAGS} test: all clean: rm -f core *~ *.o *.os *.a *.${CCTOOLS_DYNAMIC_SUFFIX} ${TARGETS} install: all mkdir -p ${CCTOOLS_INSTALL_DIR}/bin mkdir -p ${CCTOOLS_INSTALL_DIR}/lib mkdir -p ${CCTOOLS_INSTALL_DIR}/include/cctools if [ -f ${CCTOOLS_INSTALL_DIR}/bin/chirp_server ]; then mv ${CCTOOLS_INSTALL_DIR}/bin/chirp_server ${CCTOOLS_INSTALL_DIR}/bin/chirp_server.old; fi chmod 755 ${SCRIPTS} cp ${PROGRAMS} ${SCRIPTS} ${CCTOOLS_INSTALL_DIR}/bin cp ${LIBRARIES} ${CCTOOLS_INSTALL_DIR}/lib cp ${PUBLIC_HEADERS} ${CCTOOLS_INSTALL_DIR}/include/cctools cctools-4.0-source/chirp/src/chirp_acl.c0000640060042600000500000005375412175446362017161 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include "chirp_acl.h" #include "chirp_filesystem.h" #include "chirp_group.h" #include "chirp_protocol.h" #include "chirp_ticket.h" #include "debug.h" #include "hash_table.h" #include "stringtools.h" #include "username.h" #include "xxmalloc.h" #include #include #include #include #include #include #include #include #include #include #include static int read_only_mode = 0; static const char *default_acl = 0; extern const char *chirp_super_user; extern const char *chirp_ticket_path; void chirp_acl_force_readonly() { read_only_mode = 1; } void chirp_acl_default(const char *d) { default_acl = d; } static void make_acl_name(const char *filename, int get_parent, char *aclname) { char tmp[CHIRP_PATH_MAX]; sprintf(tmp, "%s/%s", filename, CHIRP_ACL_BASE_NAME); string_collapse_path(tmp, aclname, 1); } static int ticket_read(char *ticket_filename, struct chirp_ticket *ct) { CHIRP_FILE *tf = cfs_fopen(ticket_filename, "r"); if(!tf) return 0; char *b; size_t l; if(!cfs_freadall(tf, &b, &l)) { cfs_fclose(tf); return 0; } cfs_fclose(tf); int result = chirp_ticket_read(b, ct); free(b); return result; } static int ticket_write(const char *ticket_filename, struct chirp_ticket *ct) { CHIRP_FILE *tf = cfs_fopen(ticket_filename, "w"); if(!tf) return 0; char *str = chirp_ticket_tostring(ct); cfs_fprintf(tf, "%s", str); free(str); int result = cfs_ferror(tf); cfs_fclose(tf); if(result) { errno = EACCES; return -1; } return 0; } /* do_chirp_acl_get returns the acl flags associated with a subject and directory. If the subject has rights there, they are returned and errno is undefined. If the directory exists, but the subject has no rights, returns zero with errno=0. If the rights cannot be obtained, returns zero with errno set appropriately. */ static int do_chirp_acl_get(const char *dirname, const char *subject, int *totalflags) { CHIRP_FILE *aclfile; char aclsubject[CHIRP_LINE_MAX]; int aclflags; errno = 0; *totalflags = 0; /* if the subject is a ticket, then we need the rights we have for the * directory along with the rights of the subject in that directory */ const char *digest; if(chirp_ticket_isticketsubject(subject, &digest)) { /* open the ticket file, read the public key */ char ticket_filename[CHIRP_PATH_MAX]; struct chirp_ticket ct; chirp_ticket_filename(ticket_filename, subject, NULL); if(!ticket_read(ticket_filename, &ct)) return 0; if(!do_chirp_acl_get(dirname, ct.subject, totalflags)) { chirp_ticket_free(&ct); return 0; } size_t i; size_t longest = 0; int mask = 0; for(i = 0; i < ct.nrights; i++) { char safewhere[CHIRP_PATH_MAX]; char where[CHIRP_PATH_MAX]; sprintf(safewhere, "%s/%s", chirp_ticket_path, ct.rights[i].directory); string_collapse_path(safewhere, where, 1); if(strncmp(dirname, where, strlen(where)) == 0) { if(strlen(where) > longest) { longest = strlen(where); mask = chirp_acl_text_to_flags(ct.rights[i].acl); } } } *totalflags &= mask; } else { aclfile = chirp_acl_open(dirname); if(aclfile) { while(chirp_acl_read(aclfile, aclsubject, &aclflags)) { if(string_match(aclsubject, subject)) { *totalflags |= aclflags; } else if(!strncmp(aclsubject, "group:", 6)) { if(chirp_group_lookup(aclsubject, subject)) { *totalflags |= aclflags; } } } chirp_acl_close(aclfile); } else { return 0; } } if(read_only_mode) { *totalflags &= CHIRP_ACL_READ | CHIRP_ACL_LIST; } return 1; } int chirp_acl_check_dir(const char *dirname, const char *subject, int flags) { int myflags; if(cfs->do_acl_check() == 0) return 1; if(!do_chirp_acl_get(dirname, subject, &myflags)) { /* Applications are very sensitive to this error condition. A missing ACL file indicates permission denied, but a missing directory entirely indicates no such entry. */ if(cfs_isdir(dirname)) { errno = EACCES; } else { errno = ENOENT; } return 0; } /* The superuser can implicitly list and admin */ if(chirp_super_user && !strcmp(subject, chirp_super_user)) { myflags |= CHIRP_ACL_LIST | CHIRP_ACL_ADMIN; } if((flags & myflags) == flags) { return 1; } else { errno = EACCES; return 0; } } static int do_chirp_acl_check(const char *filename, const char *subject, int flags, int follow_links) { char linkname[CHIRP_PATH_MAX]; char temp[CHIRP_PATH_MAX]; char dirname[CHIRP_PATH_MAX]; if(cfs->do_acl_check() == 0) return 1; /* Symbolic links require special handling. If requested, follow the link and look for rights in that directory. */ if(follow_links && flags != CHIRP_ACL_DELETE) { int length = cfs->readlink(filename, linkname, sizeof(linkname)); if(length > 0) { linkname[length] = 0; /* If the link is relative, construct a full path */ if(linkname[0] != '/') { sprintf(temp, "%s/../%s", filename, linkname); string_collapse_path(temp, linkname, 1); } /* Use the linkname now to look up the ACL */ debug(D_DEBUG, "symlink %s points to %s", filename, linkname); filename = linkname; } } /* If the file being checked is an ACL file, then it may be written with the admin flag, but never deleted. */ if(!strcmp(string_back(filename, CHIRP_ACL_BASE_LENGTH), CHIRP_ACL_BASE_NAME)) { if(flags & CHIRP_ACL_DELETE) { errno = EACCES; return 0; } if(flags & CHIRP_ACL_WRITE) { flags &= ~CHIRP_ACL_WRITE; flags |= CHIRP_ACL_ADMIN; } } /* Now get the name of the directory containing the file */ string_collapse_path(filename, temp, 1); if(!cfs_isdir(temp)) string_dirname(temp, dirname); else strcpy(dirname, temp); /* Perform the permissions check on that directory. */ return chirp_acl_check_dir(dirname, subject, flags); } int chirp_acl_check(const char *filename, const char *subject, int flags) { return do_chirp_acl_check(filename, subject, flags, 1); } int chirp_acl_check_link(const char *filename, const char *subject, int flags) { return do_chirp_acl_check(filename, subject, flags, 0); } char *chirp_acl_ticket_callback(const char *digest) { char path[CHIRP_PATH_MAX]; struct chirp_ticket ct; chirp_ticket_filename(path, NULL, digest); if(ticket_read(path, &ct)) { char *ticket = xxstrdup(ct.ticket); chirp_ticket_free(&ct); return ticket; } return NULL; } int chirp_acl_ticket_delete(const char *ticket_dir, const char *subject, const char *ticket_subject) { char ticket_filename[CHIRP_PATH_MAX]; const char *digest; char *esubject; struct chirp_ticket ct; int status = 0; if(!chirp_ticket_isticketsubject(ticket_subject, &digest)) { errno = EINVAL; return -1; } if(!chirp_acl_whoami(subject, &esubject)) return -1; chirp_ticket_filename(ticket_filename, ticket_subject, NULL); if(!ticket_read(ticket_filename, &ct)) { free(esubject); return -1; } if(strcmp(esubject, ct.subject) == 0 || strcmp(chirp_super_user, subject) == 0) { status = cfs->unlink(ticket_filename); } else { errno = EACCES; status = -1; } chirp_ticket_free(&ct); free(esubject); return status; } int chirp_acl_ticket_get(const char *ticket_dir, const char *subject, const char *ticket_subject, char **ticket_esubject, char **ticket, time_t * ticket_expiration, char ***ticket_rights) { char *esubject; if(!chirp_acl_whoami(subject, &esubject)) return -1; const char *digest; if(!chirp_ticket_isticketsubject(ticket_subject, &digest)) { errno = EINVAL; return -1; } struct chirp_ticket ct; char ticket_filename[CHIRP_PATH_MAX]; chirp_ticket_filename(ticket_filename, ticket_subject, NULL); if(!ticket_read(ticket_filename, &ct)) { free(esubject); errno = EINVAL; return -1; } if(strcmp(ct.subject, subject) == 0 || strcmp(subject, chirp_super_user) == 0) { *ticket_esubject = xxstrdup(ct.subject); *ticket = xxstrdup(ct.ticket); time_t now; time(&now); now = mktime(gmtime(&now)); /* convert to UTC */ *ticket_expiration = ct.expiration - now; size_t n; *ticket_rights = (char **) xxmalloc(sizeof(char *) * 2 * (ct.nrights + 1)); for(n = 0; n < ct.nrights; n++) { (*ticket_rights)[n * 2 + 0] = xxstrdup(ct.rights[n].directory); (*ticket_rights)[n * 2 + 1] = xxstrdup(ct.rights[n].acl); } (*ticket_rights)[n * 2 + 0] = NULL; (*ticket_rights)[n * 2 + 1] = NULL; chirp_ticket_free(&ct); free(esubject); return 0; } else { chirp_ticket_free(&ct); free(esubject); errno = EACCES; return -1; } } int chirp_acl_ticket_list(const char *ticket_dir, const char *subject, char ***ticket_subjects) { size_t n = 0; *ticket_subjects = NULL; struct chirp_dirent *d; struct chirp_dir *dir; dir = cfs->opendir(ticket_dir); if(dir == NULL) return -1; while((d = cfs->readdir(dir))) { if(strcmp(d->name, ".") == 0 || strcmp(d->name, "..") == 0) continue; char path[CHIRP_PATH_MAX]; sprintf(path, "%s/%s", ticket_dir, d->name); const char *digest; if(chirp_ticket_isticketfilename(d->name, &digest)) { struct chirp_ticket ct; if(!ticket_read(path, &ct)) continue; /* expired? */ if(strcmp(subject, ct.subject) == 0 || strcmp(subject, "all") == 0) { char ticket_subject[CHIRP_PATH_MAX]; n = n + 1; *ticket_subjects = (char **) xxrealloc(*ticket_subjects, (n + 1) * sizeof(char *)); chirp_ticket_subject(ticket_subject, d->name); (*ticket_subjects)[n - 1] = xxstrdup(ticket_subject); (*ticket_subjects)[n] = NULL; } chirp_ticket_free(&ct); } } cfs->closedir(dir); return 0; } int chirp_acl_gctickets(const char *ticket_dir) { struct chirp_dir *dir; struct chirp_dirent *d; dir = cfs->opendir(ticket_dir); if(!dir) { return -1; } while((d = cfs->readdir(dir))) { const char *digest; if(chirp_ticket_isticketfilename(d->name, &digest)) { /* open the ticket file, read the public key */ struct chirp_ticket ct; char path[CHIRP_PATH_MAX]; sprintf(path, "%s/%s", ticket_dir, d->name); if(ticket_read(path, &ct)) { chirp_ticket_free(&ct); continue; } debug(D_CHIRP, "ticket %s expired (or corrupt), garbage collecting", digest); cfs->unlink(path); } } cfs->closedir(dir); return 0; } int chirp_acl_ticket_create(const char *ticket_dir, const char *subject, const char *newsubject, const char *ticket, const char *duration) { time_t now; /*, delta; */ time_t offset = (time_t) strtoul(duration, NULL, 10); const char *digest; char ticket_subject[CHIRP_PATH_MAX]; char ticket_filename[CHIRP_PATH_MAX]; char expiration[128]; now = time(NULL); now = mktime(gmtime(&now)); /* convert to UTC */ sprintf(expiration, "%lu", (unsigned long) (now + offset)); /* Note about tickets making tickets: * A ticket created by a ticket authenticated user has the same effective * subject (see the ticket_register RPC in chirp_server.c). Also, the * expiration time is less than or equal to the expiration time of the * ticket used to authenticate. */ if(chirp_ticket_isticketsubject(subject, &digest)) { struct chirp_ticket ct; chirp_ticket_filename(ticket_filename, subject, NULL); if(!ticket_read(ticket_filename, &ct)) return -1; if(ct.expiration < now + offset) { sprintf(expiration, "%lu", (unsigned long) ct.expiration); } chirp_ticket_free(&ct); } if(!cfs_isdir(ticket_dir)) { errno = ENOTDIR; return -1; } chirp_ticket_name(ticket, ticket_subject, ticket_filename); CHIRP_FILE *f = cfs_fopen(ticket_filename, "w"); if(!f) { errno = EACCES; return -1; } cfs_fprintf(f, "subject \"%s\"\n", newsubject); cfs_fprintf(f, "expiration \"%s\"\n", expiration); cfs_fprintf(f, "ticket \"%s\"\n", ticket); cfs_fprintf(f, "rights \"/\" \"n\"\n"); cfs_fflush(f); int result = cfs_ferror(f); if(result) { errno = EACCES; return -1; } cfs_fclose(f); return 0; } int chirp_acl_ticket_modify(const char *ticket_dir, const char *subject, const char *ticket_subject, const char *path, int flags) { char ticket_filename[CHIRP_PATH_MAX]; const char *digest; char *esubject; struct chirp_ticket ct; int status = 0; if(!chirp_ticket_isticketsubject(ticket_subject, &digest)) { errno = EINVAL; return -1; } /* Note about tickets making tickets: * We check whether the ticket has the rights associated with the mask in * the next line. So, a ticket can only make a ticket with rights it * already has. */ if(!chirp_acl_check_dir(path, subject, flags)) return -1; /* you don't have the rights for the mask */ if(!chirp_acl_whoami(subject, &esubject)) return -1; chirp_ticket_filename(ticket_filename, ticket_subject, NULL); if(!ticket_read(ticket_filename, &ct)) { free(esubject); return -1; } if(strcmp(esubject, ct.subject) == 0 || strcmp(chirp_super_user, subject) == 0) { size_t n; int replaced = 0; for(n = 0; n < ct.nrights; n++) { char safewhere[CHIRP_PATH_MAX]; char where[CHIRP_PATH_MAX]; sprintf(safewhere, "%s/%s", ticket_dir, ct.rights[n].directory); string_collapse_path(safewhere, where, 1); if(strcmp(where, path) == 0) { free(ct.rights[n].acl); ct.rights[n].acl = xxstrdup(chirp_acl_flags_to_text(flags)); /* replace old acl mask */ replaced = 1; } } if(!replaced) { assert(strlen(path) >= strlen(ticket_dir)); ct.rights = xxrealloc(ct.rights, sizeof(*ct.rights) * (++ct.nrights) + 1); char directory[CHIRP_PATH_MAX]; char collapsed_directory[CHIRP_PATH_MAX]; sprintf(directory, "/%s", path + strlen(ticket_dir)); string_collapse_path(directory, collapsed_directory, 1); ct.rights[ct.nrights - 1].directory = xxstrdup(collapsed_directory); ct.rights[ct.nrights - 1].acl = xxstrdup(chirp_acl_flags_to_text(flags)); } status = ticket_write(ticket_filename, &ct); } else { errno = EACCES; status = -1; } chirp_ticket_free(&ct); free(esubject); return status; } int chirp_acl_whoami(const char *subject, char **esubject) { const char *digest; if(chirp_ticket_isticketsubject(subject, &digest)) { /* open the ticket file */ struct chirp_ticket ct; char ticket_filename[CHIRP_PATH_MAX]; chirp_ticket_filename(ticket_filename, subject, NULL); if(!ticket_read(ticket_filename, &ct)) return 0; *esubject = xxstrdup(ct.subject); chirp_ticket_free(&ct); return 1; } else { *esubject = xxstrdup(subject); return 1; } } int chirp_acl_set(const char *dirname, const char *subject, int flags, int reset_acl) { char aclname[CHIRP_PATH_MAX]; char newaclname[CHIRP_PATH_MAX]; char aclsubject[CHIRP_LINE_MAX]; int aclflags; CHIRP_FILE *aclfile, *newaclfile; int result; int replaced_acl_entry = 0; if(!cfs_isdir(dirname)) { errno = ENOTDIR; return -1; } sprintf(aclname, "%s/%s", dirname, CHIRP_ACL_BASE_NAME); sprintf(newaclname, "%s/%s.%d", dirname, CHIRP_ACL_BASE_NAME, (int) getpid()); if(reset_acl) { aclfile = cfs_fopen("/dev/null", "r"); } else { aclfile = cfs_fopen(aclname, "r"); /* If the acl never existed, then we can simply create it. */ if(!aclfile && errno == ENOENT) { if(default_acl) { aclfile = cfs_fopen(default_acl, "r"); } else { aclfile = cfs_fopen("/dev/null", "r"); /* use local... */ } } } if(!aclfile) { errno = EACCES; return -1; } replaced_acl_entry = 0; newaclfile = cfs_fopen(newaclname, "w"); if(!newaclfile) { cfs_fclose(aclfile); errno = EACCES; return -1; } while(chirp_acl_read(aclfile, aclsubject, &aclflags)) { if(!strcmp(subject, aclsubject)) { aclflags = flags; replaced_acl_entry = 1; } if(aclflags != 0) { cfs_fprintf(newaclfile, "%s %s\n", aclsubject, chirp_acl_flags_to_text(aclflags)); } } cfs_fclose(aclfile); if(!replaced_acl_entry) { cfs_fprintf(newaclfile, "%s %s\n", subject, chirp_acl_flags_to_text(flags)); } /* Need to force a write in order to get response from ferror */ cfs_fflush(newaclfile); result = cfs_ferror(newaclfile); cfs_fclose(newaclfile); if(result) { errno = EACCES; result = -1; } else { result = cfs->rename(newaclname, aclname); if(result < 0) { cfs->unlink(newaclname); errno = EACCES; result = -1; } } return result; } CHIRP_FILE *chirp_acl_open(const char *dirname) { char aclname[CHIRP_PATH_MAX]; CHIRP_FILE *file; make_acl_name(dirname, 0, aclname); file = cfs_fopen(aclname, "r"); if(!file && default_acl) file = cfs_fopen(default_acl, "r"); return file; } int chirp_acl_read(CHIRP_FILE * aclfile, char *subject, int *flags) { char acl[CHIRP_LINE_MAX]; char tmp[CHIRP_LINE_MAX]; while(cfs_fgets(acl, sizeof(acl), aclfile)) { if(sscanf(acl, "%[^ ] %[rwldpvax()]", subject, tmp) == 2) { *flags = chirp_acl_text_to_flags(tmp); return 1; } else { continue; } } return 0; } void chirp_acl_close(CHIRP_FILE * aclfile) { cfs_fclose(aclfile); } const char *chirp_acl_flags_to_text(int flags) { static char text[20]; text[0] = 0; if(flags & CHIRP_ACL_READ) strcat(text, "r"); if(flags & CHIRP_ACL_WRITE) strcat(text, "w"); if(flags & CHIRP_ACL_LIST) strcat(text, "l"); if(flags & CHIRP_ACL_DELETE) strcat(text, "d"); if(flags & CHIRP_ACL_PUT) strcat(text, "p"); if(flags & CHIRP_ACL_ADMIN) strcat(text, "a"); if(flags & CHIRP_ACL_EXECUTE) strcat(text, "x"); if(flags & CHIRP_ACL_RESERVE) { strcat(text, "v"); strcat(text, "("); if(flags & CHIRP_ACL_RESERVE_READ) strcat(text, "r"); if(flags & CHIRP_ACL_RESERVE_WRITE) strcat(text, "w"); if(flags & CHIRP_ACL_RESERVE_LIST) strcat(text, "l"); if(flags & CHIRP_ACL_RESERVE_DELETE) strcat(text, "d"); if(flags & CHIRP_ACL_RESERVE_PUT) strcat(text, "p"); if(flags & CHIRP_ACL_RESERVE_RESERVE) strcat(text, "v"); if(flags & CHIRP_ACL_RESERVE_ADMIN) strcat(text, "a"); if(flags & CHIRP_ACL_RESERVE_EXECUTE) strcat(text, "x"); strcat(text, ")"); } if(text[0] == 0) { strcpy(text, "n"); } return text; } int chirp_acl_text_to_flags(const char *t) { int flags = 0; while(*t) { if(*t == 'r') flags |= CHIRP_ACL_READ; if(*t == 'w') flags |= CHIRP_ACL_WRITE; if(*t == 'l') flags |= CHIRP_ACL_LIST; if(*t == 'd') flags |= CHIRP_ACL_DELETE; if(*t == 'p') flags |= CHIRP_ACL_PUT; if(*t == 'a') flags |= CHIRP_ACL_ADMIN; if(*t == 'x') flags |= CHIRP_ACL_EXECUTE; if(*t == 'v') { flags |= CHIRP_ACL_RESERVE; if(t[1] == '(') { t += 2; while(*t && *t != ')') { if(*t == 'r') flags |= CHIRP_ACL_RESERVE_READ; if(*t == 'w') flags |= CHIRP_ACL_RESERVE_WRITE; if(*t == 'l') flags |= CHIRP_ACL_RESERVE_LIST; if(*t == 'd') flags |= CHIRP_ACL_RESERVE_DELETE; if(*t == 'p') flags |= CHIRP_ACL_RESERVE_PUT; if(*t == 'v') flags |= CHIRP_ACL_RESERVE_RESERVE; if(*t == 'a') flags |= CHIRP_ACL_RESERVE_ADMIN; if(*t == 'x') flags |= CHIRP_ACL_RESERVE_EXECUTE; ++t; } } } ++t; } return flags; } int chirp_acl_from_access_flags(int flags) { int acl = 0; if(flags & R_OK) acl |= CHIRP_ACL_READ; if(flags & W_OK) acl |= CHIRP_ACL_WRITE; if(flags & X_OK) acl |= CHIRP_ACL_EXECUTE; if(flags & F_OK) acl |= CHIRP_ACL_READ; if(acl == 0) acl |= CHIRP_ACL_READ; return acl; } int chirp_acl_from_open_flags(int flags) { int acl = 0; if(flags & O_WRONLY) acl |= CHIRP_ACL_WRITE; if(flags & O_RDWR) acl |= CHIRP_ACL_READ | CHIRP_ACL_WRITE; if(flags & O_CREAT) acl |= CHIRP_ACL_WRITE; if(flags & O_TRUNC) acl |= CHIRP_ACL_WRITE; if(flags & O_APPEND) acl |= CHIRP_ACL_WRITE; if(acl == 0) acl |= CHIRP_ACL_READ; return acl; } int chirp_acl_init_root(const char *path) { char aclpath[CHIRP_PATH_MAX]; char username[USERNAME_MAX]; CHIRP_FILE *file; if(!cfs->do_acl_check()) return 1; file = chirp_acl_open(path); if(file) { chirp_acl_close(file); return 1; } username_get(username); sprintf(aclpath, "%s/%s", path, CHIRP_ACL_BASE_NAME); file = cfs_fopen(aclpath, "w"); if(file) { cfs_fprintf(file, "unix:%s %s\n", username, chirp_acl_flags_to_text(CHIRP_ACL_READ | CHIRP_ACL_WRITE | CHIRP_ACL_DELETE | CHIRP_ACL_LIST | CHIRP_ACL_ADMIN)); cfs_fclose(file); return 1; } else { return 0; } } int chirp_acl_init_copy(const char *path) { char oldpath[CHIRP_LINE_MAX]; char newpath[CHIRP_LINE_MAX]; char subject[CHIRP_LINE_MAX]; CHIRP_FILE *oldfile; CHIRP_FILE *newfile; int result = 0; int flags; if(!cfs->do_acl_check()) return 1; sprintf(oldpath, "%s/..", path); sprintf(newpath, "%s/%s", path, CHIRP_ACL_BASE_NAME); oldfile = chirp_acl_open(oldpath); if(oldfile) { newfile = cfs_fopen(newpath, "w"); if(newfile) { while(chirp_acl_read(oldfile, subject, &flags)) { cfs_fprintf(newfile, "%s %s\n", subject, chirp_acl_flags_to_text(flags)); } cfs_fclose(newfile); result = 1; } chirp_acl_close(oldfile); } return result; } int chirp_acl_init_reserve(const char *path, const char *subject) { char dirname[CHIRP_PATH_MAX]; char aclpath[CHIRP_PATH_MAX]; CHIRP_FILE *file; int newflags = 0; int aclflags; if(!cfs->do_acl_check()) return 1; string_dirname(path, dirname); if(!do_chirp_acl_get(dirname, subject, &aclflags)) return 0; if(aclflags & CHIRP_ACL_RESERVE_READ) newflags |= CHIRP_ACL_READ; if(aclflags & CHIRP_ACL_RESERVE_WRITE) newflags |= CHIRP_ACL_WRITE; if(aclflags & CHIRP_ACL_RESERVE_LIST) newflags |= CHIRP_ACL_LIST; if(aclflags & CHIRP_ACL_RESERVE_DELETE) newflags |= CHIRP_ACL_DELETE; if(aclflags & CHIRP_ACL_RESERVE_PUT) newflags |= CHIRP_ACL_PUT; if(aclflags & CHIRP_ACL_RESERVE_RESERVE) newflags |= CHIRP_ACL_RESERVE; if(aclflags & CHIRP_ACL_RESERVE_ADMIN) newflags |= CHIRP_ACL_ADMIN; if(aclflags & CHIRP_ACL_RESERVE_EXECUTE) newflags |= CHIRP_ACL_EXECUTE; /* compatibility note: If no sub-rights are associated with the v right, then give all of the ordinary subrights. */ if(newflags == 0) newflags = CHIRP_ACL_READ | CHIRP_ACL_WRITE | CHIRP_ACL_LIST | CHIRP_ACL_DELETE | CHIRP_ACL_ADMIN; sprintf(aclpath, "%s/%s", path, CHIRP_ACL_BASE_NAME); file = cfs_fopen(aclpath, "w"); if(file) { cfs_fprintf(file, "%s %s\n", subject, chirp_acl_flags_to_text(newflags)); cfs_fclose(file); return 1; } else { return 0; } } cctools-4.0-source/chirp/src/chirp_acl.h0000640060042600000500000000562312175446362017156 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #ifndef CHIRP_ACL_H #define CHIRP_ACL_H #include "chirp_filesystem.h" #include "hash_table.h" #include #define CHIRP_ACL_BASE_NAME ".__acl" #define CHIRP_ACL_BASE_LENGTH (strlen(CHIRP_ACL_BASE_NAME)) #define CHIRP_ACL_READ (1<<0) #define CHIRP_ACL_WRITE (1<<1) #define CHIRP_ACL_LIST (1<<2) #define CHIRP_ACL_DELETE (1<<3) #define CHIRP_ACL_ADMIN (1<<4) #define CHIRP_ACL_EXECUTE (1<<5) #define CHIRP_ACL_PUT (1<<6) #define CHIRP_ACL_RESERVE_READ (1<<7) #define CHIRP_ACL_RESERVE_WRITE (1<<8) #define CHIRP_ACL_RESERVE_LIST (1<<9) #define CHIRP_ACL_RESERVE_DELETE (1<<10) #define CHIRP_ACL_RESERVE_PUT (1<<11) #define CHIRP_ACL_RESERVE_ADMIN (1<<12) #define CHIRP_ACL_RESERVE_RESERVE (1<<13) #define CHIRP_ACL_RESERVE_EXECUTE (1<<14) #define CHIRP_ACL_RESERVE (1<<15) #define CHIRP_ACL_ALL (~0) int chirp_acl_check(const char *filename, const char *subject, int flags); int chirp_acl_check_dir(const char *dirname, const char *subject, int flags); int chirp_acl_check_link(const char *linkname, const char *subject, int flags); int chirp_acl_set(const char *filename, const char *subject, int flags, int reset_acl); int chirp_acl_ticket_create(const char *ticketdir, const char *subject, const char *newsubject, const char *ticket, const char *duration); int chirp_acl_ticket_modify(const char *ticketdir, const char *subject, const char *ticket_subject, const char *path, int flags); char *chirp_acl_ticket_callback(const char *digest); int chirp_acl_gctickets(const char *ticketdir); int chirp_acl_ticket_delete(const char *ticketdir, const char *subject, const char *ticket_subject); int chirp_acl_ticket_get(const char *ticketdir, const char *subject, const char *ticket_subject, char **ticket_esubject, char **ticket, time_t * ticket_expiration, char ***ticket_rights); int chirp_acl_ticket_list(const char *ticketdir, const char *subject, char **ticket_subjects[]); CHIRP_FILE *chirp_acl_open(const char *filename); int chirp_acl_read(CHIRP_FILE * aclfile, char *subject, int *flags); void chirp_acl_close(CHIRP_FILE * aclfile); const char *chirp_acl_flags_to_text(int flags); int chirp_acl_text_to_flags(const char *text); int chirp_acl_from_access_flags(int flags); int chirp_acl_from_open_flags(int flags); void chirp_acl_force_readonly(); void chirp_acl_timeout_set(int t); int chirp_acl_timeout_get(); void chirp_acl_default(const char *aclpath); int chirp_acl_init_root(const char *path); int chirp_acl_init_copy(const char *path); int chirp_acl_init_reserve(const char *path, const char *subject); int chirp_acl_whoami(const char *subject, char **esubject); int is_a_directory(const char *filename); #endif cctools-4.0-source/chirp/src/chirp_alloc.c0000640060042600000500000005435712175446362017514 0ustar btovardip/* Copyright (C) 2008- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include "macros.h" #include "chirp_acl.h" #include "chirp_alloc.h" #include "chirp_protocol.h" #include "chirp_filesystem.h" #include "itable.h" #include "hash_table.h" #include "xxmalloc.h" #include "int_sizes.h" #include "stringtools.h" #include "full_io.h" #include "delete_dir.h" #include "debug.h" #include #include #include #include #include #include #include #include #include static struct hash_table *alloc_table = 0; static struct hash_table *root_table = 0; static struct itable *fd_table = 0; static int recovery_in_progress = 0; static int alloc_enabled = 0; extern char *chirp_root_path; struct alloc_state { FILE *file; INT64_T size; INT64_T inuse; INT64_T avail; INT64_T dirty; }; /* Note that the space consumed by a file is not the same as the filesize. This function computes the space consumed by a file of a given size. Currently, it rounds up to the next blocksize. A more exact function might take into account indirect blocks allocated within the filesystem. */ static INT64_T space_consumed(INT64_T filesize) { INT64_T block_size = 4096; INT64_T blocks = filesize / block_size; if(filesize % block_size) blocks++; return blocks * block_size; } static void alloc_state_update(struct alloc_state *a, INT64_T change) { if(change != 0) { a->inuse += change; if(a->inuse < 0) a->inuse = 0; a->avail = a->size - a->inuse; a->dirty = 1; } } static struct alloc_state *alloc_state_load(const char *path) { struct alloc_state *s = xxmalloc(sizeof(*s)); char statename[CHIRP_PATH_MAX]; debug(D_ALLOC, "locking %s", path); sprintf(statename, "%s/.__alloc", path); /* WARNING chirp_alloc assumes we are using the local filesystem */ s->file = fopen(statename, "r+"); if(!s->file) { free(s); return 0; } if(lockf(fileno(s->file), F_TLOCK, 0)) { debug(D_ALLOC, "lock of %s blocked; flushing outstanding locks", path); chirp_alloc_flush(); debug(D_ALLOC, "locking %s (retry)", path); if(lockf(fileno(s->file), F_LOCK, 0)) { debug(D_ALLOC, "lock of %s failed: %s", path, strerror(errno)); fclose(s->file); free(s); return 0; } } fscanf(s->file, "%" SCNd64 " %" SCNd64, &s->size, &s->inuse); s->dirty = 0; if(recovery_in_progress) { s->inuse = 0; s->dirty = 1; } s->avail = s->size - s->inuse; return s; } static void alloc_state_save(const char *path, struct alloc_state *s) { if(s->dirty) { debug(D_ALLOC, "storing %s", path); } else { debug(D_ALLOC, "freeing %s", path); } if(s->dirty) { ftruncate(fileno(s->file), 0); fseek(s->file, 0, SEEK_SET); fprintf(s->file, "%" PRId64 "\n%" PRId64 "\n", s->size, s->inuse); } fclose(s->file); free(s); } static int alloc_state_create(const char *path, INT64_T size) { char statepath[CHIRP_PATH_MAX]; FILE *file; sprintf(statepath, "%s/.__alloc", path); file = fopen(statepath, "w"); if(file) { fprintf(file, "%" PRId64 " 0\n", size); fclose(file); return 1; } else { return 0; } } static char *alloc_state_root(const char *path) { char dirname[CHIRP_PATH_MAX]; char statename[CHIRP_PATH_MAX]; char *s; strcpy(dirname, path); while(1) { sprintf(statename, "%s/.__alloc", dirname); if(cfs_file_size(statename) >= 0) { return xxstrdup(dirname); } s = strrchr(dirname, '/'); if(!s) return 0; *s = 0; } return 0; } static char *alloc_state_root_cached(const char *path) { char *result; if(!root_table) root_table = hash_table_create(0, 0); result = hash_table_lookup(root_table, path); if(result) return result; result = alloc_state_root(path); if(!result) return 0; hash_table_insert(root_table, path, result); return result; } static struct alloc_state *alloc_state_cache_exact(const char *path) { struct alloc_state *a; char *d; char dirname[CHIRP_PATH_MAX]; char statename[CHIRP_PATH_MAX]; d = alloc_state_root_cached(path); if(!d) return 0; /* Save a copy of dirname, because the following alloc_table_load_cached may result in a flush of the alloc table root. */ strcpy(dirname, d); sprintf(statename, "%s/.__alloc", dirname); if(!alloc_table) alloc_table = hash_table_create(0, 0); a = hash_table_lookup(alloc_table, dirname); if(a) return a; a = alloc_state_load(dirname); if(!a) return a; hash_table_insert(alloc_table, dirname, a); return a; } static struct alloc_state *alloc_state_cache(const char *path) { char dirname[CHIRP_PATH_MAX]; string_dirname(path, dirname); return alloc_state_cache_exact(dirname); } static void recover(const char *path) { char newpath[CHIRP_PATH_MAX]; struct alloc_state *a, *b; struct chirp_dir *dir; struct chirp_dirent *d; a = alloc_state_cache_exact(path); if(!a) fatal("couldn't open alloc state in %s: %s", path, strerror(errno)); dir = cfs->opendir(path); if(!dir) fatal("couldn't open %s: %s\n", path, strerror(errno)); while((d = cfs->readdir(dir))) { if(!strcmp(d->name, ".")) continue; if(!strcmp(d->name, "..")) continue; if(!strncmp(d->name, ".__", 3)) continue; sprintf(newpath, "%s/%s", path, d->name); if(S_ISDIR(d->info.cst_mode)) { recover(newpath); b = alloc_state_cache_exact(newpath); if(a != b) alloc_state_update(a, b->size); } else if(S_ISREG(d->info.cst_mode)) { alloc_state_update(a, space_consumed(d->info.cst_size)); } else { debug(D_ALLOC, "warning: unknown file type: %s\n", newpath); } } cfs->closedir(dir); debug(D_ALLOC, "%s (%sB)", path, string_metric(a->inuse, -1, 0)); } void chirp_alloc_init(const char *rootpath, INT64_T size) { struct alloc_state *a; time_t start, stop; INT64_T inuse, avail; #ifdef CCTOOLS_OPSYS_CYGWIN fatal("sorry, CYGWIN cannot employ space allocation because it does not support file locking."); #endif alloc_enabled = 1; recovery_in_progress = 1; debug(D_ALLOC, "### begin allocation recovery scan ###"); if(!alloc_state_create(rootpath, size)) fatal("couldn't create allocation in %s: %s\n", rootpath, strerror(errno)); a = alloc_state_cache_exact(rootpath); if(!a) fatal("couldn't find allocation in %s: %s\n", rootpath, strerror(errno)); start = time(0); recover(rootpath); size = a->size; inuse = a->inuse; avail = a->avail; chirp_alloc_flush(); stop = time(0); debug(D_ALLOC, "### allocation recovery took %d seconds ###", stop - start); debug(D_ALLOC, "%sB total", string_metric(size, -1, 0)); debug(D_ALLOC, "%sB in use", string_metric(inuse, -1, 0)); debug(D_ALLOC, "%sB available", string_metric(avail, -1, 0)); recovery_in_progress = 0; } static time_t last_flush_time = 0; void chirp_alloc_flush() { char *path, *root; struct alloc_state *s; if(!alloc_enabled) return; debug(D_ALLOC, "flushing allocation states..."); if(!alloc_table) alloc_table = hash_table_create(0, 0); hash_table_firstkey(alloc_table); while(hash_table_nextkey(alloc_table, &path, (void **) &s)) { alloc_state_save(path, s); hash_table_remove(alloc_table, path); } if(!root_table) root_table = hash_table_create(0, 0); hash_table_firstkey(root_table); while(hash_table_nextkey(root_table, &path, (void **) &root)) { free(root); hash_table_remove(root_table, path); } last_flush_time = time(0); } int chirp_alloc_flush_needed() { if(!alloc_enabled) return 0; return hash_table_size(alloc_table); } time_t chirp_alloc_last_flush_time() { return last_flush_time; } INT64_T chirp_alloc_search(const char *subject, const char *dir, const char *patt, int flags, struct link * l, time_t stoptime) { return cfs->search(subject, dir, patt, flags, l, stoptime); } INT64_T chirp_alloc_open(const char *path, INT64_T flags, INT64_T mode) { struct alloc_state *a; int fd = -1; if(!alloc_enabled) return cfs->open(path, flags, mode); a = alloc_state_cache(path); if(a) { INT64_T filesize = cfs_file_size(path); if(filesize < 0) filesize = 0; fd = cfs->open(path, flags, mode); if(fd >= 0) { if(!fd_table) fd_table = itable_create(0); itable_insert(fd_table, fd, xxstrdup(path)); if(flags & O_TRUNC) { alloc_state_update(a, -space_consumed(filesize)); } } } else { fd = -1; } return fd; } INT64_T chirp_alloc_close(int fd) { if(!alloc_enabled) return cfs->close(fd); if(!fd_table) fd_table = itable_create(0); char *path = itable_remove(fd_table, fd); if(path) free(path); cfs->close(fd); return 0; } INT64_T chirp_alloc_pread(int fd, void *buffer, INT64_T length, INT64_T offset) { return cfs->pread(fd, buffer, length, offset); } INT64_T chirp_alloc_pwrite(int fd, const void *data, INT64_T length, INT64_T offset) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->pwrite(fd, data, length, offset); if(!fd_table) fd_table = itable_create(0); a = alloc_state_cache(itable_lookup(fd_table, fd)); if(a) { INT64_T filesize = cfs_fd_size(fd); if(filesize >= 0) { INT64_T newfilesize = MAX(length + offset, filesize); INT64_T alloc_change = space_consumed(newfilesize) - space_consumed(filesize); if(a->avail >= alloc_change) { result = cfs->pwrite(fd, data, length, offset); if(result > 0) alloc_state_update(a, alloc_change); } else { errno = ENOSPC; result = -1; } } else { result = -1; } } else { result = -1; } return result; } INT64_T chirp_alloc_sread(int fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset) { return cfs->sread(fd, buffer, length, stride_length, stride_skip, offset); } INT64_T chirp_alloc_swrite(int fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset) { return cfs->swrite(fd, buffer, length, stride_length, stride_skip, offset); } INT64_T chirp_alloc_fstat(int fd, struct chirp_stat * buf) { return cfs->fstat(fd, buf); } INT64_T chirp_alloc_fstatfs(int fd, struct chirp_statfs * info) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->fstatfs(fd, info); if(!fd_table) fd_table = itable_create(0); a = alloc_state_cache(itable_lookup(fd_table, fd)); if(a) { result = cfs->fstatfs(fd, info); if(result == 0) { info->f_blocks = a->size / info->f_bsize; info->f_bfree = a->avail / info->f_bsize; info->f_bavail = a->avail / info->f_bsize; } } else { result = -1; } return result; } INT64_T chirp_alloc_fchown(int fd, INT64_T uid, INT64_T gid) { return cfs->fchown(fd, uid, gid); } INT64_T chirp_alloc_fchmod(int fd, INT64_T mode) { return cfs->fchmod(fd, mode); } INT64_T chirp_alloc_ftruncate(int fd, INT64_T length) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->ftruncate(fd, length); if(!fd_table) fd_table = itable_create(0); a = alloc_state_cache(itable_lookup(fd_table, fd)); if(a) { INT64_T filesize = cfs_fd_size(fd); if(filesize >= 0) { INT64_T alloc_change = space_consumed(length) - space_consumed(filesize); if(a->avail >= alloc_change) { result = cfs->ftruncate(fd, length); if(result == 0) alloc_state_update(a, alloc_change); } else { errno = ENOSPC; result = -1; } } else { result = -1; } } else { result = -1; } return result; } INT64_T chirp_alloc_fsync(int fd) { return cfs->fsync(fd); } struct chirp_dir *chirp_alloc_opendir(const char *path) { return cfs->opendir(path); } struct chirp_dirent *chirp_alloc_readdir(struct chirp_dir *dir) { return cfs->readdir(dir); } void chirp_alloc_closedir(struct chirp_dir *dir) { cfs->closedir(dir); } INT64_T chirp_alloc_getfile(const char *path, struct link *link, time_t stoptime) { return cfs->getfile(path, link, stoptime); } INT64_T chirp_alloc_getstream(const char *path, struct link * l, time_t stoptime) { INT64_T fd, result, actual, total = 0; int buffer_size = 65536; char *buffer; fd = chirp_alloc_open(path, O_RDONLY, 0700); if(fd < 0) return fd; link_putliteral(l, "0\n", stoptime); buffer = malloc(buffer_size); while(1) { result = chirp_alloc_pread(fd, buffer, buffer_size, total); if(result <= 0) break; actual = link_putlstring(l, buffer, result, stoptime); if(actual != result) break; total += actual; } free(buffer); chirp_alloc_close(fd); return total; } /* Note that putfile is given in advance the size of a file. It checks the space available, and then guarantees that the file will either be delivered whole or not at all. */ INT64_T chirp_alloc_putfile(const char *path, struct link * link, INT64_T length, INT64_T mode, time_t stoptime) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->putfile(path, link, length, mode, stoptime); result = chirp_alloc_unlink(path); if(result < 0 && errno != ENOENT) return result; a = alloc_state_cache(path); if(a) { if(a->avail > length) { result = cfs->putfile(path, link, length, mode, stoptime); if(result > 0) { alloc_state_update(a, space_consumed(result)); } else { cfs->unlink(path); } } else { errno = ENOSPC; result = -1; } } else { result = -1; } return result; } /* In contrast, putstream does not know the size of the output in advance, and simply writes piece by piece, updating the allocation state as it goes. */ INT64_T chirp_alloc_putstream(const char *path, struct link * l, time_t stoptime) { INT64_T fd, result, actual, total = 0; int buffer_size = 65536; char *buffer; fd = chirp_alloc_open(path, O_CREAT | O_TRUNC | O_WRONLY, 0700); if(fd < 0) return fd; link_putliteral(l, "0\n", stoptime); buffer = malloc(buffer_size); while(1) { result = link_read(l, buffer, buffer_size, stoptime); if(result <= 0) break; actual = chirp_alloc_pwrite(fd, buffer, result, total); if(actual != result) break; total += actual; } free(buffer); chirp_alloc_close(fd); return total; } INT64_T chirp_alloc_unlink(const char *path) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->unlink(path); a = alloc_state_cache(path); if(a) { INT64_T filesize = cfs_file_size(path); if(filesize >= 0) { result = cfs->unlink(path); if(result == 0) alloc_state_update(a, -space_consumed(filesize)); } else { result = -1; } } else { result = -1; } return result; } INT64_T chirp_alloc_rename(const char *oldpath, const char *newpath) { struct alloc_state *a, *b; int result = -1; if(!alloc_enabled) return cfs->rename(oldpath, newpath); a = alloc_state_cache(oldpath); if(a) { b = alloc_state_cache(newpath); if(b) { if(a == b) { result = rename(oldpath, newpath); } else { INT64_T filesize = cfs_file_size(oldpath); if(filesize >= 0) { if(b->avail >= filesize) { result = cfs->rename(oldpath, newpath); if(result == 0) { alloc_state_update(a, -space_consumed(filesize)); alloc_state_update(b, space_consumed(filesize)); } chirp_alloc_flush(); } else { errno = ENOSPC; result = -1; } } else { result = -1; } } } else { result = -1; } } else { result = -1; } return result; } INT64_T chirp_alloc_link(const char *path, const char *newpath) { if(!alloc_enabled) return cfs->link(path, newpath); errno = EPERM; return -1; } INT64_T chirp_alloc_symlink(const char *path, const char *newpath) { return cfs->symlink(path, newpath); } INT64_T chirp_alloc_readlink(const char *path, char *buf, INT64_T length) { return cfs->readlink(path, buf, length); } INT64_T chirp_alloc_mkdir(const char *path, INT64_T mode) { return cfs->mkdir(path, mode); } INT64_T chirp_alloc_rmall(const char *path) { if(!alloc_enabled) return cfs->rmall(path); int result = chirp_alloc_unlink(path); if(result == 0) { return 0; } else if(errno != EISDIR) { return -1; } else { struct chirp_dir *dir; struct chirp_dirent *d; char subpath[CHIRP_PATH_MAX]; dir = chirp_alloc_opendir(path); if(!dir) return -1; result = 0; while((d = chirp_alloc_readdir(dir))) { if(!strcmp(d->name, ".")) continue; if(!strcmp(d->name, "..")) continue; if(!strncmp(d->name, ".__ ", 3)) continue; sprintf(subpath, "%s/%s", path, d->name); result = chirp_alloc_rmall(subpath); if(result != 0) break; } chirp_alloc_closedir(dir); if(result == 0) { return chirp_alloc_rmdir(path); } else { return result; } } } INT64_T chirp_alloc_rmdir(const char *path) { struct alloc_state *a, *d; int result = -1; if(!alloc_enabled) return cfs->rmdir(path); d = alloc_state_cache_exact(path); if(d) { a = alloc_state_cache(path); if(a) { if(cfs->rmdir(path) == 0) { if(d != a) { alloc_state_update(a, -d->size); debug(D_ALLOC, "rmalloc %s %lld", path, d->size); } chirp_alloc_flush(); result = 0; } else { result = -1; } } } return result; } INT64_T chirp_alloc_stat(const char *path, struct chirp_stat * buf) { return cfs->stat(path, buf); } INT64_T chirp_alloc_lstat(const char *path, struct chirp_stat * buf) { return cfs->lstat(path, buf); } INT64_T chirp_alloc_statfs(const char *path, struct chirp_statfs * info) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->statfs(path, info); a = alloc_state_cache(path); if(a) { result = cfs->statfs(path, info); if(result == 0) { info->f_blocks = a->size / info->f_bsize; info->f_bavail = a->avail / info->f_bsize; info->f_bfree = a->avail / info->f_bsize; if(a->avail < 0) { info->f_bavail = 0; info->f_bfree = 0; } } } else { result = -1; } return result; } INT64_T chirp_alloc_access(const char *path, INT64_T mode) { return cfs->access(path, mode); } INT64_T chirp_alloc_chmod(const char *path, INT64_T mode) { return cfs->chmod(path, mode); } INT64_T chirp_alloc_chown(const char *path, INT64_T uid, INT64_T gid) { return cfs->chown(path, uid, gid); } INT64_T chirp_alloc_lchown(const char *path, INT64_T uid, INT64_T gid) { return cfs->lchown(path, uid, gid); } INT64_T chirp_alloc_truncate(const char *path, INT64_T newsize) { struct alloc_state *a; int result; if(!alloc_enabled) return cfs->truncate(path, newsize); a = alloc_state_cache(path); if(a) { INT64_T filesize = cfs_file_size(path); if(filesize >= 0) { INT64_T alloc_change = space_consumed(newsize) - space_consumed(filesize); if(a->avail >= alloc_change) { result = cfs->truncate(path, newsize); if(result == 0) alloc_state_update(a, alloc_change); } else { errno = ENOSPC; result = -1; } } else { result = -1; } } else { result = -1; } return result; } INT64_T chirp_alloc_utime(const char *path, time_t actime, time_t modtime) { return cfs->utime(path, actime, modtime); } INT64_T chirp_alloc_md5(const char *path, unsigned char digest[16]) { return cfs->md5(path, digest); } INT64_T chirp_alloc_setrep(const char *path, int nreps) { return cfs->setrep(path, nreps); } INT64_T chirp_alloc_lsalloc(const char *path, char *alloc_path, INT64_T * total, INT64_T * inuse) { char *name; struct alloc_state *a; int result = -1; if(!alloc_enabled) { errno = ENOSYS; return -1; } name = alloc_state_root_cached(path); if(name) { a = alloc_state_cache_exact(name); if(a) { strcpy(alloc_path, name); *total = a->size; *inuse = a->inuse; result = 0; } else { result = -1; } } else { result = -1; } return result; } INT64_T chirp_alloc_mkalloc(const char *path, INT64_T size, INT64_T mode) { struct alloc_state *a; int result = -1; if(!alloc_enabled) { errno = ENOSYS; return -1; } a = alloc_state_cache(path); if(a) { if(a->avail > size) { result = cfs->mkdir(path, mode); if(result == 0) { if(alloc_state_create(path, size)) { alloc_state_update(a, size); debug(D_ALLOC, "mkalloc %s %lld", path, size); chirp_alloc_flush(); } else { result = -1; } } } else { errno = ENOSPC; return -1; } } else { return -1; } return result; } char *chirp_stat_string(struct chirp_stat *info) { static char line[CHIRP_LINE_MAX]; sprintf(line, "%" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64, info->cst_dev, info->cst_ino, info->cst_mode, info->cst_nlink, info->cst_uid, info->cst_gid, info->cst_rdev, info->cst_size, info->cst_blksize, info->cst_blocks, info->cst_atime, info->cst_mtime, info->cst_ctime); return line; } char *chirp_statfs_string(struct chirp_statfs *info) { static char line[CHIRP_LINE_MAX]; sprintf(line, "%" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64, info->f_type, info->f_bsize, info->f_blocks, info->f_bfree, info->f_bavail, info->f_files, info->f_ffree); return line; } INT64_T chirp_alloc_getxattr(const char *path, const char *name, void *data, size_t size) { return cfs->getxattr(path, name, data, size); } INT64_T chirp_alloc_fgetxattr(int fd, const char *name, void *data, size_t size) { return cfs->fgetxattr(fd, name, data, size); } INT64_T chirp_alloc_lgetxattr(const char *path, const char *name, void *data, size_t size) { return cfs->lgetxattr(path, name, data, size); } INT64_T chirp_alloc_listxattr(const char *path, char *list, size_t size) { return cfs->listxattr(path, list, size); } INT64_T chirp_alloc_flistxattr(int fd, char *list, size_t size) { return cfs->flistxattr(fd, list, size); } INT64_T chirp_alloc_llistxattr(const char *path, char *list, size_t size) { return cfs->listxattr(path, list, size); } INT64_T chirp_alloc_setxattr(const char *path, const char *name, const void *data, size_t size, int flags) { /* FIXME check allocated */ return cfs->setxattr(path, name, data, size, flags); } INT64_T chirp_alloc_fsetxattr(int fd, const char *name, const void *data, size_t size, int flags) { /* FIXME check allocated */ return cfs->fsetxattr(fd, name, data, size, flags); } INT64_T chirp_alloc_lsetxattr(const char *path, const char *name, const void *data, size_t size, int flags) { /* FIXME check allocated */ return cfs->lsetxattr(path, name, data, size, flags); } INT64_T chirp_alloc_removexattr(const char *path, const char *name) { /* FIXME check allocated */ return cfs->removexattr(path, name); } INT64_T chirp_alloc_fremovexattr(int fd, const char *name) { /* FIXME check allocated */ return cfs->fremovexattr(fd, name); } INT64_T chirp_alloc_lremovexattr(const char *path, const char *name) { /* FIXME check allocated */ return cfs->lremovexattr(path, name); } cctools-4.0-source/chirp/src/chirp_alloc.h0000640060042600000500000001076212175446362017511 0ustar btovardip/* Copyright (C) 2008- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #ifndef CHIRP_ALLOC_H #define CHIRP_ALLOC_H #include "chirp_types.h" #include "link.h" #include #include void chirp_alloc_init(const char *rootpath, INT64_T size); void chirp_alloc_flush(); int chirp_alloc_flush_needed(); time_t chirp_alloc_last_flush_time(); INT64_T chirp_alloc_open(const char *path, INT64_T flags, INT64_T mode); INT64_T chirp_alloc_close(int fd); INT64_T chirp_alloc_pread(int fd, void *buffer, INT64_T length, INT64_T offset); INT64_T chirp_alloc_pwrite(int fd, const void *buffer, INT64_T length, INT64_T offset); INT64_T chirp_alloc_sread(int fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset); INT64_T chirp_alloc_swrite(int fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset); INT64_T chirp_alloc_fstat(int fd, struct chirp_stat *buf); INT64_T chirp_alloc_fstatfs(int fd, struct chirp_statfs *buf); INT64_T chirp_alloc_fchown(int fd, INT64_T uid, INT64_T gid); INT64_T chirp_alloc_fchmod(int fd, INT64_T mode); INT64_T chirp_alloc_ftruncate(int fd, INT64_T length); INT64_T chirp_alloc_fsync(int fd); struct chirp_dir * chirp_alloc_opendir( const char *path ); struct chirp_dirent * chirp_alloc_readdir( struct chirp_dir *dir ); void chirp_alloc_closedir( struct chirp_dir *dir ); INT64_T chirp_alloc_getfile(const char *path, struct link *link, time_t stoptime); INT64_T chirp_alloc_putfile(const char *path, struct link *link, INT64_T length, INT64_T mode, time_t stoptime); INT64_T chirp_alloc_getstream(const char *path, struct link *link, time_t stoptime); INT64_T chirp_alloc_putstream(const char *path, struct link *link, time_t stoptime); INT64_T chirp_alloc_unlink(const char *path); INT64_T chirp_alloc_rename(const char *path, const char *newpath); INT64_T chirp_alloc_link(const char *path, const char *newpath); INT64_T chirp_alloc_symlink(const char *path, const char *newpath); INT64_T chirp_alloc_readlink(const char *path, char *buf, INT64_T length); INT64_T chirp_alloc_mkdir(const char *path, INT64_T mode); INT64_T chirp_alloc_rmdir(const char *path); INT64_T chirp_alloc_rmall(const char *path); INT64_T chirp_alloc_stat(const char *path, struct chirp_stat *buf); INT64_T chirp_alloc_lstat(const char *path, struct chirp_stat *buf); INT64_T chirp_alloc_statfs(const char *path, struct chirp_statfs *buf); INT64_T chirp_alloc_access(const char *path, INT64_T mode); INT64_T chirp_alloc_chmod(const char *path, INT64_T mode); INT64_T chirp_alloc_chown(const char *path, INT64_T uid, INT64_T gid); INT64_T chirp_alloc_lchown(const char *path, INT64_T uid, INT64_T gid); INT64_T chirp_alloc_truncate(const char *path, INT64_T length); INT64_T chirp_alloc_utime(const char *path, time_t actime, time_t modtime); INT64_T chirp_alloc_md5(const char *path, unsigned char digest[16]); INT64_T chirp_alloc_setrep(const char *path, int nreps); INT64_T chirp_alloc_lsalloc(const char *path, char *alloc_path, INT64_T * total, INT64_T * inuse); INT64_T chirp_alloc_mkalloc(const char *path, INT64_T size, INT64_T mode); INT64_T chirp_alloc_file_size(const char *path); INT64_T chirp_alloc_fd_size(int fd); INT64_T chirp_alloc_search(const char *subject, const char *dir, const char *pattern, int flags, struct link *l, time_t stalltime); char *chirp_stat_string(struct chirp_stat *info); char *chirp_statfs_string(struct chirp_statfs *info); INT64_T chirp_alloc_getxattr (const char *path, const char *name, void *data, size_t size); INT64_T chirp_alloc_fgetxattr (int fd, const char *name, void *data, size_t size); INT64_T chirp_alloc_lgetxattr (const char *path, const char *name, void *data, size_t size); INT64_T chirp_alloc_listxattr (const char *path, char *list, size_t size); INT64_T chirp_alloc_flistxattr (int fd, char *list, size_t size); INT64_T chirp_alloc_llistxattr (const char *path, char *list, size_t size); INT64_T chirp_alloc_setxattr (const char *path, const char *name, const void *data, size_t size, int flags); INT64_T chirp_alloc_fsetxattr (int fd, const char *name, const void *data, size_t size, int flags); INT64_T chirp_alloc_lsetxattr (const char *path, const char *name, const void *data, size_t size, int flags); INT64_T chirp_alloc_removexattr (const char *path, const char *name); INT64_T chirp_alloc_fremovexattr (int fd, const char *name); INT64_T chirp_alloc_lremovexattr (const char *path, const char *name); #endif cctools-4.0-source/chirp/src/chirp_audit.c0000640060042600000500000000600412175446362017512 0ustar btovardip/* Copyright (C) 2008- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include "chirp_filesystem.h" #include "chirp_audit.h" #include "chirp_protocol.h" #include "stringtools.h" #include "debug.h" #include #include #include #include #include #include static int audit_count = 0; static int get_directory_owner(const char *path, char *owner) { char aclpath[CHIRP_PATH_MAX]; char tmp[CHIRP_LINE_MAX]; char *r; CHIRP_FILE *file; int result; sprintf(aclpath, "%s/.__acl", path); file = cfs_fopen(aclpath, "r"); if(!file) return -1; r = cfs_fgets(tmp, sizeof(tmp), file); if(!r) return -1; result = sscanf(tmp, "%[^ \t\n]", owner); cfs_fclose(file); if(result == 1) { return 0; } else { return -1; } } static int chirp_audit_recursive(const char *path, struct hash_table *table) { struct chirp_dir *dir; struct chirp_dirent *d; char subpath[CHIRP_PATH_MAX]; char owner[CHIRP_PATH_MAX]; struct chirp_audit *entry; int result; result = get_directory_owner(path, owner); if(result < 0) strcpy(owner, "unknown"); entry = hash_table_lookup(table, owner); if(!entry) { entry = malloc(sizeof(*entry)); memset(entry, 0, sizeof(*entry)); strcpy(entry->name, owner); hash_table_insert(table, owner, entry); } entry->ndirs++; dir = cfs->opendir(path); if(!dir) { debug(D_LOCAL, "audit: couldn't enter %s: %s", path, strerror(errno)); return -1; } while((d = cfs->readdir(dir))) { if(!strcmp(d->name, ".")) continue; if(!strcmp(d->name, "..")) continue; if(!strncmp(d->name, ".__", 3)) continue; if(!strncmp(d->name, ".__", 3)) continue; audit_count++; if((audit_count % 10000) == 0) debug(D_LOCAL, "audit: %d items", audit_count); sprintf(subpath, "%s/%s", path, d->name); if(S_ISDIR(d->info.cst_mode)) { chirp_audit_recursive(subpath, table); } else { entry->nfiles++; entry->nbytes += d->info.cst_size; } } cfs->closedir(dir); return 0; } struct hash_table *chirp_audit(const char *path) { struct hash_table *table; time_t stop, start; int result; /* An audit can be time consuming and resource intensive, so run the audit at a low priority so as not to hurt anyone else. */ nice(10); table = hash_table_create(0, 0); if(!table) return 0; audit_count = 0; start = time(0); debug(D_LOCAL, "audit: starting"); result = chirp_audit_recursive(path, table); stop = time(0); if(stop == start) stop++; debug(D_LOCAL, "audit: completed %d items in %d seconds (%d items/sec)", audit_count, (int) (stop - start), audit_count / (stop - start)); if(result < 0) { chirp_audit_delete(table); return 0; } else { return table; } } void chirp_audit_delete(struct hash_table *table) { char *key; struct chirp_audit *entry; hash_table_firstkey(table); while(hash_table_nextkey(table, &key, (void *) &entry)) { free(hash_table_remove(table, key)); } hash_table_delete(table); } cctools-4.0-source/chirp/src/chirp_audit.h0000640060042600000500000000140312175446362017515 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ /* chirp_audit scans a local path using the chirp_local module, counting up the files, directories, and bytes consumed by each user. It returns a hash_table keyed on the user name, with each entry pointing to a chirp_audit structure. When done, the caller should send the hash table back to chirp_audit_delete. */ #ifndef CHIRP_AUDIT_H #define CHIRP_AUDIT_H #include "int_sizes.h" #include "hash_table.h" #include "chirp_client.h" struct hash_table *chirp_audit(const char *path); void chirp_audit_delete(struct hash_table *table); #endif cctools-4.0-source/chirp/src/chirp_audit_cluster0000751060042600000500000001232412175446362021037 0ustar btovardip#!/usr/bin/perl # # This tool automatically audits all hosts in a Chirp cluster # in parallel, and then produces four text reports listing the # storage consumption, by user, by host, and then for the # combination of all users and hosts. # use POSIX; print "Auditing entire Chirp cluster.\n"; $pwd=`pwd`; $nerrors=0; mkdir "/tmp/audit-$<"; print "Getting list of hosts from catalog:...\n"; $hostlist=`chirp_status -s`; @hosts = split /[ \t\n]/, $hostlist; print "Auditing $#hosts hosts in parallel, this could take a while...\n"; `multirun -d -p 100 -f /tmp/audit-$) { chomp; ($nfiles, $ndirs, $nbytes, $user) = split; if($nfiles eq "couldn't") { print "error auditing $host: $_\n"; $nerrors++; next; } $hostfiles{$host} += $nfiles; $hostdirs{$host} += $ndirs; $hostbytes{$host} += $nbytes; $hostusers{$host}++; $userfiles{$user} += $nfiles; $userdirs{$user} += $ndirs; $userbytes{$user} += $nbytes; $userhosts{$user}++; $users{$user}++; $userhostfiles{$user}{$host} += $nfiles; $userhostdirs{$user}{$host} += $ndirs; $userhostbytes{$user}{$host} += $nbytes; $hostuserfiles{$host}{$user} += $nfiles; $hostuserdirs{$host}{$user} += $ndirs; $hostuserbytes{$host}{$user} += $nbytes; $totalfiles += $nfiles; $totaldirs += $ndirs; $totalbytes += $nbytes; $totalhosts ++; } } @users = keys %users; sub sort_by_host_bytes { return $hostbytes{$b} <=> $hostbytes{$a}; } sub sort_by_user_bytes { return $userbytes{$b} <=> $userbytes{$a}; } sub sort_by_userhost_bytes { return $userhostbytes{$user}{$b} <=> $userhostbytes{$user}{$a}; } sub sort_by_hostuser_bytes { return $hostuserbytes{$host}{$b} <=> $hostuserbytes{$host}{$a}; } $totalgb = int($totalbytes/1024.0/1024.0/1024.0); $date = `date`; print "Generating audit.user.txt\n"; open FILE, ">audit.user.txt" or die; print FILE "Chirp Storage Audit by User\n"; print FILE "$date\n"; print FILE "$#users users, $#hosts hosts, $totalgb GB data, $totalfiles files, $totaldirs dirs\n"; if($nerrors) { print FILE "($nerrors hosts could not be audited)\n"; } print FILE "\n HOSTS FILES DIRS TOTAL DATA OWNER\n"; foreach $user (sort sort_by_user_bytes @users) { printf FILE "%8s %8s %8s %12.1f MB %s\n",$userhosts{$user},$userfiles{$user},$userdirs{$user},$userbytes{$user}/1048576,$user; } close FILE; print "Generating audit.host.txt\n"; open FILE, ">audit.host.txt" or die; print FILE "Chirp Storage Audit by Host\n"; print FILE "$date\n"; print FILE "$#users users, $#hosts hosts, $totalgb GB data, $totalfiles files, $totaldirs dirs\n"; if($nerrors) { print FILE "($nerrors hosts could not be audited)\n"; } print FILE "\n USERS FILES DIRS TOTAL DATA HOSTNAME\n"; foreach $host (sort sort_by_host_bytes @hosts) { next if($hostbytes{$host}==0); printf FILE "%8s %8s %8s %12.1f MB %s\n",$hostusers{$host},$hostfiles{$host},$hostdirs{$host},$hostbytes{$host}/1048576,$host; } close FILE; print "Generating audit.host.user.txt\n"; open FILE, ">audit.host.user.txt" or die; print FILE "Chirp Storage Audit by Host and User\n"; print FILE "$date\n"; print FILE "$#users users, $#hosts hosts, $totalgb GB data, $totalfiles files, $totaldirs dirs\n"; if($nerrors) { print FILE "($nerrors hosts could not be audited)\n"; } print FILE "\n USERS FILES DIRS TOTAL DATA HOSTNAME / USER\n"; foreach $host (sort sort_by_host_bytes @hosts) { next if($hostbytes{$host}==0); printf FILE "--------------------------------------------------------------------------------\n"; printf FILE "%8s %8s %8s %12.1f MB %s\n",$hostusers{$host},$hostfiles{$host},$hostdirs{$host},$hostbytes{$host}/1048576,$host; printf FILE "--------------------------------------------------------------------------------\n"; foreach $user (sort sort_by_hostuser_bytes @users) { next if($hostuserbytes{$host}{$user}==0); printf FILE "%8s %8s %8s %12.1f MB - %s\n","",$hostuserfiles{$host}{$user},$hostuserdirs{$host}{$user},$hostuserbytes{$host}{$user}/1048576,$user; } } close FILE; print "Generating audit.user.host.txt\n"; open FILE, ">audit.user.host.txt" or die; print FILE "Chirp Storage Audit by User and Host\n"; print FILE "$date\n"; print FILE "$#users users, $#hosts hosts, $totalgb GB data, $totalfiles files, $totaldirs dirs\n"; if($nerrors) { print FILE "($nerrors hosts could not be audited)\n"; } print FILE "\n HOSTS FILES DIRS TOTAL DATA USER/HOSTNAME\n"; foreach $user (sort sort_by_user_bytes @users) { next if($userbytes{$user}==0); printf FILE "--------------------------------------------------------------------------------\n"; printf FILE "%8s %8s %8s %12.1f MB %s\n",$userhosts{$user},$userfiles{$user},$userdirs{$user},$userbytes{$user}/1048576,$user; printf FILE "--------------------------------------------------------------------------------\n"; foreach $host (sort sort_by_userhost_bytes @hosts) { next if($userhostbytes{$user}{$host}==0); printf FILE "%8s %8s %8s %12.1f MB - %s\n","",$userhostfiles{$user}{$host},$userhostdirs{$user}{$host},$userhostbytes{$user}{$host}/1048576,$host; } } close FILE; print "Audit complete with $nerrors errors.\n"; cctools-4.0-source/chirp/src/chirp_benchmark.c0000640060042600000500000001160112175446362020335 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include "chirp_reli.h" #include "full_io.h" #include "auth_all.h" #include "getopt_aux.h" #include #include #include #include #include #include #include #include #include #include #ifndef CCTOOLS_OPSYS_CYGWIN #include #endif char *host; time_t stoptime; double measure[10000]; double total; double average; double variance; double stddev; int loops, cycles; int do_chirp; int measure_bandwidth = 0; #ifdef CCTOOLS_OPSYS_DARWIN #define do_sync 0 #else #define do_sync (getenv("CHIRP_SYNC") ? O_SYNC : 0) #endif long do_open(const char *file, int flags, int mode) { if(do_chirp) { return (long) chirp_reli_open(host, file, flags, mode, stoptime); } else { return open(file, flags, mode); } } int do_close(long fd) { if(do_chirp) { return chirp_reli_close((struct chirp_file *) fd, stoptime); } else { return close(fd); } } int do_fsync(long fd) { if(do_chirp) { return 0; } else { return fsync(fd); } } int do_pread(long fd, char *buffer, int length, int offset) { if(do_chirp) { return chirp_reli_pread((struct chirp_file *) fd, buffer, length, offset, stoptime); } else { return full_pread(fd, buffer, length, offset); } } int do_pwrite(long fd, const char *buffer, int length, int offset) { if(do_chirp) { return chirp_reli_pwrite((struct chirp_file *) fd, buffer, length, offset, stoptime); } else { return full_pwrite(fd, buffer, length, offset); } } int do_stat(const char *file, struct stat *buf) { if(do_chirp) { struct chirp_stat lbuf; return chirp_reli_stat(host, file, &lbuf, stoptime); } else { return stat(file, buf); } } int do_bandwidth(const char *file, int bytes, int blocksize, int do_write) { int offset = 0; long fd; char *buffer = malloc(blocksize); int i; if(!buffer) return 0; for(i = 0; i < blocksize; i++) buffer[i] = (char) i; fd = do_open(file, (do_write ? O_WRONLY : O_RDONLY) | O_CREAT | do_sync | O_TRUNC, 0777); if(fd < 0 || fd == 0) { printf("couldn't open %s: %s", file, strerror(errno)); free(buffer); return 0; } while(bytes > 0) { if(do_write) { do_pwrite(fd, buffer, blocksize, offset); } else { do_pread(fd, buffer, blocksize, offset); } offset += blocksize; bytes -= blocksize; } do_close(fd); free(buffer); return 1; } void print_total() { int j; total = 0; variance = 0; for(j = 0; j < cycles; j++) total += measure[j]; average = total / cycles; for(j = 0; j < cycles; j++) variance += (measure[j] - average) * (measure[j] - average); stddev = sqrt(variance / (cycles - 1)); printf("%9.4f +/- %9.4f ", average, stddev); if(measure_bandwidth) { printf(" MB/s\n"); } else { printf(" usec\n"); } } #define RUN_LOOP( name, test ) \ printf("%s\t",name);\ for(j=0;j \n", argv[0]); return -1; } auth_register_all(); host = argv[1]; fname = argv[2]; loops = atoi(argv[3]); cycles = atoi(argv[4]); bwloops = atoi(argv[5]); if(!strcmp(host, "unix")) { do_chirp = 0; } else { do_chirp = 1; } #ifdef SYS_getpid RUN_LOOP("getpid", syscall(SYS_getpid)); #else RUN_LOOP("getpid", getpid()); #endif fd = do_open(fname, O_WRONLY | O_CREAT | O_TRUNC | do_sync, 0777); if(fd < 0 || fd == 0) { perror(fname); return -1; } RUN_LOOP("write1", do_pwrite(fd, data, 1, 0)); RUN_LOOP("write8", do_pwrite(fd, data, 8192, 0)); do_close(fd); fd = do_open(fname, O_RDONLY | do_sync, 0777); if(fd < 0) { perror(fname); return -1; } RUN_LOOP("read1", do_pread(fd, data, 1, 0)); RUN_LOOP("read8", do_pread(fd, data, 8192, 0)); do_close(fd); RUN_LOOP("stat", do_stat(fname, &buf)); RUN_LOOP("open", fd = do_open(fname, O_RDONLY | do_sync, 0777); do_close(fd);); if(bwloops == 0) return 0; loops = bwloops; measure_bandwidth = 1; for(k = filesize; k >= (4 * 1024); k = k / 2) { printf("%4d ", k / 1024); RUN_LOOP("write", do_bandwidth(fname, filesize, k, 1)); sync(); printf("%4d ", k / 1024); RUN_LOOP("read", do_bandwidth(fname, filesize, k, 0)); sync(); } return 0; } cctools-4.0-source/chirp/src/chirp_client.c0000640060042600000500000014106712175446362017673 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #include "chirp_protocol.h" #include "chirp_client.h" #include "chirp_group.h" #include "chirp_ticket.h" #include "sleeptools.h" #include "link.h" #include "auth.h" #include "auth_hostname.h" #include "domain_name_cache.h" #include "full_io.h" #include "macros.h" #include "md5.h" #include "debug.h" #include "copy_stream.h" #include "list.h" #include "string_array.h" #include "url_encode.h" #include "xxmalloc.h" #include #include #include #include #include #include #include #include #include #ifdef HAS_SYS_STATFS_H #include #endif #include #include #include #include #include #include #include #include #include #if defined(HAS_ATTR_XATTR_H) #include #elif defined(HAS_SYS_XATTR_H) #include #endif #ifndef ENOATTR #define ENOATTR EINVAL #endif /* The maximum chunk of memory the server will allocate to handle I/O */ #define MAX_BUFFER_SIZE (16*1024*1024) static int global_serial = 0; struct chirp_client { struct link *link; char hostport[CHIRP_PATH_MAX]; int broken; int serial; }; static INT64_T convert_result(INT64_T result) { if(result >= 0) { return result; } else { switch (result) { case CHIRP_ERROR_NOT_AUTHENTICATED: case CHIRP_ERROR_NOT_AUTHORIZED: errno = EACCES; break; case CHIRP_ERROR_DOESNT_EXIST: errno = ENOENT; break; case CHIRP_ERROR_ALREADY_EXISTS: errno = EEXIST; break; case CHIRP_ERROR_TOO_BIG: errno = EFBIG; break; case CHIRP_ERROR_NO_SPACE: errno = ENOSPC; break; case CHIRP_ERROR_NO_MEMORY: errno = ENOMEM; break; case CHIRP_ERROR_INVALID_REQUEST: errno = EINVAL; break; case CHIRP_ERROR_TOO_MANY_OPEN: errno = EMFILE; break; case CHIRP_ERROR_BUSY: errno = EBUSY; break; case CHIRP_ERROR_TRY_AGAIN: errno = EAGAIN; break; case CHIRP_ERROR_NOT_DIR: errno = ENOTDIR; break; case CHIRP_ERROR_IS_DIR: errno = EISDIR; break; case CHIRP_ERROR_NOT_EMPTY: errno = ENOTEMPTY; break; case CHIRP_ERROR_CROSS_DEVICE_LINK: errno = EXDEV; break; case CHIRP_ERROR_NO_SUCH_PROCESS: errno = ESRCH; break; case CHIRP_ERROR_IS_A_PIPE: errno = ESPIPE; break; case CHIRP_ERROR_NOT_SUPPORTED: errno = ENOTSUP; break; case CHIRP_ERROR_GRP_UNREACHABLE: case CHIRP_ERROR_TIMED_OUT: case CHIRP_ERROR_DISCONNECTED: case CHIRP_ERROR_UNKNOWN: errno = ECONNRESET; break; } return -1; } } static INT64_T get_stat_result(struct chirp_client *c, struct chirp_stat *info, time_t stoptime) { char line[CHIRP_LINE_MAX]; INT64_T fields; memset(info, 0, sizeof(*info)); if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) { c->broken = 1; errno = ECONNRESET; return -1; } fields = sscanf(line, "%" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 "\n", &info->cst_dev, &info->cst_ino, &info->cst_mode, &info->cst_nlink, &info->cst_uid, &info->cst_gid, &info->cst_rdev, &info->cst_size, &info->cst_blksize, &info->cst_blocks, &info->cst_atime, &info->cst_mtime, &info->cst_ctime); info->cst_dev = -1; info->cst_rdev = 0; if(fields != 13) { c->broken = 1; errno = ECONNRESET; return -1; } return 0; } static INT64_T get_statfs_result(struct chirp_client *c, struct chirp_statfs *info, time_t stoptime) { char line[CHIRP_LINE_MAX]; INT64_T fields; memset(info, 0, sizeof(*info)); if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) { c->broken = 1; errno = ECONNRESET; return -1; } fields = sscanf(line, "%" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 " %" SCNd64 "\n", &info->f_type, &info->f_bsize, &info->f_blocks, &info->f_bfree, &info->f_bavail, &info->f_files, &info->f_ffree); if(fields != 7) { c->broken = 1; errno = ECONNRESET; return -1; } return 0; } static INT64_T get_result(struct chirp_client *c, time_t stoptime) { char line[CHIRP_LINE_MAX]; INT64_T result; INT64_T fields; if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) { c->broken = 1; errno = ECONNRESET; return -1; } fields = sscanf(line, "%" SCNd64, &result); if(fields != 1) { errno = ECONNRESET; c->broken = 1; return -1; } result = convert_result(result); if(result >= 0) { debug(D_CHIRP, " = %lld", result); } else { debug(D_CHIRP, " = %lld (%s)", result, strerror(errno)); } return result; } static INT64_T send_command_varargs(struct chirp_client *c, time_t stoptime, char const *fmt, va_list args) { INT64_T result; char command[CHIRP_LINE_MAX]; vsprintf(command, fmt, args); if(c->broken) { errno = ECONNRESET; return -1; } debug(D_CHIRP, "%s: %s", c->hostport, command); result = link_putstring(c->link, command, stoptime); if(result < 0) { c->broken = 1; errno = ECONNRESET; } return result; } static INT64_T send_command(struct chirp_client *c, time_t stoptime, char const *fmt, ...) { INT64_T result; va_list args; va_start(args, fmt); result = send_command_varargs(c, stoptime, fmt, args); va_end(args); return result; } static INT64_T simple_command(struct chirp_client *c, time_t stoptime, char const *fmt, ...) { INT64_T result; va_list args; va_start(args, fmt); result = send_command_varargs(c, stoptime, fmt, args); va_end(args); if(result >= 0) { return get_result(c, stoptime); } else { return result; } } struct chirp_client *chirp_client_connect_condor(time_t stoptime) { FILE *file; int fields; int save_errno; struct chirp_client *client; char host[CHIRP_LINE_MAX]; char hostport[CHIRP_LINE_MAX]; char cookie[CHIRP_LINE_MAX]; int port; int result; /* Older versions of Condor use chirp.config. Start with Condor V8.X the file is .chirp.config. https://htcondor-wiki.cs.wisc.edu/index.cgi/tktview?tn=3353 */ file = fopen("chirp.config", "r"); if(!file) file = fopen(".chirp.config", "r"); if(!file) return 0; fields = fscanf(file, "%s %d %s", host, &port, cookie); fclose(file); if(fields != 3) { errno = EINVAL; return 0; } sprintf(hostport, "%s:%d", host, port); client = chirp_client_connect(hostport, 0, stoptime); if(!client) return 0; result = chirp_client_cookie(client, cookie, stoptime); if(result != 0) { save_errno = errno; chirp_client_disconnect(client); errno = save_errno; return 0; } return client; } struct chirp_client *chirp_client_connect(const char *hostport, int negotiate_auth, time_t stoptime) { struct chirp_client *c; char addr[LINK_ADDRESS_MAX]; char host[DOMAIN_NAME_MAX]; int save_errno; int port; if(sscanf(hostport, "%[^:]:%d", host, &port) == 2) { /* use the split host and port */ } else { strcpy(host, hostport); port = CHIRP_PORT; } if(!domain_name_cache_lookup(host, addr)) { errno = ENOENT; return 0; } c = malloc(sizeof(*c)); if(c) { c->link = link_connect(addr, port, stoptime); c->broken = 0; c->serial = global_serial++; strcpy(c->hostport, hostport); if(c->link) { link_tune(c->link, LINK_TUNE_INTERACTIVE); if(negotiate_auth) { char *type, *subject; int result = auth_assert(c->link, &type, &subject, stoptime); if(result) { free(type); free(subject); return c; } else { chirp_client_disconnect(c); c = 0; if(time(0) >= stoptime) { errno = ECONNRESET; } else { errno = EACCES; } } } else { return c; } } save_errno = errno; free(c); errno = save_errno; } return 0; } void chirp_client_disconnect(struct chirp_client *c) { link_close(c->link); free(c); } INT64_T chirp_client_serial(struct chirp_client *c) { return c->serial; } INT64_T chirp_client_cookie(struct chirp_client * c, const char *cookie, time_t stoptime) { return simple_command(c, stoptime, "cookie %s\n", cookie); } INT64_T chirp_client_login(struct chirp_client * c, const char *name, const char *password, time_t stoptime) { return simple_command(c, stoptime, "login %s %s\n", name, password); } INT64_T chirp_client_getlongdir(struct chirp_client * c, const char *path, chirp_longdir_t callback, void *arg, time_t stoptime) { char name[CHIRP_LINE_MAX]; struct chirp_stat info; int result; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "getlongdir %s\n", safepath); if(result < 0) return result; while(link_readline(c->link, name, sizeof(name), stoptime)) { if(!name[0]) return 0; if(get_stat_result(c, &info, stoptime) >= 0) { callback(name, &info, arg); } else { break; } } c->broken = 1; errno = ECONNRESET; return -1; } INT64_T chirp_client_getdir(struct chirp_client * c, const char *path, chirp_dir_t callback, void *arg, time_t stoptime) { INT64_T result; const char *name; result = chirp_client_opendir(c, path, stoptime); if(result == 0) { while((name = chirp_client_readdir(c, stoptime))) { callback(name, arg); } } return result; } INT64_T chirp_client_opendir(struct chirp_client * c, const char *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "getdir %s\n", safepath); } const char *chirp_client_readdir(struct chirp_client *c, time_t stoptime) { static char name[CHIRP_PATH_MAX]; if(link_readline(c->link, name, sizeof(name), stoptime)) { if(name[0]) { return name; } else { return 0; } } else { c->broken = 1; errno = ECONNRESET; return 0; } } INT64_T chirp_client_getacl(struct chirp_client * c, const char *path, chirp_dir_t callback, void *arg, time_t stoptime) { INT64_T result; const char *name; result = chirp_client_openacl(c, path, stoptime); if(result == 0) { while((name = chirp_client_readacl(c, stoptime))) { callback(name, arg); } } return result; } INT64_T chirp_client_openacl(struct chirp_client * c, const char *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "getacl %s\n", safepath); } const char *chirp_client_readacl(struct chirp_client *c, time_t stoptime) { static char acl[CHIRP_PATH_MAX]; if(link_readline(c->link, acl, sizeof(acl), stoptime)) { if(acl[0]) { return acl; } else { return 0; } } else { c->broken = 1; errno = ECONNRESET; return 0; } } static int ticket_translate(const char *name, char *ticket_subject) { char command[PATH_MAX * 2 + 4096]; const char *dummy; if(chirp_ticket_isticketsubject(name, &dummy)) { strcpy(ticket_subject, name); return 1; } char *pk = xxmalloc(65536); /* max size of public key */ sprintf(command, "sed '/^\\s*#/d' < '%s' | openssl rsa -pubout 2> /dev/null", name); FILE *pkf = popen(command, "r"); int length = fread(pk, sizeof(char), 65536, pkf); if(length <= 0) { pclose(pkf); return 0; } pk[length] = 0; pclose(pkf); /* load the digest */ const char *digest = chirp_ticket_digest(pk); sprintf(ticket_subject, "ticket:%s", digest); return 1; } /* Some versions of gcc emit a silly error about the use of %c. This suppresses that error. */ static size_t my_strftime(char *str, int len, const char *fmt, struct tm *t) { return strftime(str, len, fmt, t); } INT64_T chirp_client_ticket_register(struct chirp_client * c, const char *name, const char *subject, time_t duration, time_t stoptime) { char command[PATH_MAX * 2 + 4096]; char ticket_subject[CHIRP_LINE_MAX]; FILE *shell; int status; if(access(name, R_OK) != 0) return -1; /* the 'name' argument must be a client ticket filename */ ticket_translate(name, ticket_subject); /* BEWARE: we don't bother to escape the filename, a user could * provide a malicious filename that makes us execute code we don't want to. */ sprintf(command, "if [ -r '%s' ]; then sed '/^\\s*#/d' < '%s' | openssl rsa -pubout 2> /dev/null; exit 0; else exit 1; fi", name, name); shell = popen(command, "r"); if(!shell) return -1; /* read the ticket file (public key) */ char *ticket = xxrealloc(NULL, 4096); size_t read, length = 0; while((read = fread(ticket + length, 1, 4096, shell)) > 0) { length += read; ticket = xxrealloc(ticket, length + 4096); } if(ferror(shell)) { status = pclose(shell); errno = ferror(shell); return -1; } assert(feof(shell)); status = pclose(shell); if(status) { errno = EINVAL; return -1; } if(subject == NULL) subject = "self"; INT64_T result = send_command(c, stoptime, "ticket_register %s %llu %zu\n", subject, (unsigned long long) duration, length); if(result < 0) { free(ticket); return result; } result = link_write(c->link, ticket, length, stoptime); free(ticket); if(result != (int) length) { c->broken = 1; errno = ECONNRESET; return -1; } result = get_result(c, stoptime); if(result == 0) { time_t t; struct tm tm; char now[1024]; char expiration[1024]; time(&t); localtime_r(&t, &tm); my_strftime(now, sizeof(now) / sizeof(char), "%c", &tm); t += duration; localtime_r(&t, &tm); my_strftime(expiration, sizeof(expiration) / sizeof(char), "%c", &tm); FILE *file = fopen(name, "a"); if(file == NULL) return -1; fprintf(file, "# %s: Registered with %s as \"%s\". Expires on %s\n", now, c->hostport, subject, expiration); fclose(file); } return result; } INT64_T chirp_client_ticket_create(struct chirp_client * c, char name[CHIRP_PATH_MAX], unsigned bits, time_t stoptime) { static const char command[] = "T=`mktemp`\n" "P=`mktemp`\n" "MD5=`mktemp`\n" "echo \"# Chirp Ticket\" > \"$T\"\n" "echo \"# `date`: Ticket Created.\" >> \"$T\"\n" "openssl genrsa \"$CHIRP_BITS\" >> \"$T\" 2> /dev/null\n" "sed '/^\\s*#/d' < \"$T\" | openssl rsa -pubout > \"$P\" 2> /dev/null\n" /* WARNING: openssl is *very* bad at giving sensible output. Use the last * 32 non-space characters as the MD5 sum. */ "openssl md5 < \"$P\" 2> /dev/null | tr -d '[:space:]' | tail -c 32 > \"$MD5\"\n" "if [ -z \"$CHIRP_TICKET\" ]; then\n" " CHIRP_TICKET=\"ticket.`cat $MD5`\"\n" "fi\n" "cat > \"$CHIRP_TICKET\" < \"$T\"\n" "rm -f \"$T\" \"$P\" \"$MD5\"\n" "echo \"Generated ticket $CHIRP_TICKET.\" 1>&2\n" "echo -n \"$CHIRP_TICKET\"\n"; int result = 0; if(strlen(name) == 0) unsetenv("CHIRP_TICKET"); else result = setenv("CHIRP_TICKET", name, 1); if(result == -1) return -1; char bits_s[32]; sprintf(bits_s, "%u", bits); result = setenv("CHIRP_BITS", bits_s, 1); if(result == -1) return -1; memset(name, 0, CHIRP_PATH_MAX); FILE *shell = popen(command, "r"); if(shell == NULL) return -1; ssize_t read; char *buffer = name; while((read = full_fread(shell, buffer, sizeof(name) - 1 - (name - buffer))) > 0) buffer += read; pclose(shell); if((buffer - name) <= 0) { errno = EINVAL; return -1; } return 0; } INT64_T chirp_client_ticket_delete(struct chirp_client * c, const char *name, time_t stoptime) { char ticket_subject[CHIRP_LINE_MAX]; ticket_translate(name, ticket_subject); INT64_T result = simple_command(c, stoptime, "ticket_delete %s\n", ticket_subject); if(result == 0) { unlink(name); } return result; } INT64_T chirp_client_ticket_get(struct chirp_client * c, const char *name, char **subject, char **ticket, time_t * duration, char ***rights, time_t stoptime) { INT64_T result; char ticket_subject[CHIRP_LINE_MAX]; *subject = *ticket = NULL; *rights = NULL; ticket_translate(name, ticket_subject); result = simple_command(c, stoptime, "ticket_get %s\n", ticket_subject); if(result == 0) { char line[CHIRP_LINE_MAX]; size_t length; size_t nrights = 0; if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) goto failure; if(sscanf(line, "%zu", &length) != 1) goto failure; *subject = xxmalloc((length + 1) * sizeof(char)); if(!link_read(c->link, *subject, length, stoptime)) goto failure; (*subject)[length] = '\0'; if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) goto failure; if(sscanf(line, "%zu", &length) != 1) goto failure; *ticket = xxmalloc((length + 1) * sizeof(char)); if(!link_read(c->link, *ticket, length, stoptime)) goto failure; (*ticket)[length] = '\0'; if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) goto failure; unsigned long long tmp; if(sscanf(line, "%llu", &tmp) != 1) goto failure; *duration = (time_t) tmp; while(1) { char path[CHIRP_PATH_MAX]; char acl[CHIRP_LINE_MAX]; if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) goto failure; if(sscanf(line, "%s %s", path, acl) == 2) { *rights = xxrealloc(*rights, sizeof(char *) * 2 * (nrights + 2)); (*rights)[nrights * 2 + 0] = xxstrdup(path); (*rights)[nrights * 2 + 1] = xxstrdup(acl); (*rights)[nrights * 2 + 2] = NULL; (*rights)[nrights * 2 + 3] = NULL; nrights++; } else if(sscanf(line, "%" SCNd64, &result) == 1 && result == 0) { break; } else goto failure; } return 0; failure: free(*subject); free(*ticket); if(*rights != NULL) { char **tmp = *rights; while(tmp[0] && tmp[1]) { free(tmp[0]); free(tmp[1]); } free(*rights); } *subject = *ticket = NULL; c->broken = 1; errno = ECONNRESET; return -1; } return result; } INT64_T chirp_client_ticket_list(struct chirp_client * c, const char *subject, char ***list, time_t stoptime) { INT64_T result; size_t size = 0; *list = NULL; result = simple_command(c, stoptime, "ticket_list %s\n", subject); if(result == 0) { while(1) { char line[CHIRP_LINE_MAX]; size_t length; if(!link_readline(c->link, line, CHIRP_LINE_MAX, stoptime)) goto failure; if(sscanf(line, "%zu", &length) != 1) goto failure; if(length == 0) break; size++; *list = xxrealloc(*list, sizeof(char *) * (size + 1)); (*list)[size - 1] = xxmalloc(sizeof(char) * (length + 1)); if(!link_read(c->link, (*list)[size - 1], length, stoptime)) goto failure; (*list)[size - 1][length] = '\0'; (*list)[size] = NULL; } return 0; failure: if(*list != NULL) { char **tmp = *list; while(tmp[0]) { free(tmp[0]); } free(*list); } c->broken = 1; errno = ECONNRESET; return -1; } return result; } INT64_T chirp_client_ticket_modify(struct chirp_client * c, const char *name, const char *path, const char *aclmask, time_t stoptime) { char ticket_subject[CHIRP_LINE_MAX]; char safepath[CHIRP_LINE_MAX]; ticket_translate(name, ticket_subject); url_encode(path, safepath, sizeof(safepath)); INT64_T result = simple_command(c, stoptime, "ticket_modify %s %s %s\n", ticket_subject, safepath, aclmask); if(result == 0) { time_t t; struct tm tm; char now[1024]; time(&t); localtime_r(&t, &tm); my_strftime(now, sizeof(now) / sizeof(char), "%c", &tm); FILE *file = fopen(name, "a"); if(file == NULL) return -1; fprintf(file, "# %s: Set ACL Mask on %s directory = '%s' mask = '%s'.\n", now, c->hostport, path, aclmask); fclose(file); } return result; } INT64_T chirp_client_setacl(struct chirp_client * c, const char *path, const char *user, const char *acl, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "setacl %s %s %s\n", safepath, user, acl); } INT64_T chirp_client_resetacl(struct chirp_client * c, const char *path, const char *acl, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "resetacl %s %s\n", safepath, acl); } INT64_T chirp_client_locate(struct chirp_client * c, const char *path, chirp_loc_t callback, void *arg, time_t stoptime) { char location[CHIRP_PATH_MAX]; char host[CHIRP_PATH_MAX]; sscanf(c->hostport, "%[^:]%*s", host); snprintf(location, CHIRP_PATH_MAX, "%s:%s", host, path); callback(location, arg); return 1; } INT64_T chirp_client_open(struct chirp_client * c, const char *path, INT64_T flags, INT64_T mode, struct chirp_stat * info, time_t stoptime) { INT64_T result; char fstr[256]; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); fstr[0] = 0; if(flags & O_WRONLY) { strcat(fstr, "w"); } else if(flags & O_RDWR) { strcat(fstr, "rw"); } else { strcat(fstr, "r"); } if(flags & O_CREAT) strcat(fstr, "c"); if(flags & O_TRUNC) strcat(fstr, "t"); if(flags & O_APPEND) strcat(fstr, "a"); if(flags & O_EXCL) strcat(fstr, "x"); #ifdef O_SYNC if(flags & O_SYNC) strcat(fstr, "s"); #endif result = simple_command(c, stoptime, "open %s %s %lld\n", safepath, fstr, mode); if(result >= 0) { if(get_stat_result(c, info, stoptime) >= 0) { return result; } else { c->broken = 1; errno = ECONNRESET; return -1; } } else { return result; } } INT64_T chirp_client_close(struct chirp_client * c, INT64_T fd, time_t stoptime) { return simple_command(c, stoptime, "close %lld\n", fd); } INT64_T chirp_client_pread_begin(struct chirp_client * c, INT64_T fd, void *buffer, INT64_T length, INT64_T offset, time_t stoptime) { return send_command(c, stoptime, "pread %lld %lld %lld\n", fd, length, offset); } INT64_T chirp_client_pread_finish(struct chirp_client * c, INT64_T fd, void *buffer, INT64_T length, INT64_T offset, time_t stoptime) { INT64_T result; INT64_T actual; result = get_result(c, stoptime); if(result > 0) { actual = link_read(c->link, buffer, result, stoptime); if(actual != result) { errno = ECONNRESET; return -1; } } return result; } INT64_T chirp_client_pread(struct chirp_client * c, INT64_T fd, void *buffer, INT64_T length, INT64_T offset, time_t stoptime) { INT64_T result = chirp_client_pread_begin(c, fd, buffer, length, offset, stoptime); if(result < 0) return result; return chirp_client_pread_finish(c, fd, buffer, length, offset, stoptime); } INT64_T chirp_client_sread_begin(struct chirp_client * c, INT64_T fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime) { return send_command(c, stoptime, "sread %lld %lld %lld %lld %lld\n", fd, length, stride_length, stride_skip, offset); } INT64_T chirp_client_sread_finish(struct chirp_client * c, INT64_T fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime) { INT64_T result; INT64_T actual; result = get_result(c, stoptime); if(result > 0) { actual = link_read(c->link, buffer, result, stoptime); if(actual != result) { errno = ECONNRESET; return -1; } } return result; } INT64_T chirp_client_sread(struct chirp_client * c, INT64_T fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime) { INT64_T result = chirp_client_sread_begin(c, fd, buffer, length, stride_length, stride_skip, offset, stoptime); if(result < 0) return result; return chirp_client_sread_finish(c, fd, buffer, length, stride_length, stride_skip, offset, stoptime); } INT64_T chirp_client_getfile(struct chirp_client * c, const char *path, FILE * stream, time_t stoptime) { INT64_T length; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); length = simple_command(c, stoptime, "getfile %s\n", safepath); if(length >= 0) { if(link_stream_to_file(c->link, stream, length, stoptime) == length) { return length; } else { c->broken = 1; errno = ECONNRESET; } } return -1; } INT64_T chirp_client_getfile_buffer(struct chirp_client * c, const char *path, char **buffer, time_t stoptime) { INT64_T length; INT64_T result; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); *buffer = 0; length = simple_command(c, stoptime, "getfile %s\n", safepath); if(length <= 0) return length; *buffer = malloc(length + 1); if(!*buffer) { c->broken = 1; errno = ENOMEM; return -1; } result = link_read(c->link, *buffer, length, stoptime); if(result < 0) { free(*buffer); c->broken = 1; return -1; } (*buffer)[length] = 0; return result; } INT64_T chirp_client_readlink(struct chirp_client * c, const char *path, char *buffer, INT64_T length, time_t stoptime) { INT64_T result; INT64_T actual; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "readlink %s %lld\n", safepath, length); if(result > 0) { actual = link_read(c->link, buffer, result, stoptime); if(actual != result) { c->broken = 1; errno = ECONNRESET; return -1; } } return result; } INT64_T chirp_client_localpath(struct chirp_client * c, const char *path, char *localpath, int length, time_t stoptime) { INT64_T result; INT64_T actual; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "localpath %s\n", path); if(result > 0) { actual = link_read(c->link, localpath, result, stoptime); if(actual != result) { c->broken = 1; errno = ECONNRESET; return -1; } } return result; } INT64_T chirp_client_whoami(struct chirp_client * c, char *buffer, INT64_T length, time_t stoptime) { INT64_T result; INT64_T actual; result = simple_command(c, stoptime, "whoami %lld\n", length); if(result > 0) { actual = link_read(c->link, buffer, result, stoptime); if(actual != result) { c->broken = 1; errno = ECONNRESET; return -1; } buffer[actual] = 0; } return result; } INT64_T chirp_client_whoareyou(struct chirp_client * c, const char *rhost, char *buffer, INT64_T length, time_t stoptime) { INT64_T result; INT64_T actual; result = simple_command(c, stoptime, "whoareyou %s %lld\n", rhost, length); if(result > 0) { actual = link_read(c->link, buffer, result, stoptime); if(actual != result) { c->broken = 1; errno = ECONNRESET; return -1; } } return result; } INT64_T chirp_client_pwrite_begin(struct chirp_client * c, INT64_T fd, const void *buffer, INT64_T length, INT64_T offset, time_t stoptime) { INT64_T result; if(length > MAX_BUFFER_SIZE) length = MAX_BUFFER_SIZE; result = send_command(c, stoptime, "pwrite %lld %lld %lld\n", fd, length, offset); if(result < 0) return result; result = link_putlstring(c->link, buffer, length, stoptime); if(result != length) { c->broken = 1; errno = ECONNRESET; return -1; } return result; } INT64_T chirp_client_pwrite_finish(struct chirp_client * c, INT64_T fd, const void *buffer, INT64_T length, INT64_T offset, time_t stoptime) { return get_result(c, stoptime); } INT64_T chirp_client_pwrite(struct chirp_client * c, INT64_T fd, const void *buffer, INT64_T length, INT64_T offset, time_t stoptime) { INT64_T result = chirp_client_pwrite_begin(c, fd, buffer, length, offset, stoptime); if(result < 0) return result; return chirp_client_pwrite_finish(c, fd, buffer, length, offset, stoptime); } INT64_T chirp_client_swrite_begin(struct chirp_client * c, INT64_T fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime) { INT64_T result; if(length > MAX_BUFFER_SIZE) length = MAX_BUFFER_SIZE; result = send_command(c, stoptime, "swrite %lld %lld %lld %lld %lld\n", fd, length, stride_length, stride_skip, offset); if(result < 0) return result; result = link_putlstring(c->link, buffer, length, stoptime); if(result != length) { c->broken = 1; errno = ECONNRESET; return -1; } return result; } INT64_T chirp_client_swrite_finish(struct chirp_client * c, INT64_T fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime) { return get_result(c, stoptime); } INT64_T chirp_client_swrite(struct chirp_client * c, INT64_T fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime) { INT64_T result = chirp_client_swrite_begin(c, fd, buffer, length, stride_length, stride_skip, offset, stoptime); if(result < 0) return result; return chirp_client_swrite_finish(c, fd, buffer, length, stride_length, stride_skip, offset, stoptime); } INT64_T chirp_client_putfile(struct chirp_client * c, const char *path, FILE * stream, INT64_T mode, INT64_T length, time_t stoptime) { INT64_T result; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "putfile %s %lld %lld\n", safepath, mode, length); if(result < 0) return result; result = link_stream_from_file(c->link, stream, length, stoptime); if(result != length) { c->broken = 1; errno = ECONNRESET; return -1; } return get_result(c, stoptime); } INT64_T chirp_client_putfile_buffer(struct chirp_client * c, const char *path, const char *buffer, INT64_T mode, INT64_T length, time_t stoptime) { INT64_T result; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "putfile %s %lld %lld\n", safepath, mode, length); if(result < 0) return result; result = link_putlstring(c->link, buffer, length, stoptime); if(result != length) { c->broken = 1; errno = ECONNRESET; return -1; } return get_result(c, stoptime); } INT64_T chirp_client_getstream(struct chirp_client * c, const char *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "getstream %s\n", path); } INT64_T chirp_client_getstream_read(struct chirp_client * c, void *buffer, INT64_T length, time_t stoptime) { return link_read_avail(c->link, buffer, length, stoptime); } INT64_T chirp_client_putstream(struct chirp_client * c, const char *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "putstream %s\n", path); } INT64_T chirp_client_putstream_write(struct chirp_client * c, const char *data, INT64_T length, time_t stoptime) { return link_putlstring(c->link, data, length, stoptime); } INT64_T chirp_client_thirdput(struct chirp_client * c, const char *path, const char *hostname, const char *newpath, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; char safenewpath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); url_encode(newpath, safenewpath, sizeof(safenewpath)); return simple_command(c, stoptime, "thirdput %s %s %s\n", safepath, hostname, safenewpath); } INT64_T chirp_client_fchmod(struct chirp_client * c, INT64_T fd, INT64_T mode, time_t stoptime) { return simple_command(c, stoptime, "fchmod %lld %lld\n", fd, mode); } INT64_T chirp_client_fchown(struct chirp_client * c, INT64_T fd, INT64_T uid, INT64_T gid, time_t stoptime) { return simple_command(c, stoptime, "fchown %lld %lld %lld\n", fd, uid, gid); } INT64_T chirp_client_ftruncate(struct chirp_client * c, INT64_T fd, INT64_T length, time_t stoptime) { return simple_command(c, stoptime, "ftruncate %lld %lld\n", fd, length); } INT64_T chirp_client_fstat_begin(struct chirp_client * c, INT64_T fd, struct chirp_stat * info, time_t stoptime) { return send_command(c, stoptime, "fstat %lld\n", fd); } INT64_T chirp_client_fstat_finish(struct chirp_client * c, INT64_T fd, struct chirp_stat * info, time_t stoptime) { INT64_T result = get_result(c, stoptime); if(result >= 0) return get_stat_result(c, info, stoptime); return result; } INT64_T chirp_client_fstat(struct chirp_client * c, INT64_T fd, struct chirp_stat * info, time_t stoptime) { INT64_T result = chirp_client_fstat_begin(c, fd, info, stoptime); if(result >= 0) return chirp_client_fstat_finish(c, fd, info, stoptime); return result; } INT64_T chirp_client_stat(struct chirp_client * c, const char *path, struct chirp_stat * info, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = simple_command(c, stoptime, "stat %s\n", safepath); if(result >= 0) result = get_stat_result(c, info, stoptime); return result; } INT64_T chirp_client_lstat(struct chirp_client * c, const char *path, struct chirp_stat * info, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = simple_command(c, stoptime, "lstat %s\n", safepath); if(result >= 0) result = get_stat_result(c, info, stoptime); return result; } INT64_T chirp_client_fstatfs(struct chirp_client * c, INT64_T fd, struct chirp_statfs * info, time_t stoptime) { INT64_T result = simple_command(c, stoptime, "fstatfs %lld\n", fd); if(result >= 0) result = get_statfs_result(c, info, stoptime); return result; } INT64_T chirp_client_statfs(struct chirp_client * c, const char *path, struct chirp_statfs * info, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = simple_command(c, stoptime, "statfs %s\n", safepath); if(result >= 0) result = get_statfs_result(c, info, stoptime); return result; } INT64_T chirp_client_mkfifo(struct chirp_client * c, const char *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "mkfifo %s\n", safepath); } INT64_T chirp_client_unlink(struct chirp_client * c, const char *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "unlink %s\n", safepath); } INT64_T chirp_client_rename(struct chirp_client * c, const char *oldpath, const char *newpath, time_t stoptime) { char safeoldpath[CHIRP_LINE_MAX]; char safenewpath[CHIRP_LINE_MAX]; url_encode(oldpath, safeoldpath, sizeof(safeoldpath)); url_encode(newpath, safenewpath, sizeof(safenewpath)); return simple_command(c, stoptime, "rename %s %s\n", safeoldpath, safenewpath); } INT64_T chirp_client_link(struct chirp_client * c, const char *oldpath, const char *newpath, time_t stoptime) { char safeoldpath[CHIRP_LINE_MAX]; char safenewpath[CHIRP_LINE_MAX]; url_encode(oldpath, safeoldpath, sizeof(safeoldpath)); url_encode(newpath, safenewpath, sizeof(safenewpath)); return simple_command(c, stoptime, "link %s %s\n", safeoldpath, safenewpath); } INT64_T chirp_client_symlink(struct chirp_client * c, const char *oldpath, const char *newpath, time_t stoptime) { char safeoldpath[CHIRP_LINE_MAX]; char safenewpath[CHIRP_LINE_MAX]; url_encode(oldpath, safeoldpath, sizeof(safeoldpath)); url_encode(newpath, safenewpath, sizeof(safenewpath)); debug(D_CHIRP, "symlink %s %s", safeoldpath, safenewpath); return simple_command(c, stoptime, "symlink %s %s\n", safeoldpath, safenewpath); } INT64_T chirp_client_fsync_begin(struct chirp_client * c, INT64_T fd, time_t stoptime) { return send_command(c, stoptime, "fsync %lld\n", fd); } INT64_T chirp_client_fsync_finish(struct chirp_client * c, INT64_T fd, time_t stoptime) { return get_result(c, stoptime); } INT64_T chirp_client_fsync(struct chirp_client * c, INT64_T fd, time_t stoptime) { INT64_T result = chirp_client_fsync_begin(c, fd, stoptime); if(result >= 0) return get_result(c, stoptime); return result; } INT64_T chirp_client_mkdir(struct chirp_client * c, char const *path, INT64_T mode, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "mkdir %s %lld\n", safepath, mode); } INT64_T chirp_client_rmdir(struct chirp_client * c, char const *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "rmdir %s\n", safepath); } INT64_T chirp_client_rmall(struct chirp_client * c, char const *path, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "rmall %s\n", safepath); } INT64_T chirp_client_truncate(struct chirp_client * c, char const *path, INT64_T length, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "truncate %s %lld\n", safepath, length); } INT64_T chirp_client_utime(struct chirp_client * c, char const *path, time_t actime, time_t modtime, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "utime %s %u %u\n", safepath, actime, modtime); } INT64_T chirp_client_access(struct chirp_client * c, char const *path, INT64_T mode, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "access %s %lld\n", safepath, mode); } INT64_T chirp_client_chmod(struct chirp_client * c, char const *path, INT64_T mode, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "chmod %s %lld\n", safepath, mode); } INT64_T chirp_client_chown(struct chirp_client * c, char const *path, INT64_T uid, INT64_T gid, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "chown %s %lld %lld\n", safepath, uid, gid); } INT64_T chirp_client_lchown(struct chirp_client * c, char const *path, INT64_T uid, INT64_T gid, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "lchown %s %lld %lld\n", safepath, uid, gid); } INT64_T chirp_client_md5(struct chirp_client * c, const char *path, unsigned char digest[16], time_t stoptime) { INT64_T result; INT64_T actual; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "md5 %s\n", path); if(result == 16) { actual = link_read(c->link, (char *) digest, 16, stoptime); if(actual != result) { errno = ECONNRESET; result = -1; } } else if(result >= 0) { result = -1; errno = ECONNRESET; } return result; } INT64_T chirp_client_setrep(struct chirp_client * c, char const *path, int nreps, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "setrep %s %d\n", safepath, nreps); } INT64_T chirp_client_remote_debug(struct chirp_client * c, const char *flag, time_t stoptime) { if(flag == NULL) flag = "*"; return simple_command(c, stoptime, "debug %s\n", flag); } INT64_T chirp_client_audit(struct chirp_client * c, const char *path, struct chirp_audit ** list, time_t stoptime) { INT64_T result; struct chirp_audit *entry; int i, actual; char line[CHIRP_LINE_MAX]; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "audit %s\n", safepath); if(result <= 0) return result; *list = malloc(sizeof(struct chirp_audit) * result); entry = *list; for(i = 0; i < result; i++) { actual = link_readline(c->link, line, sizeof(line), stoptime); if(actual <= 0) { free(*list); result = -1; errno = ECONNRESET; break; } else { sscanf(line, "%s %" SCNd64 " %" SCNd64 " %" SCNd64, entry->name, &entry->nfiles, &entry->ndirs, &entry->nbytes); } entry++; } return result; } INT64_T chirp_client_mkalloc(struct chirp_client * c, char const *path, INT64_T size, INT64_T mode, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); return simple_command(c, stoptime, "mkalloc %s %lld %lld\n", safepath, size, mode); } INT64_T chirp_client_lsalloc(struct chirp_client * c, char const *path, char *allocpath, INT64_T * total, INT64_T * inuse, time_t stoptime) { int result; char line[CHIRP_LINE_MAX]; char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); result = simple_command(c, stoptime, "lsalloc %s\n", safepath); if(result == 0) { if(link_readline(c->link, line, sizeof(line), stoptime)) { sscanf(line, "%s %" SCNd64 " %" SCNd64, allocpath, total, inuse); } else { c->broken = 1; errno = ECONNRESET; result = -1; } } return result; } CHIRP_SEARCH *chirp_client_opensearch(struct chirp_client * c, const char *path, const char *pattern, int flags, time_t stoptime) { INT64_T result = simple_command(c, stoptime, "search %s %s %d\n", pattern, path, flags); if(result == 0) { char line[CHIRP_LINE_MAX]; buffer_t *buffer; size_t n = 0; buffer = buffer_create(); while(link_readline(c->link, line, sizeof(line), stoptime) && line[0]) { buffer_printf(buffer, "%s", line); n += strlen(line); } if(n == 0) { buffer_printf(buffer, ""); } CHIRP_SEARCH *result = malloc(sizeof(CHIRP_SEARCH)); result->buffer = buffer; result->current = buffer_tostring(buffer, NULL); return result; } else { return NULL; } } static const char *search_readnext(const char *current, char **result) { *result = NULL; if(strlen(current)) { ptrdiff_t length; const char *tail = strchr(current, ':'); if(tail) length = tail - current; else length = strlen(current); *result = xxmalloc(length + 1); strncpy(*result, current, length); (*result)[length] = '\0'; return current + length + 1; } return NULL; } static void search_unpackstat(const char *str, struct chirp_stat *info) { sscanf(str, "%" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " " "%" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " %" PRId64 " " "%" PRId64 " %" PRId64 " %" PRId64, &info->cst_dev, &info->cst_ino, &info->cst_mode, &info->cst_nlink, &info->cst_uid, &info->cst_gid, &info->cst_rdev, &info->cst_size, &info->cst_atime, &info->cst_mtime, &info->cst_ctime, &info->cst_blksize, &info->cst_blocks); } struct chirp_searchent *chirp_client_readsearch(CHIRP_SEARCH * search) { char *result; const char *current = search_readnext(search->current, &result); if(current && result) { search->entry.err = atoi(result); free(result); if(search->entry.err) { current = search_readnext(current, &result); assert(current && result); search->entry.errsource = atoi(result); free(result); current = search_readnext(current, &result); assert(current && result); memset(search->entry.path, 0, CHIRP_PATH_MAX); strncpy(search->entry.path, result, CHIRP_PATH_MAX - 1); free(result); memset(&search->entry.info, 0, sizeof(search->entry.info)); } else { search->entry.errsource = 0; current = search_readnext(current, &result); assert(current && result); memset(search->entry.path, 0, CHIRP_PATH_MAX); strncpy(search->entry.path, result, CHIRP_PATH_MAX - 1); free(result); current = search_readnext(current, &result); assert(current && result); memset(&search->entry.info, 0, sizeof(search->entry.info)); search_unpackstat(current, &search->entry.info); free(result); } search->current = current; return &search->entry; } return NULL; } int chirp_client_closesearch(CHIRP_SEARCH * search) { buffer_delete(search->buffer); free(search); return 0; } INT64_T chirp_client_getxattr(struct chirp_client * c, const char *path, const char *name, void *data, size_t size, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = send_command(c, stoptime, "getxattr %s %s\n", safepath, name); if(result < 0) return result; result = get_result(c, stoptime); if(result < 0) { if(errno == EINVAL) errno = ENOATTR; return result; } else if(result > (int) size) { link_soak(c->link, result, stoptime); errno = ERANGE; return result; } if(!link_read(c->link, data, result, stoptime)) { return -1; } return result; } INT64_T chirp_client_fgetxattr(struct chirp_client * c, INT64_T fd, const char *name, void *data, size_t size, time_t stoptime) { INT64_T result = send_command(c, stoptime, "fgetxattr %lld %s\n", fd, name); if(result < 0) return result; result = get_result(c, stoptime); if(result < 0) { if(errno == EINVAL) errno = ENOATTR; return result; } else if(result > (int) size) { link_soak(c->link, result, stoptime); errno = ERANGE; return result; } if(!link_read(c->link, data, result, stoptime)) { return -1; } return result; } INT64_T chirp_client_lgetxattr(struct chirp_client * c, const char *path, const char *name, void *data, size_t size, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = send_command(c, stoptime, "lgetxattr %s %s\n", safepath, name); if(result < 0) return result; result = get_result(c, stoptime); if(result < 0) { if(errno == EINVAL) errno = ENOATTR; return result; } else if(result > (int) size) { link_soak(c->link, result, stoptime); errno = ERANGE; return result; } if(!link_read(c->link, data, result, stoptime)) { return -1; } return result; } INT64_T chirp_client_listxattr(struct chirp_client * c, const char *path, char *list, size_t size, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = send_command(c, stoptime, "listxattr %s\n", safepath); if(result < 0) return result; result = get_result(c, stoptime); if(result < 0) return result; if(result > (int) size) { link_soak(c->link, result, stoptime); errno = ERANGE; return result; } if(!link_read(c->link, list, result, stoptime)) { return -1; } return result; } INT64_T chirp_client_flistxattr(struct chirp_client * c, INT64_T fd, char *list, size_t size, time_t stoptime) { INT64_T result = send_command(c, stoptime, "flistxattr %lld\n", fd); if(result < 0) return result; result = get_result(c, stoptime); if(result < 0) return result; if(result > (int) size) { link_soak(c->link, result, stoptime); errno = ERANGE; return result; } if(!link_read(c->link, list, result, stoptime)) { return -1; } return result; } INT64_T chirp_client_llistxattr(struct chirp_client * c, const char *path, char *list, size_t size, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = send_command(c, stoptime, "llistxattr %s\n", safepath); if(result < 0) return result; result = get_result(c, stoptime); if(result < 0) return result; if(result > (int) size) { link_soak(c->link, result, stoptime); errno = ERANGE; return result; } if(!link_read(c->link, list, result, stoptime)) { return -1; } return result; } INT64_T chirp_client_setxattr(struct chirp_client * c, const char *path, const char *name, const void *data, size_t size, int flags, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = send_command(c, stoptime, "setxattr %s %s %zu %d\n", safepath, name, size, flags); if(result < 0) return result; result = link_putlstring(c->link, data, size, stoptime); if(result != (int) size) { c->broken = 1; errno = ECONNRESET; return -1; } result = get_result(c, stoptime); if(result < 0) { if(errno == EINVAL) errno = ENOATTR; return result; } return 0; } INT64_T chirp_client_fsetxattr(struct chirp_client * c, INT64_T fd, const char *name, const void *data, size_t size, int flags, time_t stoptime) { INT64_T result = send_command(c, stoptime, "fsetxattr %s %s %zu %d\n", fd, name, size, flags); if(result < 0) return result; result = link_putlstring(c->link, data, size, stoptime); if(result != (int) size) { c->broken = 1; errno = ECONNRESET; return -1; } result = get_result(c, stoptime); if(result < 0) { if(errno == EINVAL) errno = ENOATTR; return result; } return 0; } INT64_T chirp_client_lsetxattr(struct chirp_client * c, const char *path, const char *name, const void *data, size_t size, int flags, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = send_command(c, stoptime, "lsetxattr %s %s %zu %d\n", safepath, name, size, flags); if(result < 0) return result; result = link_putlstring(c->link, data, size, stoptime); if(result != (int) size) { c->broken = 1; errno = ECONNRESET; return -1; } result = get_result(c, stoptime); if(result < 0) { if(errno == EINVAL) errno = ENOATTR; return result; } return 0; } INT64_T chirp_client_removexattr(struct chirp_client * c, const char *path, const char *name, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = simple_command(c, stoptime, "removexattr %s %s\n", safepath, name); if(result == -1 && errno == EINVAL) errno = ENOATTR; return result; } INT64_T chirp_client_fremovexattr(struct chirp_client * c, INT64_T fd, const char *name, time_t stoptime) { INT64_T result = simple_command(c, stoptime, "fremovexattr %lld %s\n", fd, name); if(result == -1 && errno == EINVAL) errno = ENOATTR; return result; } INT64_T chirp_client_lremovexattr(struct chirp_client * c, const char *path, const char *name, time_t stoptime) { char safepath[CHIRP_LINE_MAX]; url_encode(path, safepath, sizeof(safepath)); INT64_T result = simple_command(c, stoptime, "lremovexattr %s %s\n", safepath, name); if(result == -1 && errno == EINVAL) errno = ENOATTR; return result; } cctools-4.0-source/chirp/src/chirp_client.h0000640060042600000500000002635612175446362017703 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ #ifndef CHIRP_CLIENT_H #define CHIRP_CLIENT_H #include "int_sizes.h" #include "chirp_protocol.h" #include "chirp_types.h" #include #include #include #include /* Authentication Environment Variable */ #define CHIRP_CLIENT_TICKETS "CHIRP_CLIENT_TICKETS" struct chirp_client *chirp_client_connect(const char *host, int negotiate_auth, time_t stoptime); struct chirp_client *chirp_client_connect_condor(time_t stoptime); void chirp_client_disconnect(struct chirp_client *c); INT64_T chirp_client_serial(struct chirp_client *c); INT64_T chirp_client_open(struct chirp_client *c, const char *path, INT64_T flags, INT64_T mode, struct chirp_stat *buf, time_t stoptime); INT64_T chirp_client_close(struct chirp_client *c, INT64_T fd, time_t stoptime); INT64_T chirp_client_pread(struct chirp_client *c, INT64_T fd, void *buffer, INT64_T length, INT64_T offset, time_t stoptime); INT64_T chirp_client_pwrite(struct chirp_client *c, INT64_T fd, const void *buffer, INT64_T length, INT64_T offset, time_t stoptime); INT64_T chirp_client_sread(struct chirp_client *c, INT64_T fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime); INT64_T chirp_client_swrite(struct chirp_client *c, INT64_T fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime); INT64_T chirp_client_fsync(struct chirp_client *c, INT64_T fd, time_t stoptime); INT64_T chirp_client_fstat(struct chirp_client *c, INT64_T fd, struct chirp_stat *buf, time_t stoptime); INT64_T chirp_client_fstatfs(struct chirp_client *c, INT64_T fd, struct chirp_statfs *buf, time_t stoptime); INT64_T chirp_client_fchown(struct chirp_client *c, INT64_T fd, INT64_T uid, INT64_T gid, time_t stoptime); INT64_T chirp_client_fchmod(struct chirp_client *c, INT64_T fd, INT64_T mode, time_t stoptime); INT64_T chirp_client_ftruncate(struct chirp_client *c, INT64_T fd, INT64_T length, time_t stoptime); INT64_T chirp_client_getfile(struct chirp_client *c, const char *name, FILE * stream, time_t stoptime); INT64_T chirp_client_getfile_buffer(struct chirp_client *c, const char *name, char **buffer, time_t stoptime); INT64_T chirp_client_putfile(struct chirp_client *c, const char *name, FILE * stream, INT64_T mode, INT64_T length, time_t stoptime); INT64_T chirp_client_putfile_buffer(struct chirp_client *c, const char *name, const char *buffer, INT64_T mode, INT64_T length, time_t stoptime); INT64_T chirp_client_thirdput(struct chirp_client *c, const char *path, const char *hostname, const char *newpath, time_t stoptime); INT64_T chirp_client_getstream(struct chirp_client *c, const char *path, time_t stoptime); INT64_T chirp_client_getstream_read(struct chirp_client *c, void *buffer, INT64_T length, time_t stoptime); INT64_T chirp_client_putstream(struct chirp_client *c, const char *path, time_t stoptime); INT64_T chirp_client_putstream_write(struct chirp_client *c, const char *data, INT64_T length, time_t stoptime); INT64_T chirp_client_cookie(struct chirp_client *c, const char *cookie, time_t stoptime); CHIRP_SEARCH *chirp_client_opensearch(struct chirp_client *c, const char *paths, const char *pattern, int flags, time_t stoptime); struct chirp_searchent *chirp_client_readsearch(CHIRP_SEARCH *search); int chirp_client_closesearch(CHIRP_SEARCH *search); INT64_T chirp_client_getlongdir(struct chirp_client *c, const char *path, chirp_longdir_t callback, void *arg, time_t stoptime); INT64_T chirp_client_getdir(struct chirp_client *c, const char *path, chirp_dir_t callback, void *arg, time_t stoptime); INT64_T chirp_client_opendir(struct chirp_client *c, const char *path, time_t stoptime); const char *chirp_client_readdir(struct chirp_client *c, time_t stoptime); INT64_T chirp_client_getacl(struct chirp_client *c, const char *path, chirp_dir_t callback, void *arg, time_t stoptime); INT64_T chirp_client_openacl(struct chirp_client *c, const char *path, time_t stoptime); const char *chirp_client_readacl(struct chirp_client *c, time_t stoptime); INT64_T chirp_client_ticket_create(struct chirp_client *c, char name[CHIRP_PATH_MAX], unsigned bits, time_t stoptime); INT64_T chirp_client_ticket_register(struct chirp_client *c, const char *name, const char *subject, time_t duration, time_t stoptime); INT64_T chirp_client_ticket_delete(struct chirp_client *c, const char *name, time_t stoptime); INT64_T chirp_client_ticket_list(struct chirp_client *c, const char *subject, char ***list, time_t stoptime); INT64_T chirp_client_ticket_get(struct chirp_client *c, const char *name, char **subject, char **ticket, time_t * duration, char ***rights, time_t stoptime); INT64_T chirp_client_ticket_modify(struct chirp_client *c, const char *name, const char *path, const char *aclmask, time_t stoptime); INT64_T chirp_client_setacl(struct chirp_client *c, const char *path, const char *user, const char *acl, time_t stoptime); INT64_T chirp_client_resetacl(struct chirp_client *c, const char *path, const char *acl, time_t stoptime); INT64_T chirp_client_locate(struct chirp_client *c, const char *path, chirp_loc_t callback, void *arg, time_t stoptime); INT64_T chirp_client_whoami(struct chirp_client *c, char *buf, INT64_T length, time_t stoptime); INT64_T chirp_client_whoareyou(struct chirp_client *c, const char *rhost, char *buffer, INT64_T length, time_t stoptime); INT64_T chirp_client_mkfifo(struct chirp_client *c, const char *path, time_t stoptime); INT64_T chirp_client_unlink(struct chirp_client *c, const char *path, time_t stoptime); INT64_T chirp_client_rename(struct chirp_client *c, const char *path, const char *newpath, time_t stoptime); INT64_T chirp_client_link(struct chirp_client *c, const char *path, const char *newpath, time_t stoptime); INT64_T chirp_client_symlink(struct chirp_client *c, const char *path, const char *newpath, time_t stoptime); INT64_T chirp_client_readlink(struct chirp_client *c, const char *path, char *buf, INT64_T length, time_t stoptime); INT64_T chirp_client_mkdir(struct chirp_client *c, char const *path, INT64_T mode, time_t stoptime); INT64_T chirp_client_rmdir(struct chirp_client *c, char const *path, time_t stoptime); INT64_T chirp_client_rmall(struct chirp_client *c, char const *path, time_t stoptime); INT64_T chirp_client_stat(struct chirp_client *c, const char *path, struct chirp_stat *buf, time_t stoptime); INT64_T chirp_client_lstat(struct chirp_client *c, const char *path, struct chirp_stat *buf, time_t stoptime); INT64_T chirp_client_statfs(struct chirp_client *c, const char *path, struct chirp_statfs *buf, time_t stoptime); INT64_T chirp_client_access(struct chirp_client *c, const char *path, INT64_T mode, time_t stoptime); INT64_T chirp_client_chmod(struct chirp_client *c, const char *path, INT64_T mode, time_t stoptime); INT64_T chirp_client_chown(struct chirp_client *c, const char *path, INT64_T uid, INT64_T gid, time_t stoptime); INT64_T chirp_client_lchown(struct chirp_client *c, const char *path, INT64_T uid, INT64_T gid, time_t stoptime); INT64_T chirp_client_truncate(struct chirp_client *c, const char *path, INT64_T length, time_t stoptime); INT64_T chirp_client_utime(struct chirp_client *c, const char *path, time_t actime, time_t modtime, time_t stoptime); INT64_T chirp_client_md5(struct chirp_client *c, const char *path, unsigned char digest[16], time_t stoptime); INT64_T chirp_client_setrep(struct chirp_client *c, const char *path, int nreps, time_t stoptime); INT64_T chirp_client_getxattr(struct chirp_client *c, const char *path, const char *name, void *data, size_t size, time_t stoptime); INT64_T chirp_client_fgetxattr(struct chirp_client *c, INT64_T fd, const char *name, void *data, size_t size, time_t stoptime); INT64_T chirp_client_lgetxattr(struct chirp_client *c, const char *path, const char *name, void *data, size_t size, time_t stoptime); INT64_T chirp_client_listxattr(struct chirp_client *c, const char *path, char *list, size_t size, time_t stoptime); INT64_T chirp_client_flistxattr(struct chirp_client *c, INT64_T fd, char *list, size_t size, time_t stoptime); INT64_T chirp_client_llistxattr(struct chirp_client *c, const char *path, char *list, size_t size, time_t stoptime); INT64_T chirp_client_setxattr(struct chirp_client *c, const char *path, const char *name, const void *data, size_t size, int flags, time_t stoptime); INT64_T chirp_client_fsetxattr(struct chirp_client *c, INT64_T fd, const char *name, const void *data, size_t size, int flags, time_t stoptime); INT64_T chirp_client_lsetxattr(struct chirp_client *c, const char *path, const char *name, const void *data, size_t size, int flags, time_t stoptime); INT64_T chirp_client_removexattr(struct chirp_client *c, const char *path, const char *name, time_t stoptime); INT64_T chirp_client_fremovexattr(struct chirp_client *c, INT64_T fd, const char *name, time_t stoptime); INT64_T chirp_client_lremovexattr(struct chirp_client *c, const char *path, const char *name, time_t stoptime); INT64_T chirp_client_remote_debug(struct chirp_client *c, const char *flag, time_t stoptime); INT64_T chirp_client_localpath(struct chirp_client *c, const char *path, char *localpath, int length, time_t stoptime); INT64_T chirp_client_audit(struct chirp_client *c, const char *path, struct chirp_audit **list, time_t stoptime); INT64_T chirp_client_mkalloc(struct chirp_client *c, char const *path, INT64_T size, INT64_T mode, time_t stoptime); INT64_T chirp_client_lsalloc(struct chirp_client *c, char const *path, char *allocpath, INT64_T * total, INT64_T * inuse, time_t stoptime); INT64_T chirp_client_pread_begin(struct chirp_client *c, INT64_T fd, void *buffer, INT64_T length, INT64_T offset, time_t stoptime); INT64_T chirp_client_pread_finish(struct chirp_client *c, INT64_T fd, void *buffer, INT64_T length, INT64_T offset, time_t stoptime); INT64_T chirp_client_sread_begin(struct chirp_client *c, INT64_T fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime); INT64_T chirp_client_sread_finish(struct chirp_client *c, INT64_T fd, void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime); INT64_T chirp_client_pwrite_begin(struct chirp_client *c, INT64_T fd, const void *buffer, INT64_T length, INT64_T offset, time_t stoptime); INT64_T chirp_client_pwrite_finish(struct chirp_client *c, INT64_T fd, const void *buffer, INT64_T length, INT64_T offset, time_t stoptime); INT64_T chirp_client_swrite_begin(struct chirp_client *c, INT64_T fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime); INT64_T chirp_client_swrite_finish(struct chirp_client *c, INT64_T fd, const void *buffer, INT64_T length, INT64_T stride_length, INT64_T stride_skip, INT64_T offset, time_t stoptime); INT64_T chirp_client_fsync_begin(struct chirp_client *c, INT64_T fd, time_t stoptime); INT64_T chirp_client_fsync_finish(struct chirp_client *c, INT64_T fd, time_t stoptime); INT64_T chirp_client_fstat_begin(struct chirp_client *c, INT64_T fd, struct chirp_stat *buf, time_t stoptime); INT64_T chirp_client_fstat_finish(struct chirp_client *c, INT64_T fd, struct chirp_stat *buf, time_t stoptime); #endif cctools-4.0-source/chirp/src/chirp_distribute.c0000640060042600000500000004757512175446362020604 0ustar btovardip/* Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin Copyright (C) 2005- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. */ /* chirp_distribute copies a directory from one host to many others by building a spanning tree at runtime using third party transfers. The -X option will delete the directory from all of the named hosts. */ #include "chirp_client.h" #include "chirp_reli.h" #include "auth.h" #include "auth_all.h" #include "cctools.h" #include "debug.h" #include "stringtools.h" #include "timestamp.h" #include "macros.h" #include "random_init.h" #include "getopt_aux.h" #include #include #include #include #include #include #include #include #include static int timeout = 300; static int overall_timeout = 3600; static int overall_stoptime = 0; static int did_explicit_auth = 0; static int destroy_mode = 0; static int detail_mode = 0; static int maxprocs = 100; static int randomize_mode = 0; static int confirm_mode = 0; static int transfers_needed = 0; static int transfers_complete = 0; static char *failure_matrix = 0; static int failure_matrix_size = 0; static char *failure_matrix_filename = 0; const double threshold = .2; static double *bw_matrix = 0; static int bw_matrix_size = 400; static void bw_matrix_init(int n) { bw_matrix = malloc(sizeof(double) * n * n); memset(bw_matrix, 0, sizeof(double) * n * n); bw_matrix_size = n; } static void bw_matrix_set(int s, int t, double c) { bw_matrix[s * bw_matrix_size + t] = c; } static double bw_matrix_get(int s, int t) { return bw_matrix[s * bw_matrix_size + t]; } static double bw_find_max(int s) { int max = 0, i; for(i = 0; i < bw_matrix_size; i++) { if(max < bw_matrix_get(s, i)) max = bw_matrix_get(s, i); } return max; } static int compute_stoptime() { return MIN(time(0) + timeout, overall_stoptime); } #define FAILURE_MARK_NONE ' ' #define FAILURE_MARK_FAILED '#' #define FAILURE_MARK_SUCCESS '+' static void failure_matrix_init(int n) { failure_matrix = malloc(sizeof(char) * n * n); memset(failure_matrix, FAILURE_MARK_NONE, sizeof(char) * n * n); failure_matrix_size = n; } static void failure_matrix_set(int s, int t, char c) { failure_matrix[s * failure_matrix_size + t] = c; } static char failure_matrix_get(int s, int t) { return failure_matrix[s * failure_matrix_size + t]; } static void failure_matrix_print() { FILE *file; int i, j; if(!failure_matrix_filename) return; file = fopen(failure_matrix_filename, "w"); if(!file) return; for(i = 0; i < failure_matrix_size; i++) { for(j = 0; j < failure_matrix_size; j++) { fputc(failure_matrix_get(i, j), file); } fputc('\n', file); } fclose(file); } typedef enum { TARGET_STATE_FRESH, TARGET_STATE_RECEIVING, TARGET_STATE_SENDING, TARGET_STATE_IDLE, TARGET_STATE_FAILED } target_state_t; struct m_server_info { char *name; int cid; int index; double max; int status; }; struct server_info { char *name; int cid; }; struct target_info { const char *name; target_state_t state; pid_t pid; int cid; }; static void show_help() { fprintf(stdout, "Use: chirp_distribute [options] ...\n"); fprintf(stdout, "where options are:\n"); fprintf(stdout, " %-30s Require this authentication mode.\n", "-a,--auth="); fprintf(stdout, " %-30s Enable debugging for this subsystem.\n", "-d,--debug="); fprintf(stdout, " %-30s Show detailed location, time, and performance of each transfer.\n", "-D,--info-transfer"); fprintf(stdout, " %-30s Write matrix of failures to this file.\n", "-F,--failures-file="); fprintf(stdout, " %-30s Comma-delimited list of tickets to use for authentication.\n", "-i,--tickets="); fprintf(stdout, " %-30s Stop after this number of successful copies.\n", "-N,--copies-max="); fprintf(stdout, " %-30s Maximum number of processes to run at once (default=%d)\n", "-p,--jobs=", maxprocs); fprintf(stdout, " %-30s Randomize order of target hosts given on command line.\n", "-R,--randomize-hosts"); fprintf(stdout, " %-30s Timeout for for each copy. (default is %ds)\n", "-t,--timeout=