9951 explained code solutions for 126 technologies


python-scipyHow do I check the version of Python SciPy I'm using?


To check the version of Python SciPy you are using, you can use the scipy.__version__ attribute. This attribute will return the version of SciPy you are using.

Example code

import scipy
print(scipy.__version__)

Example output:

1.5.2

The code can be broken down into two parts:

  1. import scipy - this imports the SciPy library into the program.
  2. print(scipy.__version__) - this prints the version of SciPy that is being used.

Helpful links

Edit this code on GitHub