pip get installed packages directory code example
Example 1: python get packages path
path = os.path.dirname(a_module.__file__)
Example 2: how to see pip installed packages
py -m pip list [options]
path = os.path.dirname(a_module.__file__)
py -m pip list [options]