"cell_type": "markdown",
"metadata": {},
"source": [
- "# Software Engineering Unit at LBL\n",
+ "# Software Engineering in Python\n",
"\n",
- "Goal:\n",
- " \n",
- "Write a utility that returns the mean number of a particular animal seen per sighting of that animal.\n",
+ "# Outline\n",
+ "\n",
+ "* What is software engineering?\n",
+ "* Goal\n",
+ "* Creating a library of code\n",
+ "* Refactoring\n",
+ "* Testing\n",
+ "* Nose\n",
+ "* Test-driven development"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "***\n",
+ "# What is software engineering?\n",
+ "***\n",
+ "\n",
+ "*\"Software engineering is the application of a systematic, disciplined, quantifiable approach to the design, development, operation, and maintenance of software, and the study of these approaches; that is, the application of engineering to software.\"* - [Wikipedia](https://en.wikipedia.org/wiki/Software_engineering)\n",
+ "\n",
+ "In practial terms, this means solving problems with software in a way that is:\n",
+ "\n",
+ "* Efficient\n",
+ "* Maintainable\n",
+ "* Repeatable\n",
+ "* Scalable\n",
+ "* Provably correct\n",
+ "* Cost-effective\n",
+ "\n",
+ "Today we'll focus on building a small, trusted library of code. We will strive to achieve the bullet points identified above"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "***\n",
+ "# Goal\n",
+ "***\n",
+ "\n",
+ "Up until now, most of our work has been in the IPython notebooks. As we discussed earlier, however, there are advantages to creating standalone Python modules and command-line scripts. These advantages include the ability to execute the programs frequently or in an automated fashion, as well as to centralize commonly-used bits of code for import into multiple programs.\n",
+ "\n",
+ "Recalling the animal sighting data sets we worked with earlier, our goal will be to create a standalone utility, runnable from the command line, that finds the mean number of a particular animal seen per sighting of that animal. We will design our utility so that it will work with any properly-formatted data file and allow us to find the mean number of sightings for any animal contained within.\n",
"\n",
- " def mean_animal(filename, species)\n",
- " ...\n",
- " return mean_animal_per_sighting"
+ "To achieve our goal, we'll approach the problem in a fashion typical of modern software engineering."
]
},
{