Skip to content

Commit

Permalink
Update OSGeo imports
Browse files Browse the repository at this point in the history
Replace deprecated imports, e.g.:

  import gdal

with updated method, e.g.

  from osgeo import gdal
  • Loading branch information
cemacrr committed Nov 18, 2020
1 parent 5a86452 commit fe4ca29
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion bin/LiCSBAS02_ml_prep.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
import sys
import time
import shutil
import gdal
from osgeo import gdal
import glob
import numpy as np
import subprocess as subp
Expand Down
2 changes: 1 addition & 1 deletion bin/LiCSBAS03op_GACOS.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
import shutil
import glob
import numpy as np
import gdal
from osgeo import gdal
import multiprocessing as multi
import LiCSBAS_io_lib as io_lib
import LiCSBAS_tools_lib as tools_lib
Expand Down
2 changes: 1 addition & 1 deletion bin/LiCSBAS_color_geotiff.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ def __init__(self, msg):


#%% Set color range
import gdal
from osgeo import gdal

### Auto
if cmin is None:
Expand Down
2 changes: 1 addition & 1 deletion bin/LiCSBAS_color_geotiff2tiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
import time
import shutil
import glob
import gdal
from osgeo import gdal
import numpy as np
import subprocess as subp
import multiprocessing as multi
Expand Down
2 changes: 1 addition & 1 deletion bin/LiCSBAS_decomposeLOS.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
import getopt
import os
import sys
import gdal, osr
from osgeo import gdal, osr
import numpy as np
import time
from decimal import Decimal
Expand Down
2 changes: 1 addition & 1 deletion bin/LiCSBAS_disp_img.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
import subprocess as subp
import SCM
import zipfile
import gdal
from osgeo import gdal

import LiCSBAS_tools_lib as tools_lib
import LiCSBAS_io_lib as io_lib
Expand Down
2 changes: 1 addition & 1 deletion bin/LiCSBAS_flt2geotiff.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ def main(argv=None):
else:
print('Use gdal module')
try:
import gdal, osr
from osgeo import gdal, osr
except:
print("\nERROR: gdal must be installed.", file=sys.stderr)
return 1
Expand Down

0 comments on commit fe4ca29

Please sign in to comment.