When using `if` to determine whether or not a value exists, I prefer using the pattern that the default for non-existence is `None`, rather than another Python type (such as `[]`, `{}`, `''`, or `0`) where it is less-clear on a glance that `if value` will evaluate to False.

So, I would change this line to be `if total_student_count.get(child.location.url(), None)`