Assignment Instructions

— Alex Reinhart and Christopher Genovese

All homework in this class will be submitted using GitHub. Before you can submit an assignment, follow our system setup instructions to ensure you have a GitHub account and have the right software installed.

At the beginning of the semester, we will send an email through Canvas with instructions to be added to our class GitHub organization. Once you’re in our class organization, you will have a GitHub repository at The system setup instructions describe how to clone this repository to your computer.

Starting a homework assignment #

Browse the problem bank for an assignment that looks interesting to you, based on its topic and difficulty level. We recommend you choose assignments based on the skills you want to develop the most.

Once you’ve picked a homework assignment you’d like to do, open a terminal and ensure you have the latest problem bank:

cd ~/s750/problem-bank
git pull origin master

Next, move to your assignment repository on your computer:

cd ~/s750/assignments-YOURUSERNAME

The new-homework script provided there will help you make a new branch for the assignment and install template files. Select the programming language you plan to use and run one of the following commands:

# For R:
python r assignment-name

# For Python:
python python assignment-name

# For any other language, including SQL, or
# assignments that don't require programming:
python none assignment-name

Replace assignment-name with the name of the homework assignment exactly as written in the problem bank, e.g. cow-proximity or markov-babbler.

The script will create a new branch for this assignment and install template files in a subdirectory. Edit these files to begin working on your assignment.

Work on only one assignment per branch. If you want to stop working on one assignment and switch to another, commit your work, then switch branches.

Submitting a homework assignment #

Once you’re ready, commit your work (with git add and git commit). When you’re ready to submit:

  1. Push your work to GitHub (git push).
  2. In your web browser, go to your private repository on GitHub. Click the “New pull request” button.
  3. As the “base” branch, choose master. As the “compare” branch, select the branch you created for this assignment.
  4. Scroll down. You’ll see a listing of the commits included in the pull request and the diff the TAs will review. Make sure this includes the work you intend to submit and nothing else. If it looks wrong, stop and ask for help.
  5. Press “Create pull request”.
  6. Give your pull request an informative title specifying the assignment you’re submitting. If required in the assignment, answer any questions in the comment box.
  7. On the right-hand side, under “Reviewers”, select 36-750/tas, which will notify all the TAs.
  8. Press “Create pull request”.

Your assignment is now submitted and ready for the TAs to grade. It may take several days, or up to a week, for them to review your assignment, depending on how many assignments are in their queue.

You should only submit one assignment per pull request, and work on one assignment on each branch.

Automated checks #

Our automated system, ComScan, will pull your code as soon as you open your pull request. If your code is written in R or Python, it will attempt to run your unit tests. If they pass, you will see the message “All checks have passed.” If they fail, you will see a red X on your pull request indicating that “checks have failed”, and ComScan will leave a comment linking to the logs, which will show you which test failed. This should only take a few minutes.

If your tests failed because of a problem in your code, fix the bug before requesting review from the TAs. (If you already requested review, cancel the request until you can fix the problem.)

Sometimes the tests fail for reasons that aren’t your fault: ComScan might have crashed unexpectedly, or maybe you used a package that wasn’t installed on our server. In that case, you don’t need to do anything; we’ll investigate and fix the problem.

If you’re not sure why ComScan reported a problem, just send us an email or come to office hours.

Code review #

The TAs will review your code and leave comments if any issues need to be fixed. If they determine you have mastered the assignment, they will approve the pull request and merge it into your master branch, and it will be counted toward your points total automatically.

Code review is based on the programming rubric.

Don’t panic if the TAs leave lots of comments. Because you can revise your work, we often leave comments about stylistic issues and small problems, so receiving a lot of comments does not mean your work is bad.

Each assignment and project may be revised at most twice.

To resubmit an assignment #

If the TAs determine that your assignment needs revisions, they will mark your pull request “Changes requested”. If you don’t understand their comments, you should always feel free to reply and ask for clarification. You can also consult us during office hours.

To make revisions, you do not need to make a new pull request. Simply follow these instructions:

  1. Make sure you’re on the branch you used for the assignment (git checkout assignment-name-here).
  2. Make your revisions and run your tests.
  3. Commit your revisions (git add and git commit).
  4. Push the revisions to GitHub (git push).
  5. Go to GitHub and find your previous pull request. Your commits should appear there. Request review again to notify the TAs it’s ready for regrading, using this button: