OpenDrift / opendrift

Open source framework for ocean trajectory modelling
https://opendrift.github.io
GNU General Public License v2.0
247 stars 121 forks source link

ChemD+RadioN: Bugfix. '.seconds' to to '.total_seconds()' #1040

Closed manuelaghito closed 1 year ago

manuelaghito commented 1 year ago

'.seconds' does not work for time_step >= 24 hours. Changed to '.total_seconds()' @magnesim ready to merge I think

knutfrode commented 1 year ago

Yes, total_seconds seems more correct here. Tests are probably failing for some other reason.

knutfrode commented 1 year ago

That said, time_step > 24 hours might not be a good idea? time_step_output > 24h should however be ok.

manuelaghito commented 1 year ago

I "needed" that to run some unit tests trying to make them fast. Dynamic partitioning seems to be a slow process. time_step == 24 hours failed with '.seconds'... that gives 0!