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

Delft 3D Timestep to Seconds Function #168

Closed browniea closed 1 year ago

browniea commented 2 years ago

This PR outputs the time based on the time step in function convert_time, d3d. get_layer_data and d3d.get_all_data_points. A function to get all timestamps 'get_all_timestamps' will return an array of all the timestamps for a data set.

Additions: -get_all_timestamps : inputs netcdf4 dataframe and return as all the time stamps for that data set -convert_time : converts a time_index to a time_stamp in seconds or vice versa

Changes in 'get_layer_data`

Changes in 'get_all_data_points`

browniea commented 2 years ago

Changing the d3d.turbulent_intensity function to output TI in a percentage rather than a fraction

TI_data['turbulent_intensity']= np.sqrt(2/3*TI_data['turkin1'])/u_mag * 100