Wednesday, December 15, 2010
Performance vs. Memory
I can vividly remember in CS class when I was told that you always can interchange speed and memory. Concise memory almost always involves in a reduction of speed. Lately I've felt the headaches of multiple scripts. Scripts to run other scripts, that run other scripts. A pipeline designed of very very little pipes. While this complexity can be viewed from a variety of angles, the more scripts the more angles. After a while only the experience mouse is the only one that can make it out of the maze. As I take over a protein binding project designed with many scripts. I find it overall confusing. Partial confusion is based upon the transferring from shell scripting to Perl. Utilizing one script to translate another. A question that resonates in my head is the clarity of labeling. So often do we label our files based upon our moods or generalized belief of the script. Requiring a time consuming process to break down a true purpose. Often all of the scripts are placed in a single folder when using the folder system to organize could eliminate the confusion and excessive commenting. A second problem is the consistent usage of hard coding locations. I have a firm belief in the idea of a config file and a soft-coded script. The idea that a script could be used on any computer with the basic requirements. A script that is edited from the outside (config) rather than the inside. That the extra efforts of a well thought script can save in the long run. Utilizing an interpreter based system may also decrease the problems at hand. Imagine you have 500,000 jobs to run one day and 500 to run the next day and you're using the same cluster. A script could be manually told the task to break up the jobs based upon your believed speed. Instead what if the script could evaluate the hard drive and ram memory usages and pair up files according to your processor abilities. Dividing up the jobs among nodes without much though, or threading the jobs for single machines based upon either a config file or auto detecting system. In most cases I believe the idea of a complex script is simply a script that is poorly designed a structure that appears like a plate of spaghetti rather than a box of it.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment