GOTM

EditScenario and friends

Karsten Bolding

September 13, 2019


Status on Python

I use Intels Python distribution - with mixed feelings - and lately when I’ve done Python sysadm I’ve started to reciecve messages about ending support. We have also tested how the tools work with package-manager installed Python3 on debian based distributions - with success.

On Windows we suggest to use Anaconda as Python distribution.

From here it is also clear the Python2 is approaching the end:

The End Of Life date (EOL, sunset date) for Python 2.7 has been moved five years into the future, to 2020. 

In combination with Jorns new Python3 only laptop it made it clear that steps were needed in order to be able to operate GOTM in the usual way also after January 1. 2020. This has lead to a number of changes in the python code so basic functionallity is available both in Python2 and Python3. It has also lead to the fact that certain features are only available in Python2. These are typically GUI related extra features.

Good news is that the different packages are available from PyPi and are as easy to install as:

pip install <package_name> [--user]  

For further information see PyPi

Status on packages

  Name    Py2       Py3   
xmlstore x x
xmlplot x x
editscenario x x1
gotmgui x
pygotm2 x x
PyNcView3 x x
 

In principle Python is platform independent and we have tested on Mac, Linux and Windows but there are so many things that can influence compatability that there is no guarantee that it will work on all computers.

  1. The graphical part of editscenario - i.e viewing GOTM time-series and profiles - will likely not work with Python3.
  2. We have not uploaded pygotm to PyPi yet (as of the release of this blog). As pygotm is not a pure Python package it also includes a shared library basically containing all the functionality of GOTM. pygotm will in principle work with Python3 - import pygotm will produce no errors - but as gotmgui will not work with Python3 the usefullness will be very limited.
  3. Maintaining PyNcView is time consuming but has turned out to be quite essential to our daily workflow. Jorn has as a consequence upgraded PyNcView to work in Python3.

Some of the tools require PyQt 4 or 5, or PySide. Installing these is beyond this blog.

So the short message of this blog is really:

pip install pyncview <--user>

Futher development will only provide support for Python3.