No module named 'sentinelhub.common'


#1

Hi,
While exploring “https://github.com/azupanc/eo-ex/blob/master/notebooks/water-level-monitor/theewaterskloof_dam_water_level.ipynb” I am stuck at line
“from sentinelhub.common import BBox, CRS”.The error is :-No module named ‘sentinelhub.common’.
What could be the reason for this problem?


#2

Hi @mansimittal06,

In the newest version of sentinelhub-py module common was renamed to geometry. That is why you are getting an error.

Please change that line into

from sentinelhub import BBox, CRS

#3

Okay got it.It solved my problem.Thank You.


#4

Kindly help me in one more error:-
AttributeError: ‘tuple’ object has no attribute ‘exterior’


#5

Hi Mansi,

this example is no longer maintained. Please take a look at sentinel-hub/water-observatory-backend instead for a working and up-to-date example.

Best regards,

Anze

PS: I updated the example’s README with this note.


#6

Okay thank you for this reference.


#7

Hi,
I was trying the
https://github.com/sentinel-hub/water-observatory-backend example.
There are invalid syntax error in some scripts that are present in src.


#8

What Python version are you using? Is this due to f-strings that are available from Python 3.6?


#9

I am using python version 3.5


#10

If you don’t wish to upgrade your python installation to 3.6, then the solution is to replace the f-strings like

f'{resx}m'

with

'{}m'.format(resx)