Only soil fertility changes #131
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Note, that biomass_accumulation fails to be compiled. Under development mode, this function works. There seems a bug related to compiling after adding Crop class in the output
The last pull request contains more changes from my side. This pull request only contains soil fertility stress.
How to test: see another video
Brief explanations on changes:
• aquacrop/entities/crop.py
Add the variables needed for soil fertility stress simulation and give the default values. The default values are the values under no soil fertility stress.
• aquacrop/entities/crops/crop_params.py
Add testing crops which will be the same as AQ-WIN
• aquacrop/entities/initParamVariables.py
Initialize some global variables for soil fertility stress calculation. These variables keep some critical values during the soil fertility stress simulation.
• aquacrop/entities/output.py
Add soil fertility stress output for testing
• aquacrop/entities/soil.py
I changed the logic to calculate the soil hydraulic parameters according to AQ-WIN, which should have no impact on soil fertility stress simulation. For my own global model, the previous code may lead to some errors.
• aquacrop/initialize/compute_crop_calendar.py
Calculate the crop phenological calendar with soil fertility stress parameters
Initialize soil fertility stress simulation
Calibrate soil fertility stress if needed
• aquacrop/initialize/compute_variables.py
Adjust to ensure CO2 data is available during initialization
• aquacrop/initialize/read_model_parameters.py
Read CO2 data first for soil fertility stress calculation and delete the redundant codes
• aquacrop/solution/adjust_CCx.py
Adjustment of CCx and canopy development because of soil fertility stress
• aquacrop/solution/biomass_accumulation.py
Adjustment of water productivity and biomass because of soil fertility stress
There is a dynamic update of soil fertility stress according to AQ-WIN
• aquacrop/solution/canopy_cover.py
Adjustment of CCx, canopy development, and senescence because of soil fertility stress
There is an interaction between soil fertility stress and early senescence
• aquacrop/timestep/outputs_when_model_is_finished.py
Add soil fertility stress output
• aquacrop/timestep/reset_initial_conditions.py
Reset initial conditions for soil fertility stress. Almost the same as aquacrop/initialize/compute_crop_calendar.py
• aquacrop/timestep/run_single_timestep.py
Enable some global variables to pass to the next time step