MHKiT-Software / MHKiT-Python

MHKiT-Python provides the marine renewable energy (MRE) community tools for data processing, visualization, quality control, resource assessment, and device performance.
https://mhkit-software.github.io/MHKiT/
BSD 3-Clause "New" or "Revised" License
47 stars 45 forks source link

Handle RDI's variable profile shenanigans #292

Closed jmcvey3 closed 3 months ago

jmcvey3 commented 4 months ago

Introduces fixes for RDI files that contain changing "number of cells" and variable "cell sizes". The latter are bin-averaged into the largest cell size. Issue #291

jmcvey3 commented 4 months ago

@browniea When you get a chance, see if this works for you. The range may still offset based on whatever the "bin1_dist_m" attribute, but that should be easily adjusted.

browniea commented 3 months ago

@jmcvey3 Looks like there is a conflict with the latest merge #286

jmcvey3 commented 3 months ago

@jmcvey3 Looks like there is a conflict with the latest merge #286

Yeah that's annoying

browniea commented 3 months ago

The variable bin size is still being missed but the number of bins is right! image

jmcvey3 commented 3 months ago

The variable bin size is still being missed but the number of bins is right! image

Sweet. The data from the 0.12 m bins is stored in the variables with an "_sl" tag, so I'm sure it wouldn't be difficult to write a function to combine these two. However, I don't think that function would belong in the reader, since the goal of the reader is to read what's in the datafile and do no more processing than necessary.

browniea commented 3 months ago

That makes sense and I agree. I can include that in my next example notebook for UMERC stuff.

jmcvey3 commented 3 months ago

That makes sense and I agree. I can include that in my next example notebook for UMERC stuff.

Great, yes I think that's a good idea, especially since TRDI is retiring the Workhorse line and pushing these newer instruments.