ASTRON 98: Introduction to Python For Astronomers
(Fall 2026)


Facilitators:

  • Katherine Mora (katherinemora@berkeley.edu)
  • Mariam Helal (mariam.helal@berkeley.edu)
  • William Lee (williamlee8@berkeley.edu)
  • Safia Barmada (sbarmada@berkeley.edu)
  • Milana Berhe (milana.berhe@berkeley.edu)
  • Olivia Silva (olivia_lsilva@berkeley.edu)
  • Annecy Jiang (annecyjiang@berkeley.edu)
  • Makaio Jimenez (makaiojimenez@berkeley.edu)
  • Nathan DeBeech (nathandebeech@berkeley.edu)

Interns:

  • Hannah Eghtedari (hannaheghtedari@berkeley.edu)

Faculty Sponsor:

  • Aaron Parsons (aparsons@berkeley.edu)

Time & Location:

  • Mondays & Wednesdays, 3:00-4:00 PM
  • 131 Campbell Hall

Office Hours:

  • TBD (Posted by Week 2)

Course Number:

  • 98

Course Code:

  • TBD

Units:

  • 2 units, P/NP

Course Description

This course offers an introduction to the Python programming language with an emphasis on data analysis and scientific research in astronomy and physics. Python is one of the most common programming languages used by modern astronomers, and this class focuses on preparing undergraduate intended/declared astronomy students for upper-division laboratory courses and research. However, students from all backgrounds are welcome to apply.

Key topics include the command line, VS Code, scripting, version control with Git, documentation, Jupyter Notebooks, and common Python packages/libraries. We’ll also cover advanced topics such as curve-fitting, processing FITS files, querying databases, and object-oriented programming.

The Python DeCal is designed for students with little or no prior programming experience. However, learning the technical material covered in this course—especially for beginners—requires dedication, patience, and regular practice. Many students find this workload more demanding than other lower-division DeCals at UC Berkeley. If you have already taken advanced computer science or data science courses at Berkeley or elsewhere, this class may not be the best fit for you. But if you are excited to explore how coding can be applied to astronomical research, we still encourage you to apply.

Everyone’s ``learning to code” journey will be different. Some concepts may click quickly, while others take time. Your effort on homework and the in-class exams will directly shape what you gain from the Python DeCal. We strongly recommend attending all lectures and discussions, as attendance is strictly required. If you have a conflict with the course time or extenuating circumstances there is an asynchronous option. In addition to mandatory in-person attendance, each lecture will be recorded and posted to our class YouTube Channel as an additional resource. To get the most out of this course, complete homework assignments to the best of your ability (with little to no help from AI tools), attend office hours regularly, and put meaningful effort into preparing for exams. If you need help, please reach out. We have a large team, so we can give as many students as possible one-on-one support.

Learning Objective

Students will be introduced to fundamental programming concepts with the goal of building proficiency in developing software for upper-division astronomy laboratory work and scientific research using Python. In addition to completing weekly homework and lecture check assignments, students will demonstrate their understanding of version control, scripting, packages/libraries (i.e., NumPy, Matplotlib, Pandas, SciPy, Astropy), and software structure and flow by completing the homework assignments and in-class exams structured as coding challenges.

These exams will be presented quarterly, and will take place during the usual course time. These exams will not be cumulative and will be structured such a way that allow students to demonstrate their understanding of new coding concepts without being overwhelming.

Course Materials & Resources

Students are expected to bring and use their own computers for the duration of this course. If you are unable to obtain a laptop, please consider utilizing the Student Technology Equity Program (STEP) which offers semester-long computer rentals. If the STEP program is not a suitable option, reach out to the Python DeCal course staff and we can help arrange alternative accommodations.

Required Readings

There are no required readings outside of material provided during lecture, discussion, and the guides. However, we recommend two optional textbooks written by former Python DeCal instructors:

  • Python for Astronomers: An Introduction to Scientific Computing
    Written by previous facilitators (Imad Pasha and Christopher Agostino), last updated in 2019.
    GitHub Link

  • Astronomical Python: An Introduction to Modern Scientific Programming
    Official textbook by Imad Pasha, published in May 2024.
    IOPscience Link

