UU-Hydro / PCR-GLOBWB_model

PCR-GLOBWB (PCRaster Global Water Balance) is a large-scale hydrological model intended for global to regional studies and developed at the Department of Physical Geography, Utrecht University (Netherlands). Contact: Edwin Sutanudjaja (E.H.Sutanudjaja@uu.nl).
GNU General Public License v3.0
116 stars 79 forks source link

Automatically derive input reading frequency from file #33

Open BramDr opened 6 months ago

BramDr commented 6 months ago

Currently, the frequency at which input parameters are read from file is hard coded in the model. For example the yearly land-surface inputs:


        # - assumption: annual resolution
        if self.noAnnualChangesInLandCoverParameter == False and self.dynamicIrrigationArea == False and \
          (currTimeStep.timeStepPCR == 1 or currTimeStep.doy == 1):
            msg = 'Read land cover fractions based on the given netcdf file.'```

It would be better for this frequency to be derived from the files themselves, meaning that if a monthly file is given, data is read monthly. Moreover, if the final timestep of the input file is reached, the input data of the final timestep is re-read every year. This is not needed.