Open AStcherbinine opened 2 years ago
I think I know the problem, and if so all the tests should fail. I believe problem is essentially that there appear to be discrepancies throughout the native DISORT code in the definition of RHOU (and to a lesser extent, its partner RHOQ). In DISOBRDF.f (the file that populates these arrays), they define the array shapes on lines 95 and 96. The comments defining whatever these variables are (all I really know is that they're the key arrays to defining the surface phase function) are in lines 51--57, and the comments don't really match what the code does. The bigger issue is that DISORT.f defines the shape of these arrays on lines 434 and 435 in a way that's inconsistent with the shapes used in DISOBRDF.f. When I compiled the native DISORT code using f2py, absolutely nothing worked.
After chatting with Mike about it, we collectively decided the array shapes in DISORBRDF.f were correct and consequently, the shape of RHOU in DISORT.f needed modified to interface with that code. So, I modified the shape of RHOU in line 435 of DISORT.f. It now appears that all the code works together well, but the tests that come with DISORT make the RHOU arrays assuming the DISORT.f shape was originally correct---so they should all fail now. I'm a bit uneasy about this modification because I think they surely should've caught it, but it's the best we've got until we find the time to more adequately resolve it.
The disotestREADME_pyRT_DISORT.txt
file that describes all the changes I made to the source code. This is really the only modification, though I did add some surface phase function stuff.
Hello,
I've tried to implement the build-in test 16 (pseudo-spherical correction) using the disort wrapper and get some array dimension errors. But then I've noticed that a similar error is raised when I try to run the tests implemented in the
pyRT_DISORT/tests/disort_tests
folder. Do you know where it comes from?Output for
python3 disotest1a.py
Output for
python3 disotest9.py