For additional reference on the packages/libraries we use throughout the semester, you may find these optional docu- mentation links helpful:

bCourses

All course-related content will be available on our bCourses site, unless otherwise noted:

  • Lecture materials, homeworks, demos, rubrics, and guides −→ posted under the Files section
  • Important updates and reminders −→ posted under the Announcements section
  • Syllabus −→ posted under the Syllabus section
  • Office hours −→ posted under the Home section
  • Grades −→ posted under the Grades section

Gradescope

All assignments for the Python DeCal will be submitted via Gradescope. This includes homework, Google Form submissions, and all exams.

After the first homework, all homework submissions must be GitHub repositories uploaded to Gradescope.

EdStem

EdStem is our main Q&A platform where students can ask questions and receive timely answers from course staff and peers. We highly recommend using EdStem over email, as it enables collaborative learning and quicker response times.

If you need to contact a staff member directly, please include [PYTHON DECAL] or [ASTRON 98] in the subject line of your email so it can be identified quickly. For logistical or urgent matters, contact the Head Instructor Katherine Mora at katherinemora@berkeley.edu.

YouTube Channel

For supplemental review and asynchronous learning, the Python DeCal records and posts all course videos to our YouTube channel. While these videos are a helpful resource, we highly recommend attending all classes in person to benefit the most from this course.

If you can only participate asynchronously, we strongly recommend attending office hours outside of class to stay on track to get personalized support. Asynchronous students must ensure they can attend at least one office hour time as they will have to take exams in-person during the scheduled exam time or office hours.

Office Hours

Course staff office hours provide a dedicated space for students to ask questions, collaborate with peers outside of regular class times, and get one-on-one support. We strongly encourage attending office hours weekly and taking the opportunity to connect with staff members. If you are struggling with any course material, office hours are a great place to get help.

Even if you don’t have course-related questions, our interns and instructors are more than happy to offer guidance on selecting or declaring a major, finding research opportunities, applying to graduate school, or exploring summer programs on and off campus.

The finalized office hours schedule will be posted to bCourses by the end of Week 2. Additional office hours will be held during the first two weeks of the course to help students install the software needed for the semester.

Grading Breakdown

  • Participation 20%

  • Homework 40%

  • Exams 40%

To pass the Python DeCal, you must earn a grade of 70% or above and attend all exams. Asynchronous students must schedule a time to take exams with an instructor during office hours if they have a conflict during the allotted course time.

Participation (20% of your grade)

Class meets twice a week, with most weeks following this structure:

  • Monday −→ Lecture to introduce new material (more formal, led by instructors/interns with demos)
  • Wednesday −→ Discussion to apply lecture material through hands-on practice (more collaborative, with staff assisting as students work through guided problems)

A laptop is required for all lectures and discussions. If you do not bring a computer, you will not be able to follow along easily or participate fully. Laptops should only be brought out after warm-up activities, which must be completed on paper to avoid the temptation of asking Google or ChatGPT directly for answers.

Lecture Checks

In-person attendance will be tracked through lecture check assignments with an access code given to students who attended lecture. Attendance and lecture check assignments will make up the most significant portion of your participation grade. Asynchronous students will have separate access codes within the lecture slides. If you need to opt to take the course asynchronously, please email the Head Instructor Katherine Mora at katherinemora@berkeley.edu indicating your participation mode. All students will automatically be enrolled as in-person students and will be responsible as such unless explicitly confirmed otherwise by the head instructor.

  • Students will complete a 5-10 minute lecture check quiz on bCourses at the end of each class. These open at the end of each lecture and close at midnight the day after lecture.
  • Students have until each exam to submit respective late lecture checks for a deduction in points.
  • Only 85% completion of lecture check assignments is required for full credit. In other words, up to 3 attendance drops will be allowed.
  • These assignments help demonstrate engagement, especially for asynchronous attendance, and reinforce lecture con- cepts.
  • Each lecture check requires an access code that will only be given to students who attended lecture. Asynchronous students will have a separate attendance code that will be posted within the lecture slides.
  • Lecture checks will be linked at the end of each lecture, as well as posted on bCourses as an assignment.

