One one hand, the direct import method has the advantage of being lean, clean, and easy to read. Computer scientists love it.
On the other hand, it does not work well if we need to use multiple packages containing identically named functions. For example, the math package math
, the complex mathematics package cmath
, the numerical python package numpy
, and the numerical calculation of uncertainties package uncertainties
all have trigonometric functions called sin
and cos
. To keep clear which function we are using from which package, and when, we will usually use the traditional import style for packages.