- Wednesday 5:30pm – 8:00pm, Mazur 103
- Prof. Lee Hachadoorian
- 104 Gladfelter Hall – In GIS Studio, enter 103A
- Office Hours:
- Monday 1-2pm (office, virtual)
- Tuesday 1-2pm (virtual only)
- Wednesday 1-2pm (office only)
Building on previous coursework with Geographic Information Systems (GIS), students will learn computer programming in a GIS environment. Students will design and execute spatial data management and spatial analysis projects using automated geoprocessing functions available in the built-in scripting languages of prominent GIS software packages, with an emphasis on the Python programming language. Students will learn programming concepts such as variable typing, function definition, conditional evaluation, looping, and object-oriented programming. The course will also introduce geospatial programming strategies independent of any specific GIS software.
Python has rapidly become the de facto standard for scientific computing. It is also the scripting language used by two prominent GIS packages, ArcGIS (proprietary) and QGIS (open source). There is also an extensive and growing ecosystem of Python packages for geospatial analysis. The course will begin by focusing on using Python and ArcPy for ArcGIS scripting and automation, while also introducing fundamental concepts in programming, using the textbook Python for ArcGIS. We will also make use of DataCamp interactive tutorials to learn Python syntax and reinforce these fundamental concepts. This part of the course will feature weekly exercises and quizzes on these basic concepts.
The latter part of the course will introduce Python geospatial programming outside of the ArcGIS environment. In this part of the course, students will present tutorials on further topics in Python and ArcPy.
- Fundamentals of GIS (GUS 5062) with B- or better, or equivalent.
- A laptop on which you can install software and data
This course meets once a week. Missing any class meetings will hamper your ability to complete the work in this course. Your attendance percentage will also indicate the maximum final grade you can earn in this course. If you miss 3 classes, you have attended 78.6% of class meetings. Accordingly, your final grade will not be higher than a C+, regardless of any other work completed. Please see my attendance policy at my Temple web page: https://sites.temple.edu/hachadoorian/specification-grading/
In addition, we will hit the ground running and you must come prepared to work in class. I will let you know ahead of time about assignments that are required class preparation. Not completing them prior to class time will be treated as an absence.
Readings and exercises will be assigned from:
- Python for ArcGIS – When accessed on campus or through the Temple Library proxy server (Python for ArcGIS via proxy), you will be able to download this textbook in its entirety for free. You are also REQUIRED to obtain a print copy. The Springer “MyCopy” service is a print-on-demand service which will allow you to order a softcover copy for $39.99. You must be accessing SpringerLink on campus or log in through the Temple Library proxy server to get access to the MyCopy print-on-demand service.
Online exercises will be assigned from DataCamp:
(Note: These links haven’t been reviewed in recently. If a link is broken, please bring it to my attention. I will remove this message when they are all updated.)
- Think Python, 2e – This is a free online textbook which provides an introduction to computer science using Python. A printed version is also available.
- Real Python – This is an extensive and growing collection of Python tutorials. The tutorials are focused, detailed, and well-written. Some are available only to subscribers, many are free.
- A large number of Python videos are available through Temple’s LinkedIn Learning subscription. You may explore them for topics of interest, but if you need reinforcement on the material we are covering in this course, I would suggest:
- Python 3 Essential Training
- Official Python documentation – I can’t teach you everything. You have to learn how to consult technical documentation in order to solve the problem at hand.
- PEP 8 — the Style Guide for Python Code – How to structure your code for readability.
- The Hitchhiker’s Guide to Python – NOT a programming tutorial, but an extensive guide to concepts and best practices in Python development.
Other resources for GIS scripting:
- Python Scripting for ArcGIS Pro by ESRI Press – may overlap with some of the material in our textbook
- Customizing QGIS with Python by Ujaval Gandhi – free materials from a workshop on the QGIS Python API
Each week during the first half of the course, exercises will be assigned from the textbook. The first handful are structured as practice quizzes (no points) in Canvas. Subsequent exercises involve modifying or creating short Python scripts. One question each week will be evaluated and bonus points awarded in the quizzes track for correct answers. The exercises must be submitted on time. Solutions will be posted to Canvas, so that you can check your work on questions that were not evaluated. We will review some of the exercises at the beginning of the class after the due date.
Beginning during the third week of class, each week will have one short, graded programming quiz. The topic will be based on the lecture and reading from two weeks prior. The difficulty level should be comparable to or easier than the take-home exercise, so if you complete the exercise, are present for in-class review, and review the problem and answer afterwards, you should be well-prepared for the quiz.
The quizzes will be taken remotely in Canvas. You will have 25 minutes to complete the quiz.
The quizzes are cumulative, and must be passed (completed) in sequence. If you do not pass a quiz, you may retake it in the following week. Completed quizzes are awarded full credit, that is, there is no penalty taking a quiz multiple times before completing it successfully.
If you fall behind, each week you may retake the next quiz in the sequence, and one additional quiz. That is, if you need to retake Quiz 3, you may also take Quiz 4 before I grade Quiz 3. You may not take Quiz 5. Quiz 4 will only be evaluated if you successfully complete Quiz 3. You may not retake a quiz during the same week, so that you have time to review the material and prepare for the retake.
This course will make use of online exercises provided by DataCamp. You must use your Temple email address to register for a premium account (free using a link provided by the instructor). You will be required to complete three assigned DataCamp courses, and one additional one of your choosing.
The three required courses are broken up by chapter in Canvas, so that, for example, it is suggested that you complete “Ch 4 Loops” from the DataCamp Intermediate Python for Data Science course when we are reading “Ch 10 Repetition: Looping for Geoprocessing” and “Ch 11 Batch Geoprocessing” in the textbook. In some cases that means that I have assigned the DataCamp chapters out of order. Since the only thing you turn in is the course completion certificate, you may choose to progress through the course in the DataCamp order, as long as you complete all chapters on time.
You are required to complete the following courses:
- Introduction to Python due during Module 3 – ArcPy Tools.
- Ch 1 – Python Basics should be completed during Module 1 – Python Basics
- Ch 2 – Python Lists should be completed during Module 2 – Lists and Tuples
- The remaining two chapters must be completed during Module 3 – ArcPy Tools
- Intermediate Python due during Module 6 – Dictionaries
- Ch 3 – Logic, Control Flow and Filtering should be completed during Module 4 – Control Flow, Conditionals
- Ch 4 – Loops should be completed during Module 5 – Loops
- The remaining three chapters must be completed during Module 6 – Dictionaries
- Python Data Science Toolbox (Part 1) due during Module 8 – Error Handling
- Ch 1 Writing your own functions and Ch 2 Default arguments, variable-length arguments and scope should be completed during Module 7 – User-Defined Functions
- The remaining one chapter must be completed during Module 8 – Error Handling
You will complete one additional DataCamp Python course of the your choosing. Suggested courses include:
- Python Data Science Toolbox (Part 2)
- Data Manipulation with Pandas
- Working with Geospatial Data in Python
- Data Types for Data Science
- Network Analysis in Python
You will have premium access to DataCamp courses for six months. You may choose to complete any additional courses you want to throughout the semester, and for a few weeks beyond the end of the semester.
Students who have previously used DataCamp and already completed the three required courses (the completion date on your DataCamp certificate is prior to this semester) should either retake the course if they feel they need a refresher or select another DataCamp Python course to do instead. Please ask me if you have any questions.
Python Package Tutorials
During the second half of the course we will tour the wide variety of Python packages for data and geospatial analysis. We will discuss packages of interest in class, and two to three students will plan a package presentation and class tutorial.
These will be three short programming assignments that will build on material learned in the exercises.
You will earn points along several tracks. Each track is worth up to 100 points. Your must progress along ALL tracks to be successful in this course. Your final grade is the based on the lowest score earned along any track.
- 0-100 points. Your attendance score is a straight percentage of class sessions you are present for.
- Programming Quizzes (8)
- 34 + 10 points each for quizzes 1 through 5, and 3 points each for quizzes 6 through 8.
- Exercises (9)
- 0 points for exercises from Chapter 2, 3, and 4, which are structured as practice quizzes.
- 1 bonus point each (6 total) added to the Programming Quizzes track for exercises from Chapter 5 on.
- DataCamp (4)
- 60 + 10 points for each course completed fully. Courses must be completed on time. 1 point will be deducted for each day late, to a minimum of 5 points for courses completed 5 or more days late. The date on the certificate of completion will be used so that you are not penalized if you complete the course on time but forget to submit the certificate.
- Python Package Tutorial
- 70-100 points. The tutorial will be awarded up to 30 points based on requirements announced separately. Since each tutorial will happen on a specifically scheduled day, this assignment cannot be revised for a higher grade.
- Programming Assignments (3)
- 69 + 10 points for each assignment.
Any student who has a need for accommodation based on the impact of a disability should contact me privately to discuss the specific situation as soon as possible. Contact Disability Resources and Services at 215-204-1280 in 100 Ritter Annex to coordinate reasonable accommodations for students with documented disabilities.
All submitted work should be your own.
All persons participating in the course should be respectful of other students and the instructor in order to facilitate a civil learning environment. All persons participating in the course have a right to expect respectful treatment in the classroom.
Statement on Academic Freedom
Freedom to teach and freedom to learn are inseparable facets of academic freedom. The University has adopted a policy on Student and Faculty Academic Rights and Responsibilities (Policy # 03.70.02).
Temple and COVID-19
Temple University’s motto is Perseverance Conquers, and we will meet the challenges of the COVID pandemic with flexibility and resilience. The university has made plans for multiple eventualities. Working together as a community to deliver a meaningful learning experience is a responsibility we all share: we’re in this together so we can be together.
How This Course Will Be Taught
This course meets in person at the time and place indicated above.
This course has no final exam.
Attendance Protocol and Your Health
To achieve course learning goals, students must attend and participate in classes, according to your instructors’ requirements. However, if you feel unwell or if you are under quarantine or in isolation because you have been exposed to the virus or tested positive for it, you should not come to campus or attend in-person classes or activities. It is the student’s responsibility to contact their instructors to create a plan for participation and engagement in the course as soon as they are able to do so, and to make a plan to complete all assignments in a timely fashion, when illness delays their completion.
Student Support Services
If you are experiencing food insecurity or financial struggles, Temple provides resources and support. Notably, the Temple University Cherry Pantry and the Temple University Emergency Student Aid Program are in operation as well as a variety of resources from the Office of Student Affairs.
Statement on Recording of Class Sessions
Class sessions may not be recorded, whether in person or remote, except in cases of an approved accommodation from the Office of Disability Resources (DRS).