Support WIND Toolkit CSV format#985
Merged
Merged
Conversation
New CSV file format for wind. Improve wind resource error reporting. Remove extra commas in test SRW files. Handle "N/A" in data columns from WIND Toolkit files.
Collaborator
|
@sjanzou Could we get your eyes on this? I can't tell why patch would build, but this would get a linker error on TCS. |
Collaborator
Author
|
When trying to build SAM on Linux, I see build errors in ptesdesignptdialog.cpp caused by functions like GetSelectedMaterial() in the PTESDesignPtDialog class returning |
Collaborator
|
/Users/runner/work/ssc/ssc/ssc/shared/lib_windfile.cpp:513:127: error:
cannot pass object of non-trivial type 'std::string' (aka
'basic_string<char, char_traits<char>, allocator<char>>') through variadic
function; call will abort at runtime [-Wnon-pod-varargs]
3269
<https://github.com/NREL/ssc/actions/runs/4032614475/jobs/6941522919#step:9:3270>
m_errorMsg = util::format("data must be in local time: data time zone %s
and site time zone %s are not the same", tz_data, tz_site);
3270
<https://github.com/NREL/ssc/actions/runs/4032614475/jobs/6941522919#step:9:3271>
^
3271
<https://github.com/NREL/ssc/actions/runs/4032614475/jobs/6941522919#step:9:3272>/Users/runner/work/ssc/ssc/ssc/shared/lib_windfile.cpp:513:136:
error: cannot pass object of non-trivial type 'std::string' (aka
'basic_string<char, char_traits<char>, allocator<char>>') through variadic
function; call will abort at runtime [-Wnon-pod-varargs]
3272
<https://github.com/NREL/ssc/actions/runs/4032614475/jobs/6941522919#step:9:3273>
m_errorMsg = util::format("data must be in local time: data time zone %s
and site time zone %s are not the same", tz_data, tz_site);
The Mac chokes when using std::string for %s…
Need to use a char* - so, please update to tz_data.c_str() and
tz_site.c_str()
Thanks,
Steve
…On Mon, Jan 30, 2023 at 9:35 AM Brian Mirletz ***@***.***> wrote:
@sjanzou <https://github.com/sjanzou> Could we get your eyes on this? I
can't tell why patch would build, but this would get a linker error on TCS.
—
Reply to this email directly, view it on GitHub
<#985 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABRSQBZOKS4PLG5IL6IRUVTWU7UVFANCNFSM6AAAAAAUJXGI24>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
mjprilliman
reviewed
Jan 30, 2023
mjprilliman
left a comment
Collaborator
There was a problem hiding this comment.
Test files worked in the UI and in included LK script
Collaborator
Author
|
Thanks @sjanzou for the solution to the mac build issue. |
mjprilliman
approved these changes
Jan 31, 2023
14 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replace #984 due to CI errors.
Fixes NatLabRockies/SAM#962
Also partially addresses NatLabRockies/SAM#815 by adding support for CSV files downloaded from RE Explorer
Next step is to update wind data download widget in SAM UI to download from wtk-download instead of wtk-srw-download, and possibly other WIND Toolkit endpoints at https://developer.nrel.gov/docs/wind/wind-toolkit/ (note that not all endpoints use the same CSV file format).
For endpoints that use different file format, consider writing a macro to convert files. For example, compare files from offshore-mid-atlantic-download to wtk-download.
SAM should now work with any of the wind data files here:
wind-file-samples.zip