예제 #1
0
 def __init__(self):
     """ Calls the Hazard init dunder. Sets unit to 'm/s'. """
     Hazard.__init__(self, HAZ_TYPE)
     self.units = 'm/s'
     self.ssi = np.array([], float)
     self.ssi_wisc = np.array([], float)
     self.ssi_full_area = np.array([], float)
예제 #2
0
 def __init__(self, pool=None):
     """Empty constructor. """
     Hazard.__init__(self, HAZ_TYPE)
     if pool:
         self.pool = pool
         LOGGER.info('Using %s CPUs.', self.pool.ncpus)
     else:
         self.pool = None
예제 #3
0
 def __init__(self, pool=None):
     """Empty constructor."""
     Hazard.__init__(self, HAZ_TYPE)
     self.category = np.array([], int)
     self.basin = list()
     if pool:
         self.pool = pool
         LOGGER.info('Using %s CPUs.', self.pool.ncpus)
     else:
         self.pool = None
예제 #4
0
    def __init__(self, pool=None):
        """Empty constructor. """
        Hazard.__init__(self, HAZ_TYPE)
        if pool:
            self.pool = pool
            LOGGER.info('Using %s CPUs.', self.pool.ncpus)
        else:
            self.pool = None

        self.crop = DFL_CROP
        self.intensity_def = INT_DEF
예제 #5
0
    def __init__(self, pool=None):
        """Initialize values.

        Parameters
        ----------
        pool : pathos.pool, optional
            Pool that will be used for parallel computation when applicable. Default: None
        """
        Hazard.__init__(self, haz_type=HAZ_TYPE, pool=pool)
        self.category = np.array([], int)
        self.basin = []
        self.windfields = []
예제 #6
0
    def __init__(self):
        """Empty constructor."""
        Hazard.__init__(self, HAZ_TYPE)
#        Hazard.__init__(self)
#        self.file_url = SPEI_FILE_URL
#        self.file_dir = SPEI_FILE_DIR
#        self.file_name = SPEI_FILE_NAME

        self.file_path = Path(SPEI_FILE_DIR, SPEI_FILE_NAME)
        self.threshold = DFL_THRESHOLD
        self.intensity_definition = DFL_INTENSITY_DEF
        self.latmin = LATMIN
        self.latmax = LATMAX
        self.lonmin = LONMIN
        self.lonmax = LONMAX
 def __init__(self):
     """Empty constructor."""
     Hazard.__init__(self, HAZ_TYPE)
예제 #8
0
 def __init__(self):
     """Empty constructor."""
     Hazard.__init__(self, HAZ_TYPE)
     self.tag.haz_type = 'LS'
예제 #9
0
 def __init__(self):
     """Empty constructor. """
     Hazard.__init__(self, HAZ_TYPE)
     self.spei = np.array([], int)
예제 #10
0
 def __init__(self):
     Hazard.__init__(self, HAZ_TYPE)
예제 #11
0
 def __init__(self):
     """ Calls the Hazard init dunder. Sets unit to 'm/s'. """
     Hazard.__init__(self, HAZ_TYPE)
     self.units = 'm/s'