These things need more precise docstrings. What are the types of the inputs and output? Remember, people who you've never interacted with are going to be using these functions.