0

I am trying to download the SciTools Iris package in Google Colab. I first use pip install, like so:

!pip install scitools-iris

And then import iris with:

import iris

however, this returns the error message:

ERROR:root:An unexpected error occurred while tokenizing input
The following traceback may be corrupted or invalid
The error message is: ('EOF in multi-line string', (1, 0))

---------------------------------------------------------------------------
RuntimeError                              Traceback (most recent call last)
<ipython-input-20-089b5db944e7> in <module>()
----> 1 import iris

/usr/local/lib/python3.7/dist-packages/iris/__init__.py in <module>()
     20   - https://pypi.org/project/irisapi/
     21   - https://iris.claims/
---> 22 """)

RuntimeError: 

Ambiguous 'iris' package.
Please use either:

**illumon-iris** - Python integration for Illumon Iris, a time-series database
  - pip install illumon-iris
  - https://pypi.python.org/pypi/illumon-iris
  - https://deephaven.io/

**SciTools Iris** - Python library for analysing and visualising meteorological and oceanographic data sets
  - http://scitools.org.uk/iris/

**info.gianlucacosta.iris** - A general-purpose library for Python
  - pip install info.gianlucacosta.iris
  - https://pypi.python.org/pypi/info.gianlucacosta.iris

**irisapi** - Iris is a highly configurable and flexible service for paging and messaging
  - pip install irisapi
  - https://pypi.org/project/irisapi/
  - https://iris.claims/

I know I want to import the SciTools Iris package, however it does not tell me how to import this specific one. Does anyone know how to import SciTools Iris in google colab?

USer555
  • 81
  • 7

1 Answers1

0

I cannot reproduce this error on Google Colab. I also note that your output says "The following traceback may be corrupted or invalid". When trying to run an example, I did get an error that was something to do with numpy so upgraded that. So this is what worked for me:

!pip install scitools-iris
!pip install numpy --upgrade
!pip install iris-sample-data

Then I copied and pasted this gallery example, and it just worked.

Note that Iris v3.1 has now been released. I don't know if that makes a difference.

RuthC
  • 1,269
  • 1
  • 10
  • 21