import os
import sys
sys.executable

"""
Explanation: Check Environment
This notebook checks that you have correctly created the environment and that all packages needed are installed.
Environment
The next command should return a line like (Mac/Linux):
/&lt;YOUR-HOME-FOLDER&gt;/anaconda/envs/ztdl/bin/python

or like (Windows 10):
C:\\&lt;YOUR-HOME-FOLDER&gt;\\Anaconda3\\envs\\ztdl\\python.exe

In particular you should make sure that you are using the python executable from within the course environment.
If that's not the case do this:

close this notebook
go to the terminal and stop jupyer notebook

make sure that you have activated the environment, you should see a prompt like:
(ztdl) $


(optional) if you don't see that prompt activate the environment:

mac/linux:
source activate ztdl



windows:
activate ztdl


restart jupyter notebook
End of explanation
"""


import sys
sys.version

"""
Explanation: Python 3.5
The next line should say that you're using Python 3.5.x from Continuum Analytics. At the time of publication it looks like this (Mac/Linux):
3.5.3 |Continuum Analytics, Inc.| (default, Mar  6 2017, 12:15:08) \n[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)

or like this (Windows 10):
3.5.3 |Continuum Analytics, Inc.| (default, May 11 2017, 13:52:01) [MSC v.1900 64 bit (AMD64)]

but date and exact version of GCC may change in the future.
If you see a different version of python, go back to the previous step and make sure you created and activated the environment correctly.
End of explanation
"""


import jupyter
jupyter.__file__

"""
Explanation: Jupyter
Check that Jupyter is running from within the environment. The next line should look like (Mac/Linux):
/&lt;YOUR-HOME-FOLDER&gt;/anaconda/envs/ztdl/lib/python3.5/site-packages/jupyter.py'

or like this (Windows 10):
C:\\Users\\paperspace\\Anaconda3\\envs\\ztdl\\lib\\site-packages\\jupyter.py
End of explanation
"""


import pip
import numpy
import jupyter
import matplotlib
import sklearn
import scipy
import pandas
import PIL
import seaborn
import h5py
import tensorflow
import keras
'''
assert(pip.__version__ == '9.0.1')
assert(numpy.__version__ == '1.12.0')
assert(matplotlib.__version__ == '2.0.0')
assert(sklearn.__version__ == '0.18.1')
assert(scipy.__version__ == '0.19.0')
assert(pandas.__version__ == '0.19.2')
assert(PIL.__version__ == '4.0.0')
assert(seaborn.__version__ == '0.7.1')
assert(h5py.__version__ == '2.7.0')
assert(tensorflow.__version__ == '1.1.0')
assert(keras.__version__ == '2.0.4')
'''
print("Houston we are go!")

"""
Explanation: Other packages
Here we will check that all the packages are installed and have the correct versions. If everything is ok you should see:
Using TensorFlow backend.

Houston we are go!

If there's any issue here please make sure you have checked the previous steps and if it's all good please send us a question in the Q&A forum.
End of explanation
"""


