Modernize gdal imports

GDAL has dropped support for the older toplevel `import gdal`
in version 3.2, now requiring `from osgeo import gdal`.
LT1AB
Ryan Burns 2021-01-06 11:07:58 -08:00
parent 86b126f564
commit ad1815ef9c
24 changed files with 32 additions and 35 deletions

View File

@ -9,7 +9,7 @@ import logging
from components.stdproc.stdproc import crossmul
from iscesys.ImageUtil.ImageUtil import ImageUtil as IU
import os
import gdal
from osgeo import gdal
import numpy as np
logger = logging.getLogger('isce.insar.runInterferogram')

View File

@ -7,7 +7,7 @@ import isce
import isceobj
from imageMath import IML
from osgeo import gdal
from gdalconst import *
from osgeo.gdalconst import *
import logging
import scipy.spatial as SS

View File

@ -9,8 +9,8 @@ import argparse
import numpy as np
from scipy import ndimage
import matplotlib.pyplot as plt
import gdal
from gdalconst import GA_ReadOnly
from osgeo import gdal
from osgeo.gdalconst import GA_ReadOnly
# suppress the DEBUG message
import logging

View File

@ -9,7 +9,7 @@ import isce
import isceobj
from isceobj.Constants import SPEED_OF_LIGHT
import numpy as np
import gdal
from osgeo import gdal
import shelve
from scipy import ndimage

View File

@ -7,7 +7,7 @@ import argparse
import isce
import isceobj
import os
import gdal
from osgeo import gdal
import xml.etree.ElementTree as ET
def createParser():

View File

@ -15,7 +15,7 @@ from isceobj.Util.Poly2D import Poly2D
import h5py
from insarPair import insarPair
from insarStack import insarStack
import gdal
from osgeo import gdal
#################################################################

View File

@ -8,8 +8,8 @@ import os
import glob
import isce
import isceobj
import gdal
from gdalconst import GA_ReadOnly
from osgeo import gdal
from osgeo.gdalconst import GA_ReadOnly
#import s1a_isce_utils as ut
from isceobj.Planet.Planet import Planet
import shelve

View File

@ -2,8 +2,8 @@
# Heresh Fattahi
import os
import gdal
from gdalconst import GA_ReadOnly
from osgeo import gdal
from osgeo.gdalconst import GA_ReadOnly
import numpy as np
from lxml import objectify

View File

@ -7,9 +7,8 @@ import os
import isce
import isceobj
import shelve
import gdal
import osr
from gdalconst import GA_ReadOnly
from osgeo import gdal, osr
from osgeo.gdalconst import GA_ReadOnly
from scipy import ndimage

View File

@ -8,9 +8,8 @@ import os
import isce
import isceobj
import shelve
import gdal
import osr
from gdalconst import GA_ReadOnly
from osgeo import gdal, osr
from osgeo.gdalconst import GA_ReadOnly
from scipy import ndimage

View File

@ -7,7 +7,7 @@ import argparse
import isce
import isceobj
import os
import gdal
from osgeo import gdal
import matplotlib as mpl; #mpl.use('Agg')
import matplotlib.pyplot as plt
from pykml.factory import KML_ElementMaker as KML

View File

@ -16,7 +16,7 @@ import time
#import matplotlib.pyplot as plt
from contrib.splitSpectrum import SplitRangeSpectrum as splitSpectrum
from isceobj.Constants import SPEED_OF_LIGHT
import gdal
from osgeo import gdal
def createParser():

View File

@ -16,7 +16,7 @@ import time
#import matplotlib.pyplot as plt
from contrib.splitSpectrum import SplitRangeSpectrum as splitSpectrum
from isceobj.Constants import SPEED_OF_LIGHT
import gdal
from osgeo import gdal
def createParser():

View File

@ -6,7 +6,7 @@ import shelve
import datetime
import shutil
import numpy as np
import gdal
from osgeo import gdal
import isce
import isceobj
from isceobj.Constants import SPEED_OF_LIGHT

View File

@ -9,8 +9,8 @@ import argparse
import os
import isce
import isceobj
import gdal
from gdalconst import GA_ReadOnly
from osgeo import gdal
from osgeo.gdalconst import GA_ReadOnly
from scipy import ndimage

View File

@ -6,7 +6,7 @@ import os
import argparse
import glob
import numpy as np
import gdal
from osgeo import gdal
import isce
import isceobj
from isceobj.Sensor.TOPS import createTOPSSwathSLCProduct

View File

@ -13,7 +13,7 @@ import copy
from isceobj.Sensor.TOPS import createTOPSSwathSLCProduct
from mroipac.correlation.correlation import Correlation
import s1a_isce_utils as ut
import gdal
from osgeo import gdal
def createParser():

View File

@ -7,7 +7,7 @@ import argparse
import isce
import isceobj
import os
import gdal
from osgeo import gdal
import numpy as np
import xml.etree.ElementTree as ET

View File

@ -12,7 +12,7 @@ from iscesys.Component.ProductManager import ProductManager as PM
import numpy as np
from netCDF4 import Dataset
#from mpl_toolkits.basemap import Basemap
import gdal
from osgeo import gdal
from scipy.interpolate import interp2d, griddata

View File

@ -8,8 +8,8 @@ import os
import glob
import isce
import isceobj
import gdal
from gdalconst import GA_ReadOnly
from osgeo import gdal
from osgeo.gdalconst import GA_ReadOnly
import s1a_isce_utils as ut
from isceobj.Planet.Planet import Planet

View File

@ -11,9 +11,8 @@ import os
import isce
import isceobj
import shelve
import gdal
import osr
from gdalconst import GA_ReadOnly
from osgeo import gdal, osr
from osgeo.gdalconst import GA_ReadOnly
from scipy import ndimage

View File

@ -7,7 +7,7 @@ import argparse
import isce
import isceobj
import os
import gdal
from osgeo import gdal
import matplotlib as mpl; #mpl.use('Agg')
import matplotlib.pyplot as plt
from pykml.factory import KML_ElementMaker as KML

View File

@ -38,7 +38,7 @@ from isceobj.Constants import SPEED_OF_LIGHT
import argparse
import os
import pickle
import gdal
from osgeo import gdal
import numpy as np
#import shelve
import s1a_isce_utils as ut

View File

@ -56,7 +56,7 @@ def baselinegrid(inps):
"""
Basline files are given as grids
"""
import gdal
from osgeo import gdal
# parsing the command line inputs
baseline_dir = inps.baseline_dir