'Returns a GDAL SpatialReference object, if GDAL is installed.'

@property
def srs(self):

    if gdal.HAS_GDAL:
        if hasattr(self, '_srs'):
            return self._srs.clone()
        else:
            try:
                self._srs = gdal.SpatialReference(self.wkt)
                return self.srs
            except Exception as msg:
                pass
            try:
                self._srs = gdal.SpatialReference(self.proj4text)
                return self.srs
            except Exception as msg:
                pass
            raise Exception(('Could    not    get    OSR    SpatialReference    from    WKT:    %s\nError:\n%s' % (self.wkt, msg)))
    else:
        raise Exception('GDAL    is    not    installed.')
