| 1 |
#!/usr/bin/env python |
| 2 |
# coding: utf-8 |
| 3 |
"""Print information about python.""" |
| 4 |
|
| 5 |
__authors__ = ["Jérôme Kieffer"] |
| 6 |
__date__ = "08/12/2015" |
| 7 |
__license__ = "MIT" |
| 8 |
|
| 9 |
|
| 10 |
import sys |
| 11 |
|
| 12 |
print("Python %s bits" % (tuple.__itemsize__ * 8)) |
| 13 |
print(" maxsize: %s\t maxunicode: %s" % (sys.maxsize, sys.maxunicode)) |
| 14 |
print(sys.version) |
| 15 |
print(" ") |
| 16 |
|
| 17 |
try: |
| 18 |
from distutils.sysconfig import get_config_vars |
| 19 |
except ImportError: |
| 20 |
from sysconfig import get_config_vars |
| 21 |
print("Config: " + str(get_config_vars("CONFIG_ARGS"))) |
| 22 |
print("") |
| 23 |
|
| 24 |
try: |
| 25 |
import numpy |
| 26 |
except ImportError: |
| 27 |
print("Numpy not installed") |
| 28 |
else: |
| 29 |
print("Numpy %s" % numpy.version.version) |
| 30 |
print(" include %s" % numpy.get_include()) |
| 31 |
print(" options %s" % numpy.get_printoptions()) |
| 32 |
print("") |