APSIMInitiative / ApsimX

ApsimX is the next generation of APSIM
http://www.apsim.info
Other
129 stars 159 forks source link

No water and nitrogen uptakes are being supplied to the root. #9017

Open yacobbeletse opened 1 month ago

yacobbeletse commented 1 month ago

What happened?

I am encountering some issues while testing a new crop using the Plant Modelling Framework (PMF). I am getting an error message stating: No water and nitrogen uptakes are being supplied to the root. Is Soil Arbitrator included in the simulation? I can confirm that the Soil Arbitrator is included in my simulation tree.

I have checked the bugs and crash reports, and while the exceptions seem similar, I have been unable to resolve the issue. The answered questions pertain to existing crops and do not address the PMF specifically.

I am unsure how to proceed further. Could you provide assistance or guidance on how to resolve this issue? PMFSoilArbitrator.zip

What Operating System are you on?

Windows

BrianCollinss commented 1 month ago

Can you briefly tell us what you have changed in Root or other organs, compared to the Plant you started with?

BrianCollinss commented 1 month ago

Strange thing is that even when I add another plant to Paddock and sow that instead of new "Plant", I get the same error, unless I remove/disable the "Plant". Also, it happens from day 1 when your plant is not even on the ground.

I am not sure if it is relevant to this issue, but you also need to add your new "Plant" to Models/Resources/SurfaceOrganicMatter.json.

byzheng commented 1 month ago

I worked with @yacobbeletse before he submitted this issue, but cannot figure out reason for this error. It is very strange for this simulation.

Then run out of ideas for this problem.

yacobbeletse commented 4 weeks ago

@BrianCollinss - I constructed a model called Plant in the same manner that models are coupled to build a simulation tree, that means I dragged and dropped the lower level processes to Plant

BrianCollinss commented 4 weeks ago

Have you made a change after dragging and dropping?

yacobbeletse commented 4 weeks ago

Yes, I have made changes

peter-devoil commented 3 weeks ago

Making a diff against the original resource (potato?) may uncover if a change has been made to the original that hasn't been applied to your copy. Diffs are tedious - you'll have to copy out the json to a text file and compare it against the resource file.

byzheng commented 3 weeks ago

My understanding may be not correct. A model/node in the simulation tree should not be evaluated if it is not used in other places.

In this case @yacobbeletse's example, A new Plant is defined under Paddock, but is not used for any manager scripts. The same error still obtained.

byzheng commented 3 weeks ago

For example, the apsim file below is a minimum example which contains a new plant Magic and Wheat. Other components are removed.

PMFSoilArbitratorMinimum.zip

yacobbeletse commented 3 weeks ago

@peter-devoil. In this case, I started with the Plant model instead of the Potato model. I had previously attempted to test Taro using the Potato model through Replacements. However, I moved away from using Replacements as it did not provide me the flexibility I needed to represent the specific Plant I am trying to test. For example, I could not add GenericPhase. So, the simulation with the magic Plant that Bangyou forwarded is based on the Plant model.

ilhuber commented 3 weeks ago

Looks like it is because your germinating phase is marked as emerged. This causes the arbitrator to try to do allocation even if the plant hasn't been sown.