In order to complete these assignments you will need to attend class to receive the attendance code. For asynchronous students, you must read the lecture slides for the attendance code or watch a recording of the lecture/discussion on our YouTube Channel. While asynchronous attendance is an option, it is reserved for students with conflicts or extenuating circumstances preventing them from attending the course in person. Due to technical or human error, some recordings may go missing. While we do have a catalog stretching back to Spring 2021, older recordings may not match the content from this semester.

Additional Participation

Throughout the semester we will request that you fill out Google Forms in a timely manner. You will receive participation credit for these assignments.

Homework (40% of your grade)

Starting in Week 2, homework will be assigned weekly on Mondays and will be due the following Wednesday at 11:59 PM on Gradescope. After the first homework, all submissions must be GitHub repositories uploaded to Gradescope. Homework will reinforce lecture material, include questions similar to those in discussion, and introduce additional topics for you to explore on your own.

Important Notes

  • There is no penalty for late submissions within a two-week grace period of the original due date. If additional time is needed beyond the grace period, contact a member of the Python DeCal staff or email the Head Instructor Katherine Mora at katherinemora@berkeley.edu.
  • Homework is graded on effort and accuracy. You will earn most points as long as you show clear thought and honest attempts, even if your answers are not fully correct.
  • While independent exploration is encouraged, any submission of AI-generated code will receive an automatic zero. You may use Google or AI-tools to ask questions, but avoid directly copying and pasting code from AI tools. Remember, humans are grading your homework, so please submit human-written code.
  • Collaboration is allowed, but all work submitted must be on your own.

While AI has become a powerful tool in recent years, please avoid over-reliance on AI for homework. AI can give you answers easily, but working through problems yourself is what builds skills needed for upper-division labs and research/industry. Misuse of AI-generated content will be treated as a violation of academic integrity and will be reported. Exams will also be entirely on pen and paper and based on the content explored in the homework, so keep that in mind. With great power comes great responsibility. With great power comes great responsibility

Exams (40% of your grade)

Each exam will be worth 10% of your grade. These exams are intended to check your understanding of course content, not to trick or punish you. If you have attended lecture and genuinely attempted completing all course assignments then these exams should be stress-free. Since there are four exams, there are many opportunities to raise your grade. With this in mind, there will be no clobber policy. Each exam will be structured as a coding challenge that will take place in-person on pen and paper. A review of the content covered will be given in the 20 minutes before an exam, and students will have the remaining class time to finish the challenge. Students may have the option of working with one other student to complete the challenge. The use of any electronic devices during exams is strictly prohibited. If a student is caught using an electronic device during an exam, they will receive an automatic zero on that exam and will be subject to the university’s academic misconduct guidelines.

Exams will be graded based on the following break-down:

  • Participation 20%
  • Performance 80%

A student will receive full credit in the participation category by simmply attending the exam in-person. The remaining percentage will be determined by the raw score the student earns on the exam.

Regrading

Due to the Python DeCal extension policy on homework assignments, we will not be accepting regrades this semester. If you believe your work was inaccurately graded (not just graded a bit harshly), you can ask a Python DeCal instructor to re-grade it. Keep in mind that the instructors reserve the right to re-grade the entirety of the assignment and you may potentially end up with a lower grade than you initially received.

Academic Misconduct

As with all classes, cheating, plagiarism, and other forms of academic dishonesty will not be tolerated. First violations will result in a zero on the assignment, and any subsequent violations may result in administrative action in accordance with the UC Berkeley Astronomy Department Policy on Academic Misconduct.


Syllabus from Previous Semesters


Back to top

Copyright © 2025 Python DeCal. All rights reserved.