Can't remember where I read this but it's good to keep in mind why module level imports should be avoided.

Having imports later in the file can be brittle and can cause small changes in the ordering of your code to break the module entirely