badlands-model / badlands

Basin and Landscape Dynamics model
https://badlands.readthedocs.io
GNU General Public License v3.0
137 stars 41 forks source link

readEroLay type error & boundary types #18

Closed eslrgs closed 4 years ago

eslrgs commented 4 years ago

Hi,

I have made both topography and uplift fields that work within my model, however when I make an erodibility field using the same method and try to read using readEroLay I get a 'NoneType' object cannot be interpreted as an integer error. I have tried to fix it but cannot seem to get round the problem. Everything else has been working perfectly!

I have cross-checked the erodibility csv with the Corinth example and it is of the same structure.

Also, is there any information on the differences between the boundary types (flat, slope, fixed or wall)?

Thanks,

eslrgs

Screenshot 2020-06-19 at 13 55 28
tristan-salles commented 4 years ago

Hi @eslrgs, you first need to run the following function before loading the erodibility maps: forcings.readDEM('data/nodes.csv') So it will look like:

forcings = rInput.readInput() forcings.readDEM('data/nodes.csv') forcings.readEroLay('data/ero.csv')

Regarding the boundary types:

Most of the time you want to use the slope of flat boundary types.

Hope it helps! Tristan

eslrgs commented 4 years ago

That's the fix - thanks Tristan! All working now.

Thanks for the boundary information too.

eslrgs commented 4 years ago

One final question..

Are the diffusion values within the XML input per year or per time-step? i.e. does a marine diffusion rate of 0.0001 m2/yr within a model using a timestep of 10000 years = 1 m2/a within the XML input?

tristan-salles commented 4 years ago

The value is per year: https://badlands.readthedocs.io/en/latest/xml.html#hillslope-structure