Some simple helpers for working with networks